12 Commits
Author SHA1 Message Date
x3 916a167f67 feat: rewrite terminal to use vte_terminal_spawn_sync
Replaced the SSH library + IO thread + intermediate PTY bridge with
vte_terminal_spawn_sync(). This eliminates the broken terminal behavior
(backspace, Ctrl+C, copy/paste, bash completion) caused by the
intermediate PTY with no process on the slave side.

- SshTerminal now spawns 'ssh' as a VTE subprocess
- Removed libssh dependency from terminal (still used for key validation)
- Removed IO thread, manual PTY creation, and thread synchronization
- VTE now handles all terminal I/O, line discipline, resize, etc.
- Password saved: uses sshpass -e with SSHPASS env var if available
- Password not saved: ssh prompts interactively in the terminal
- Removed show_password_dialog (no longer needed)
- Simplified connect flow in ssh_client.cpp
2026-09-07 16:54:21 +00:00
x3 69369aedb8 Fix: replace openpty with posix_openpt, add password retry dialog
- Replace openpty() with posix_openpt()+grantpt()+unlockpt()+ptsname()
  to fix segfault on PTY creation
- Add out_error parameter to SshTerminal::connect() to propagate error
- Password dialog now shows red error message on auth failure
- Password dialog re-opens automatically on failed password auth
  so user can retry without restarting
2026-09-07 16:29:36 +00:00
x3 e4ef84bf8e Debug: add granular logging to SSH connect to find crash point 2026-09-07 16:05:39 +00:00
x3 d85726043e Fix: crash on connect - invalid VTE signal 'size-changed'
The signal 'size-changed' does not exist in VTE 2.91. This caused a
GLib-GObject-CRITICAL warning followed by a segfault when connecting.

Fixed by replacing the VTE signal with GTK's 'size-allocate' signal
on the terminal widget, which correctly detects terminal size changes
and resizes the remote PTY accordingly.
2026-09-07 16:02:35 +00:00
x3 fe7050c018 Fix: sidebar refresh after edit, crash on connect, live log, uninstall script
- Fix sidebar disappearing after edit: add gtk_widget_show_all after rebuild
- Fix crash on connect: flush pending GLib idle callbacks in disconnect()
- Fix single-click: explicitly set activate_on_single_click to FALSE
- Add live log output when started from terminal (stderr + ~/.config/sshclient/x3-ssh.log)
- Add logging to SSH connect, auth, and key operations
- Add uninstall.sh script to remove system-wide installation
2026-09-07 15:50:11 +00:00
x3 6e719c3236 Fix: crash on failed connect, add sidebar edit/delete, password saving
- Fix crash when SSH connect fails: remove page BEFORE deleting terminal
- Sidebar right-click context menu: Connect / Edit / Delete
- Password field + Save password checkbox in server dialog
- ServerConfig stores password and save_password fields
- Auto-connect uses saved password when available
- Restore original flaticon icon
2026-09-07 15:34:23 +00:00
x3 16ae7ffde2 docs: update README with sidebar, notifications, layout diagram 2026-09-07 15:25:47 +00:00
x3 c5df1fd5f5 chore: fix .gitignore to exclude autotools generated files 2026-09-07 15:20:30 +00:00
x3 539e951fec feat: server list sidebar + notifications + new icon
- Added server list sidebar (GtkPaned) showing saved servers with
  name, user@host:port detail. Double-click to connect.
- Added '+' button in sidebar to add new servers
- Added notification bar (animated GtkRevealer) for status messages:
  'Server saved', 'Server connected', 'Server disconnected',
  'Server removed', 'Key generated', 'Key imported', 'Key deleted'
  Auto-hides after 4 seconds.
- Changed icon to terminal-style PNG + SVG (scalable)
- Server list updates automatically when servers are added/removed

Layout: [Sidebar: Servers] | [Notebook: Terminal Tabs]
2026-09-07 15:19:48 +00:00
x3 75ceeffab9 fix: toolbar buttons not visible - hbox was never packed into window
The build_toolbar() method created a local GtkBox (hbox) and packed all
buttons into it, but never added hbox to the window's vbox. The toolbar
was created then immediately garbage collected.

Fix: Inline all UI construction directly into build_ui() and pack the
toolbar box into the vbox with gtk_box_pack_start().
2026-09-07 15:05:41 +00:00
x3 4a2b2eac33 fix: critical bugs + .desktop file + system install
Bug fixes:
- Fixed PTY bridge: IO thread now uses pty_slave_ instead of pty_master_
  (remote output was never reaching the terminal)
- Fixed double-delete crash on tab close by removing page-removed callback
- Fixed port being ignored in password dialog (always used port 22)
- Added EINTR handling in select() for IO thread
- Added mutex for thread-safe cleanup
- Added try/catch for std::stoi in server config parsing
- VtePty lifecycle now managed properly (no double-close)
- Redundant ssh_channel_poll_timeout call removed

New:
- Added .desktop file for system-wide application menu entry
- Makefile.am installs desktop file to $(datadir)/applications
- Makefile.am installs icon to $(datadir)/icons/hicolor/256x256/apps
2026-09-07 15:00:08 +00:00
x3 77f9568cb1 feat: initial x3-ssh client
- GTK3 GUI with VTE terminal emulation
- Tabbed SSH sessions
- Server management (add/edit/remove)
- SSH key management (generate/import/delete)
- Quick connect bar
- libssh for SSH connections
- autotools build system (configure && make)
2026-09-07 14:50:20 +00:00