aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoe <rbo@gmx.us>2024-05-16 20:20:20 +0200
committerJoe <rbo@gmx.us>2024-05-16 20:20:20 +0200
commit6d0b3b71ea66f7555ce80ee64cf22d439a4c6ccd (patch)
treeee821bb00ba457df732464a5d9137dce6d1248c9
parentseems to be good (diff)
downloadhardflip-6d0b3b71ea66f7555ce80ee64cf22d439a4c6ccd.tar.gz
hardflip-6d0b3b71ea66f7555ce80ee64cf22d439a4c6ccd.tar.bz2
hardflip-6d0b3b71ea66f7555ce80ee64cf22d439a4c6ccd.tar.xz
hardflip-6d0b3b71ea66f7555ce80ee64cf22d439a4c6ccd.tar.zst
hardflip-6d0b3b71ea66f7555ce80ee64cf22d439a4c6ccd.zip
hey this might even work
-rw-r--r--ROADMAP.md2
-rw-r--r--src/e_events.go2
-rw-r--r--src/e_keys.go2
3 files changed, 3 insertions, 3 deletions
diff --git a/ROADMAP.md b/ROADMAP.md
index 6fd2ab3..51e54c0 100644
--- a/ROADMAP.md
+++ b/ROADMAP.md
@@ -46,7 +46,7 @@
## v0.8
-- [ ] default ssh key
+- [x] default ssh key
- [ ] theming
## v1.0 - wheelbite
diff --git a/src/e_events.go b/src/e_events.go
index 6708a84..342b871 100644
--- a/src/e_events.go
+++ b/src/e_events.go
@@ -511,7 +511,6 @@ func e_set_protocol_defaults(data *HardData, in *HostNode) {
case PROTOCOL_SSH:
in.Port = 22
in.Priv = data.opts.DefSSH
- in.Jump.Priv = data.opts.DefSSH
case PROTOCOL_RDP:
in.Port = 3389
in.Quality = 2
@@ -519,7 +518,6 @@ func e_set_protocol_defaults(data *HardData, in *HostNode) {
in.Height = 1200
in.Dynamic = true
in.drive_keys = nil
- in.Jump.Priv = data.opts.DefSSH
case PROTOCOL_CMD:
in.Silent = false
in.Shell = []string{"/bin/sh", "-c"}
diff --git a/src/e_keys.go b/src/e_keys.go
index 24976e6..aeca0b6 100644
--- a/src/e_keys.go
+++ b/src/e_keys.go
@@ -763,8 +763,10 @@ func e_insert_events(data *HardData, ui *HardUI, event tcell.EventKey) bool {
data.insert.Jump.Host = ui.buff.str()
if len(ui.buff.str()) > 0 {
data.insert.Jump.Port = 22
+ data.insert.Jump.Priv = data.opts.DefSSH
} else {
data.insert.Jump.Port = 0
+ data.insert.Jump.Priv = ""
}
case INS_SSH_JUMP_PORT,
INS_RDP_JUMP_PORT + len(data.insert.Drive):