diff options
-rw-r--r-- | src/ob-unpacksource.sh | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/ob-unpacksource.sh b/src/ob-unpacksource.sh index a603393..2454189 100644 --- a/src/ob-unpacksource.sh +++ b/src/ob-unpacksource.sh @@ -107,8 +107,8 @@ get_upstream_compression() get_upstream_dir() { - upstream_ar_dir="$(tar "-t${upstream_ar_z}f" \ - "${upstream_ar}" | sed -n 's@^\(\./\|\)\([^/]*\)\(/\|\)$@\2@p')" + upstream_ar_dir="$(tar "-t${upstream_ar_z}f" "${upstream_ar}" | \ + sed -n 's@^\(\./\|\)\([^/]*\)\(/\|\).*$@\2@p' | sort | uniq)" case "$(echo "${upstream_ar_dir}" | grep -v '^$' | wc -l)" in 0) ob_error "$(ob_get_msg 'no_upstream_dirs')" |