# SSH to an unknown host and print the new known_hosts entry
function ssh_new {
local new_known_hosts_file="$(mktemp)"
- ssh -o UserKnownHostsFile="$new_known_hosts_file" "$1" echo Connection ok
+ ssh -o UserKnownHostsFile="$new_known_hosts_file" "$@" echo Connection ok
cat "$new_known_hosts_file"
rm -f "$new_known_hosts_file"
}
+# SSH without verifying host key
+function ssh_unsafe {
+ ssh -o StrictHostKeyChecking=no "$@"
+}
+
# Bash should check the terminal size after every command terminates
shopt -s checkwinsize
# Don't attempt to tab-complete an empty line
shopt -s no_empty_cmd_completion
-
+# Prevent overwriting existing files on stdout redirection
+set -o noclobber
# Local customisations
[ -r "${HOME}/.bash/interactive_local" ] && source "${HOME}/.bash/interactive_local"