!0 instead of 1

This commit is contained in:
TheSpad 2023-11-11 20:02:44 +00:00
parent 6be18c0df7
commit 09726961fd
No known key found for this signature in database
GPG key ID: 08F06191F4587860

View file

@ -6,7 +6,7 @@ if find /run/s6/container_environment/FILE__* -maxdepth 1 > /dev/null 2>&1; then
SECRETFILE=$(cat "${FILENAME}") SECRETFILE=$(cat "${FILENAME}")
if [[ -f ${SECRETFILE} ]]; then if [[ -f ${SECRETFILE} ]]; then
FILESTRIP=${FILENAME//FILE__/} FILESTRIP=${FILENAME//FILE__/}
if [[ $(tail -n1 "${SECRETFILE}" | wc -l) = 1 ]]; then if [[ $(tail -n1 "${SECRETFILE}" | wc -l) != 0 ]]; then
echo "[env-init] Your secret: ${FILENAME##*/}" echo "[env-init] Your secret: ${FILENAME##*/}"
echo " contains a trailing newline and may not work as expected" echo " contains a trailing newline and may not work as expected"
fi fi