fetchmailrc split: ignore commented lines (#2305)

Co-authored-by: Robert Schumann <robert@schumann.link>
Co-authored-by: Georg Lauterbach <44545919+georglauterbach@users.noreply.github.com>
This commit is contained in:
Robert Schumann 2021-11-29 15:24:38 +01:00 committed by GitHub
parent 7bf1b7eea4
commit b11e5ffd1a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -49,6 +49,7 @@ do
# Just the server settings that need to be added to the specific rc.d file
echo "${LINE}" >> "${FETCHMAILRCD}/fetchmail-${COUNTER}.rc"
fi
done < "${FETCHMAILRC}"
# delete commented lines before parsing
done < <(sed '/^[[:space:]]*#/d' "${FETCHMAILRC}")
rm "${DEFAULT_FILE}"