From d5b591e5471c3108d4c71dc9ff82e8ef06fa4d06 Mon Sep 17 00:00:00 2001 From: Patrick McDermott Date: Mon, 18 Mar 2019 13:31:33 -0400 Subject: ob-unpacksource: Declare local variables --- (limited to 'src') diff --git a/src/ob-unpacksource.sh b/src/ob-unpacksource.sh index a4bb88d..ed82071 100644 --- a/src/ob-unpacksource.sh +++ b/src/ob-unpacksource.sh @@ -56,6 +56,8 @@ get_upstream_archive() get_upstream_compression() { + local z_ext= + z_ext="${upstream_ar#../${upstream_ar_base}}" case "${z_ext}" in '') @@ -88,6 +90,8 @@ get_upstream_compression() get_upstream_dir() { + local dir_count= + upstream_ar_dir="$(tar "-t${upstream_ar_z}f" "${upstream_ar}" | \ sed -n 's|^\(\./\)\{0,1\}\([^/]\{1,\}\).*$|\2|p' | sort | uniq)" dir_count="$(wc -l <<-EOF -- cgit v0.9.1