aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKarel Kočí <cynerd@email.cz>2023-11-07 16:08:34 +0100
committerKarel Kočí <cynerd@email.cz>2023-11-07 16:08:34 +0100
commit0f4b741c9a7cb71e8cbb990d3de2db06516e41f1 (patch)
tree677ca530f798c18a9ea634f08d6c1c5f86b3534e
parent5ff16f690a694aa8772aedfcfea5ac50a1187fb2 (diff)
downloadnixos-personal-0f4b741c9a7cb71e8cbb990d3de2db06516e41f1.tar.gz
nixos-personal-0f4b741c9a7cb71e8cbb990d3de2db06516e41f1.tar.bz2
nixos-personal-0f4b741c9a7cb71e8cbb990d3de2db06516e41f1.zip
tools: fix bug when used with cynerd.cz
-rw-r--r--tools/common.sh3
1 files changed, 2 insertions, 1 deletions
diff --git a/tools/common.sh b/tools/common.sh
index a563171..f74f38f 100644
--- a/tools/common.sh
+++ b/tools/common.sh
@@ -45,8 +45,9 @@ sshdest() {
sshhost() {
if [ "$1" = "cynerd.cz" ]; then
echo "lipwig"
+ else
+ awk -F. 'NF > 1 { print $2"-"$1; exit } { print $1 }' <<<"$1"
fi
- awk -F. 'NF > 1 { print $2"-"$1; exit } { print $1 }' <<<"$1"
}
_ssh() {