From 11c47ba7dd76f013f34429ff7b44f0a07ed40211 Mon Sep 17 00:00:00 2001 From: Leah Rowe Date: Fri, 7 Jun 2024 12:55:30 +0100 Subject: git.sh: reduced indentation in prep_submodules Signed-off-by: Leah Rowe --- include/git.sh | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) (limited to 'include') diff --git a/include/git.sh b/include/git.sh index 8af1f0d5..7f4af0c4 100755 --- a/include/git.sh +++ b/include/git.sh @@ -106,12 +106,10 @@ prep_submodules() mdir="$PWD/config/submodule/$project" [ -n "$tree" ] && mdir="$mdir/$tree" - if [ -f "$mdir/module.list" ]; then - cat "$mdir/module.list" > "$tmpdir/modules" || \ - $err "!cp $mdir/module.list $tmpdir/modules" - else - return 0 - fi + [ -f "$mdir/module.list" ] || return 0 + + cat "$mdir/module.list" > "$tmpdir/modules" || \ + $err "!cp $mdir/module.list $tmpdir/modules" while read -r msrcdir; do fetch_submodule "$msrcdir" -- cgit v1.2.1