From e8d0a820cf455cb577b85d74869c0e8ddeaf4cb0 Mon Sep 17 00:00:00 2001 From: Alexander Couzens Date: Sat, 23 Jul 2016 02:04:41 +0200 Subject: openwrt_common/save_lede_results: fix last path/popd/pushd bugs Signed-off-by: Holger Levsen --- bin/reproducible_openwrt_common.sh | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) (limited to 'bin/reproducible_openwrt_common.sh') diff --git a/bin/reproducible_openwrt_common.sh b/bin/reproducible_openwrt_common.sh index 34226ddf..70f811f8 100644 --- a/bin/reproducible_openwrt_common.sh +++ b/bin/reproducible_openwrt_common.sh @@ -34,7 +34,7 @@ save_logs() { save_lede_results() { RUN=$1 - cd bin/targets + pushd bin/targets for target in * ; do pushd $target || continue for subtarget in * ; do @@ -55,21 +55,27 @@ save_lede_results() { done popd fi + popd done popd done + popd # arch is like mips_34kc_dsp - popd bin/packages/ + pushd bin/packages/ for arch in * ; do pushd $arch || continue - for package in $(find * -name "*.ipk") ; do - mkdir -p $TMPDIR/$RUN/packages/$arch/$(dirname $package) - cp -p $package $TMPDIR/$RUN/packages/$arch/$(dirname $package)/ + for feed in * ; do + pushd $feed || continue + for package in $(find * -name "*.ipk") ; do + mkdir -p $TMPDIR/$RUN/packages/$arch/$feed/$(dirname $package) + cp -p $package $TMPDIR/$RUN/packages/$arch/$feed/$(dirname $package)/ + done + popd done popd done - pushd + popd } save_openwrt_results() { -- cgit v1.2.3-70-g09d2