]> git.pld-linux.org Git - packages/rpm.git/commitdiff
- skip if required tools missing
authorElan Ruusamäe <glen@pld-linux.org>
Wed, 20 Feb 2008 16:47:04 +0000 (16:47 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    rpm-hrmib-cache -> 1.4

rpm-hrmib-cache

index 1f96c6e53d6d644ad1dd2a45eeecffbf15ce220a..37363f36e25f3ca150a114834bd92da339b960f3 100644 (file)
@@ -1,9 +1,12 @@
 #!/bin/sh
+# skip if no rpm(1) or touch(1)
+[ -x /bin/rpm -a -x /bin/touch ] || exit 0
+
 export LC_ALL=C
 umask 002
 
 mydir=/var/cache/hrmib
-mkdir -p $mydir || exit 1
+mkdir -p $mydir || exit 0
 rm -f $mydir/*
 
 buf=$(rpm --nodigest --nosignature  -qa --qf '%{name}-%{version}-%{release}.%{arch} %{installtime:date}\n')
@@ -17,3 +20,5 @@ echo "$buf" | while read nvra idate; do
    esac
 done
 touch $mydir
+
+exit 0
This page took 0.415116 seconds and 4 git commands to generate.