Repository navigation
fix: merge upstream fixes and repair ssh config writes - #1
Merged
Merged
Conversation
(cherry picked from commit 5fada77)
(cherry picked from commit 54d33de)
… UpdateServers (cherry picked from commit 2a38451)
Preserving the selection across list refreshes (previous commit) also applied to search input, so a previously selected host that still matched the new query stayed selected instead of the best match.
The Windows console reports Backspace as KeyCtrlH (0x08) without a Ctrl modifier, so the form treated every Backspace as "previous tab". Only switch tabs on Windows when Ctrl is actually held. Unix terminals send DEL for Backspace, so Ctrl+H keeps working there. Fixes the bug reported in upstream Adembc#106, without disabling Ctrl+S/Ctrl+L/Esc while an input field has focus.
Saving renamed the temp file over ~/.ssh/config itself, replacing a symlink (e.g. into a dotfiles repo) with a regular file and leaving the real file stale. Resolve the link first and atomically replace its target instead. Backups still go next to the link in ~/.ssh. Fixes upstream Adembc#96.
New hosts were appended to the end of the file, after a trailing "Host *". OpenSSH uses the first value it finds for each option, so anything set under "Host *" (User, IdentityFile, ...) silently overrode the same option on the new host. Insert the new host before the first non-global Host block whose patterns match its alias.
The ssh_config parser strips the leading "!" from Pattern.Str and only tracks the negation internally, so every save rewrote "Host * !foo" as "Host * foo", inverting its meaning. It also made "Host !foo" show up as a server named foo. Restore the "!" right after parsing.
Owner
Author
|
@kody start-review |
Kody Review CompleteGreat news! 🎉 Keep up the excellent work! 🚀 Kody Guide: Usage and ConfigurationInteracting with Kody
Current Kody ConfigurationReview OptionsThe following review options are enabled or disabled:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR fixes several SSH configuration persistence issues and improves terminal UI behavior:
!bastion) when configs are loaded and saved, preventing their meaning from being changed.Ctrl+H, preventing Backspace from triggering previous-tab navigation.@and:in addition to existing supported characters.