added ssh-host which uses the configuration to select the host to connect to

This commit is contained in:
Stefan Friese 2024-08-07 17:15:16 +02:00
parent 0d1b8c875a
commit 7e2199191d
1 changed files with 4 additions and 0 deletions

View File

@ -9,6 +9,10 @@ ssh() {
# exit
}
ssh-host() {
ssh $(awk '$1 == "Host" && $2 != "*" {print $2}' "$HOME/.ssh/conf.d/individual_user" | fzf --reverse)
}
# Creates a new directory and immediately changes into it
mkcd() {
mkdir -p "$1" && cd "$1"