Update .local/share/chezmoi/home/dot_ssh/run_onchanges_after_generate-public-keys.tmpl
This commit is contained in:
parent
b9ba477155
commit
ca3430f750
1 changed files with 2 additions and 2 deletions
|
@ -10,11 +10,11 @@
|
|||
{{- includeTemplate "universal/profile" }}
|
||||
{{- includeTemplate "universal/logg" }}
|
||||
|
||||
logg 'Ensuring RSA public keys are present'
|
||||
logg info 'Ensuring RSA public keys are present'
|
||||
|
||||
find "$HOME/.ssh" -type f | while read FILE; do
|
||||
if [ ! -f "${FILE}" ] && cat "$FILE" | grep 'BEGIN RSA PRIVATE KEY'; then
|
||||
logg 'Generating missing public key for `'"$FILE"'`'
|
||||
logg info 'Generating missing public key for `'"$FILE"'`'
|
||||
ssh-keygen -f "$FILE" -y > "${FILE}.pub"
|
||||
fi
|
||||
done
|
||||
|
|
Loading…
Reference in a new issue