fix for multiple ssh keys

This commit is contained in:
Joao Jacome 2020-03-07 17:41:19 +00:00
parent 632716f908
commit a814bc8eaf

View file

@ -1,3 +1,12 @@
#!/bin/sh #!/bin/bash
(
KEYS=$(/usr/bin/env python ssh.py) KEYS=$(/usr/bin/env python ssh.py)
ssh-add - <<< "${KEYS}" IFS=';'
read -d '' -ra SPLITKEYS < <(printf '%s;\0' "$KEYS")
for i in ${SPLITKEYS[@]}
do
ssh-add - <<< "${i}"
done
)