Skip to content
Snippets Groups Projects
Commit 779b2cc8 authored by nimrod's avatar nimrod
Browse files

- Better implementation of ssh-keyscan-add shell function.

parent f3cbf073
No related branches found
No related tags found
No related merge requests found
...@@ -85,8 +85,8 @@ deduce_aws_region () { ...@@ -85,8 +85,8 @@ deduce_aws_region () {
} }
ssh_keyscan_add () { ssh_keyscan_add () {
# shellcheck disable=SC2094 ssh-keyscan "$@" >> "$HOME/.ssh/known_hosts"
(ssh-keyscan "$@"; cat "$HOME/.ssh/known_hosts") | sort -u >> "$HOME/.ssh/known_hosts" sort -uo "$HOME/.ssh/known_hosts" "$HOME/.ssh/known_hosts"
} }
gen_csr () { gen_csr () {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment