tidy the $INSTALLKEY_SH code layout a little

SSH-Copy-ID-Upstream: 78178aa5017222773e4c23d9001391eeaeca8983
This commit is contained in:
Philip Hands 2021-02-24 23:43:16 +01:00 committed by Darren Tucker
parent 983e05ef3b
commit 476ac8e9d3
1 changed files with 5 additions and 5 deletions

View File

@ -252,13 +252,13 @@ installkeys_sh() {
cd;
umask 077;
mkdir -p "${AUTH_KEY_DIR}" &&
{ [ -z \`tail -1c ${AUTH_KEY_FILE} 2>/dev/null\` ] || echo >> "${AUTH_KEY_FILE}" || exit 1; } &&
cat >> "${AUTH_KEY_FILE}" ||
exit 1;
{ [ -z \`tail -1c ${AUTH_KEY_FILE} 2>/dev/null\` ] ||
echo >> "${AUTH_KEY_FILE}" || exit 1; } &&
cat >> "${AUTH_KEY_FILE}" || exit 1;
if type restorecon >/dev/null 2>&1; then
restorecon -F "${AUTH_KEY_DIR}" "${AUTH_KEY_FILE}";
restorecon -F "${AUTH_KEY_DIR}" "${AUTH_KEY_FILE}";
fi
EOF
EOF
)
# to defend against quirky remote shells: use 'exec sh -c' to get POSIX;