summaryrefslogtreecommitdiff
path: root/functions/cache.sh
diff options
context:
space:
mode:
authorDaniel Baumann <daniel@debian.org>2007-09-23 10:05:11 +0200
committerDaniel Baumann <daniel@debian.org>2011-03-09 18:18:30 +0100
commit85c342c299231131d22764c0dfdcf977c57ce147 (patch)
tree1226c8a7ad43a2dd53e411c2e379969424e88e32 /functions/cache.sh
parentd1ee66e44c8272bb7a0053a456a3d8b0bd152268 (diff)
downloadvyos-live-build-85c342c299231131d22764c0dfdcf977c57ce147.tar.gz
vyos-live-build-85c342c299231131d22764c0dfdcf977c57ce147.zip
Adding live-helper 1.0~a13-1.
Diffstat (limited to 'functions/cache.sh')
-rwxr-xr-xfunctions/cache.sh7
1 files changed, 2 insertions, 5 deletions
diff --git a/functions/cache.sh b/functions/cache.sh
index 94d6bc2bc..d83b7e1b1 100755
--- a/functions/cache.sh
+++ b/functions/cache.sh
@@ -32,13 +32,10 @@ Save_cache ()
# Cleaning current cache
Chroot "apt-get autoclean"
- if ls chroot/var/cache/apt/archives/*.deb &> /dev/null
+ if ls chroot/var/cache/apt/archives/*.deb > /dev/null 2>&1
then
# Creating cache directory
- if [ ! -d "${DIRECTORY}" ]
- then
- mkdir -p "${DIRECTORY}"
- fi
+ mkdir -p "${DIRECTORY}"
# Saving new cache
mv -f chroot/var/cache/apt/archives/*.deb "${DIRECTORY}"