From b11e5ffd1a36244fa90416df49c43fe93a4a013a Mon Sep 17 00:00:00 2001 From: Robert Schumann Date: Mon, 29 Nov 2021 15:24:38 +0100 Subject: [PATCH] fetchmailrc split: ignore commented lines (#2305) Co-authored-by: Robert Schumann Co-authored-by: Georg Lauterbach <44545919+georglauterbach@users.noreply.github.com> --- target/bin/fetchmailrc_split | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/target/bin/fetchmailrc_split b/target/bin/fetchmailrc_split index 9f9d1647..d0edb1ea 100755 --- a/target/bin/fetchmailrc_split +++ b/target/bin/fetchmailrc_split @@ -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}"