aboutsummaryrefslogtreecommitdiffstats
path: root/openssh
diff options
context:
space:
mode:
authorMattias Andrée <maandree@kth.se>2021-06-25 19:56:42 +0200
committerMattias Andrée <maandree@kth.se>2021-06-25 19:56:42 +0200
commit6b685712464160dc4eadaaf16443878105e3e581 (patch)
tree938fdd00cd5df24981d21756020e0894504be6bf /openssh
parentAdd git config (diff)
downloaddotfiles-6b685712464160dc4eadaaf16443878105e3e581.tar.gz
dotfiles-6b685712464160dc4eadaaf16443878105e3e581.tar.bz2
dotfiles-6b685712464160dc4eadaaf16443878105e3e581.tar.xz
Link ~/.ssh to ~/.dotfiles/.secrets/ssh
Signed-off-by: Mattias Andrée <maandree@kth.se>
Diffstat (limited to '')
-rw-r--r--openssh/Makefile7
1 files changed, 7 insertions, 0 deletions
diff --git a/openssh/Makefile b/openssh/Makefile
index ed19c6f..6da1915 100644
--- a/openssh/Makefile
+++ b/openssh/Makefile
@@ -2,6 +2,13 @@
include ../common.mk
install:
+ if test -L ~/.ssh; then \
+ test "$$(readlink -- ~/.ssh)" = ~/.dotfiles/.secrets/ssh; \
+ else \
+ test ! -e ~/.ssh && \
+ ln -sf -- ~/.dotfiles/.secrets/ssh ~/.ssh; \
+ fi
+ mkdir -p -- ../.secrets/ssh
mkdir -p -- ~/.config/bash/aliases.d
test ! -d ~/.config/bash/aliases.d/openssh
ln -sf -- ~/.dotfiles/openssh/bash-aliases ~/.config/bash/aliases.d/openssh