From 0557a572a39b65d22ff78b1927d7506b956be457 Mon Sep 17 00:00:00 2001 From: "xiongdian.me" Date: Mon, 6 Nov 2023 17:04:19 +0800 Subject: [PATCH] riot: fix ci; install.sh: --no-ssh --- install.sh | 4 ++++ tools/test.zsh | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/install.sh b/install.sh index e44a337..7ecdc94 100755 --- a/install.sh +++ b/install.sh @@ -149,6 +149,9 @@ install_symlink() { fmt_note "installing symlinks ..." for ((i=0; i<${#HOME_SYMLINKS_SRC[@]}; i++)); do + if [[ -z "${HOME_SYMLINKS_SRC[$i]}" ]]; then + continue + fi local src="$DOTFILES/${HOME_SYMLINKS_SRC[$i]}" local dst="$HOME/${HOME_SYMLINKS_DST[$i]}" fmt_info "creating symlink \"$dst\" --> \"$src\" ..." @@ -327,6 +330,7 @@ for i in ${GOT_OPTS[@]}; do -a|--auto ) INSTALL_DEP=1 ;; -H|--hist|--history ) store_hist=1 ;; -x ) store_config=1 ;; + --no-ssh ) unset HOME_SYMLINKS_SRC[0]; unset HOME_SYMLINKS_DST[0] ;; * ) fmt_fatal "unknown option \"$i\"" ;; esac done diff --git a/tools/test.zsh b/tools/test.zsh index 96b49ed..07f38c8 100644 --- a/tools/test.zsh +++ b/tools/test.zsh @@ -38,7 +38,7 @@ test $(echo n | tools/common.sh ask_for_yN "test") = "0" test $(echo | tools/common.sh ask_for_yN "test") = "0" test $(echo | tools/common.sh ask_for_Yn "test") = "1" test $(DFS_QUIET=1 tools/common.sh ask_for_Yn "test") = "1" -test "$(DFS_TRUST=1 riot time@is.impt:2222,yes@you-r.right,you@are.really.recht.,ibd.,try@it scp /tmp/ ./tmp -D 2>/dev/null)" = 'scp -P 12022 -o ControlMaster=auto -o ControlPath=/tmp/sshcm-%C -o PermitLocalCommand=yes -o ProxyJump=time@is.impt:2222,yes@you-r.right,you@are.really.recht.,ibd. -r try@it.ibd.ink:"/tmp/" "./tmp"' +test "$(DFS_TRUST=1 riot time@is.impt:2222/yes@you-r.right/you@are.really.recht./ibd./try@it scp /tmp/ ./tmp -D 2>/dev/null)" = 'scp -P 12022 -o ControlMaster=auto -o ControlPath=/tmp/sshcm-%C -o PermitLocalCommand=yes -o ProxyJump=time@is.impt:2222,yes@you-r.right,you@are.really.recht.,ibd. -r try@it.ibd.ink:"/tmp/" "./tmp"' # check alias alias p114