diff options
author | Daniel Baumann <daniel@debian.org> | 2010-04-02 17:48:03 +0200 |
---|---|---|
committer | Daniel Baumann <daniel@debian.org> | 2010-04-09 21:28:42 +0200 |
commit | 9fdf028aa8e6a5e752bda5c33ef71dbf6c3b4480 (patch) | |
tree | 737df366cba90333966e404100002c8a1885b36e /helpers/bootstrap_debootstrap | |
parent | 2b25d825faa06e6889f41122cf14706a473154b8 (diff) | |
download | vyos-live-build-9fdf028aa8e6a5e752bda5c33ef71dbf6c3b4480.tar.gz vyos-live-build-9fdf028aa8e6a5e752bda5c33ef71dbf6c3b4480.zip |
Making handling of cache/packages_bootstrap a bit more error proove, thanks to Michal Suchanek <michal.suchanek@ruk.cuni.cz> for bringing it up.
Diffstat (limited to 'helpers/bootstrap_debootstrap')
-rwxr-xr-x | helpers/bootstrap_debootstrap | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/helpers/bootstrap_debootstrap b/helpers/bootstrap_debootstrap index 2b708ba4c..d7662fa39 100755 --- a/helpers/bootstrap_debootstrap +++ b/helpers/bootstrap_debootstrap @@ -116,7 +116,7 @@ if [ -x "/usr/sbin/debootstrap" ] then if [ "${LH_CACHE_PACKAGES}" = "true" ] then - if [ -d cache/packages_bootstrap ] + if ls cache/packages_bootstrap/*.deb > /dev/null 2>&1 then mkdir -p chroot/var/cache/apt/archives cp cache/packages_bootstrap/*.deb chroot/var/cache/apt/archives @@ -131,14 +131,10 @@ then fi # Removing old cache - if [ -d cache/packages_bootstrap ] - then - rm -f cache/packages_bootstrap/*.deb - fi + rm -f cache/packages_bootstrap/*.deb # Saving new cache mkdir -p cache/packages_bootstrap - cp chroot/var/cache/apt/archives/*.deb cache/packages_bootstrap fi |