From 98724d701b10a037e8ffa7ce2864a08993268517 Mon Sep 17 00:00:00 2001 From: Leah Rowe Date: Fri, 14 Jun 2024 13:19:25 +0100 Subject: lib.sh: remove the items() function it's pretty much just doing the same thing as ls -1 remove it! Signed-off-by: Leah Rowe --- include/lib.sh | 13 ------------- include/vendor.sh | 2 +- 2 files changed, 1 insertion(+), 14 deletions(-) (limited to 'include') diff --git a/include/lib.sh b/include/lib.sh index c2ad87ed..a329fa3f 100755 --- a/include/lib.sh +++ b/include/lib.sh @@ -118,19 +118,6 @@ done relname="$projectname-$version" export LOCALVERSION="-$projectname-${version%%-*}" -items() -{ - rval=1 - e "$1" d not && return 1 - for x in "$1/"*; do - # -e used because this is for files *or* directories - [ -e "$x" ] || continue - printf "%s\n" "${x##*/}" 2>/dev/null - rval=0 - done - return $rval -} - scan_config() { awkstr=" /\{.*$1.*}{/ {flag=1;next} /\}/{flag=0} flag { print }" diff --git a/include/vendor.sh b/include/vendor.sh index b2fc5346..b5fda8f3 100755 --- a/include/vendor.sh +++ b/include/vendor.sh @@ -241,7 +241,7 @@ vendor_inject() set +u +e [ $# -lt 1 ] && $err "No options specified." - [ "$1" = "listboards" ] && eval "items config/coreboot || :; exit 0" + [ "$1" = "listboards" ] && eval "ls -1 config/coreboot || :; exit 0" archive="$1" -- cgit v1.2.1