From afc604c4c9c91febde2a313f731ff59974a533d5 Mon Sep 17 00:00:00 2001 From: Hiltjo Posthuma Date: Fri, 5 Feb 2021 01:25:53 +0100 Subject: sfeed_update: $SFEED_UPDATE_INCLUDE: be a bit more precise/pedantic --- README | 2 +- sfeed_update | 2 +- sfeed_update.1 | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/README b/README index 209aa3b..2292902 100644 --- a/README +++ b/README @@ -645,7 +645,7 @@ sfeed_update_xargs shellscript: # process a single feed. # args are: config, tmpdir, name, feedurl, basesiteurl, encoding - if [ "${SFEED_UPDATE_CHILD}" != "" ]; then + if [ "${SFEED_UPDATE_CHILD}" = "1" ]; then sfeedtmpdir="$2" _feed "$3" "$4" "$5" "$6" exit $? diff --git a/sfeed_update b/sfeed_update index d153d8a..7d11f18 100755 --- a/sfeed_update +++ b/sfeed_update @@ -212,4 +212,4 @@ main() { exit 0 } -[ "${SFEED_UPDATE_INCLUDE}" != "" ] || main "$@" +[ "${SFEED_UPDATE_INCLUDE}" = "1" ] || main "$@" diff --git a/sfeed_update.1 b/sfeed_update.1 index c3274ee..897bf1f 100644 --- a/sfeed_update.1 +++ b/sfeed_update.1 @@ -1,4 +1,4 @@ -.Dd January 27, 2021 +.Dd February 5, 2021 .Dt SFEED_UPDATE 1 .Os .Sh NAME @@ -47,7 +47,7 @@ The feedname cannot contain '/' characters, they will be replaced with '_'. .Sh ENVIRONMENT VARIABLES .Bl -tag -width Ds .It SFEED_UPDATE_INCLUDE -When set with a value +When set to "1" .Nm can be sourced as a script, but it won't run the .Fn main -- cgit v1.2.3