Loading .ssh/ssh +7 −4 Original line number Diff line number Diff line Loading @@ -15,7 +15,7 @@ die() { ssh_version() { eval `${SSH_BIN} -V 2>&1 | sed -n \ 's/OpenSSH_\([0-9]\+\)\.\([0-9]\+\).*/SSH_MAJOR="\1" SSH_MINOR="\2"/p'` 's/OpenSSH_\([0-9]\{1,\}\)\.\([0-9]\{1,\}\).*/SSH_MAJOR="\1" SSH_MINOR="\2"/p'` } platform() { Loading @@ -37,9 +37,12 @@ platform() { } config_sed() { case $PLATFORM in darwin|bsd) SED_WORD_START='[[:<:]]' SED_WORD_END='[[:>:]]'; return ;; esac case "$SHELL" in bash) SED_WORD_DELIM='\b' ;; zsh|sh) SED_WORD_DELIM='\\b' ;; bash) SED_WORD_START='\b' SED_WORD_END='\b' ;; zsh|sh) SED_WORD_START='\\b' SED_WORD_END='\b' ;; esac } Loading Loading @@ -78,7 +81,7 @@ rule_canonisation() { rule_runtime() { # Replace RUNTIME with the value of the RUNTIME variable [ -n "$RUNTIME" ] || die "RUNTIME not set" echo "s!${SED_WORD_DELIM}RUNTIME${SED_WORD_DELIM}!${RUNTIME-.}!g;" echo "s!${SED_WORD_START}RUNTIME${SED_WORD_END}!${RUNTIME-.}!g;" } make_config() { Loading Loading
.ssh/ssh +7 −4 Original line number Diff line number Diff line Loading @@ -15,7 +15,7 @@ die() { ssh_version() { eval `${SSH_BIN} -V 2>&1 | sed -n \ 's/OpenSSH_\([0-9]\+\)\.\([0-9]\+\).*/SSH_MAJOR="\1" SSH_MINOR="\2"/p'` 's/OpenSSH_\([0-9]\{1,\}\)\.\([0-9]\{1,\}\).*/SSH_MAJOR="\1" SSH_MINOR="\2"/p'` } platform() { Loading @@ -37,9 +37,12 @@ platform() { } config_sed() { case $PLATFORM in darwin|bsd) SED_WORD_START='[[:<:]]' SED_WORD_END='[[:>:]]'; return ;; esac case "$SHELL" in bash) SED_WORD_DELIM='\b' ;; zsh|sh) SED_WORD_DELIM='\\b' ;; bash) SED_WORD_START='\b' SED_WORD_END='\b' ;; zsh|sh) SED_WORD_START='\\b' SED_WORD_END='\b' ;; esac } Loading Loading @@ -78,7 +81,7 @@ rule_canonisation() { rule_runtime() { # Replace RUNTIME with the value of the RUNTIME variable [ -n "$RUNTIME" ] || die "RUNTIME not set" echo "s!${SED_WORD_DELIM}RUNTIME${SED_WORD_DELIM}!${RUNTIME-.}!g;" echo "s!${SED_WORD_START}RUNTIME${SED_WORD_END}!${RUNTIME-.}!g;" } make_config() { Loading