decidedly
authorThierry Parmentelat <thierry.parmentelat@inria.fr>
Fri, 8 Feb 2013 09:13:30 +0000 (10:13 +0100)
committerThierry Parmentelat <thierry.parmentelat@inria.fr>
Fri, 8 Feb 2013 09:13:30 +0000 (10:13 +0100)
partial-repo.sh

index a41ced1..06da266 100755 (executable)
@@ -14,7 +14,7 @@ case "$1" in *-h*) usage ;; esac
 set -e 
 
 for rpms_dir in $(find "$@" -name RPMS) ; do
-    cd $rpms_dir
+    pushd $rpms_dir >& /dev/null
     cd ..
     echo "==================== Dealing with repo $(pwd)"
     mkdir -p PARTIAL-RPMS
@@ -22,5 +22,5 @@ for rpms_dir in $(find "$@" -name RPMS) ; do
     echo "==================== building packages index in $(pwd) .."
     createrepo PARTIAL-RPMS
     echo '==================== DONE'
-    cd - >& /dev/null
+    popd >& /dev/null
 done