summaryrefslogtreecommitdiff
path: root/pkgbuild-check-nonfree
diff options
context:
space:
mode:
authorJoshua Ismael Haase Hernández <hahj87@gmail.com>2011-07-19 14:50:29 -0500
committerJoshua Ismael Haase Hernández <hahj87@gmail.com>2011-07-19 14:50:29 -0500
commitf3cfc59e0e4c6d27be065cee49ca3e133d045bdd (patch)
treeb4ec42dc33305d1d45bed2afacaa2c7aab08245a /pkgbuild-check-nonfree
parent394783a7fda0f1fb587416d54af563730bff939c (diff)
Some fixing
Diffstat (limited to 'pkgbuild-check-nonfree')
-rwxr-xr-xpkgbuild-check-nonfree11
1 files changed, 4 insertions, 7 deletions
diff --git a/pkgbuild-check-nonfree b/pkgbuild-check-nonfree
index b7c1237..55976a8 100755
--- a/pkgbuild-check-nonfree
+++ b/pkgbuild-check-nonfree
@@ -33,6 +33,7 @@ function in_array { # usage : in_array( $needle, $haystack )
function get_blacklist { # Download the blacklist.
+ pushd $XDG_CONFIG_HOME/libretools/ >/dev/null
msg "Downloading the blacklist of proprietary software packages."
wget -N -q -O blacklist.txt "${BLACKLIST}" 2>/dev/null || {
[ -e $XDG_CONFIG_HOME/libretools/blacklist.txt ] || {
@@ -41,6 +42,7 @@ function get_blacklist { # Download the blacklist.
}
warning "Using local copy of blacklist"
}
+ popd > /dev/null
}
function check_deps { # Check wheter a package depends on non-free
@@ -68,15 +70,11 @@ function check_deps { # Check wheter a package depends on non-free
fi
fi
done
-
- return $ev
}
source /etc/libretools.conf
-if [ -z $XDG_CONFIG_HOME ]; then # Avoid /libretools dir doesn't exist errors
- error "There's no XDG_CONFIG_HOME var set"; exit 1
-elif [ -e $XDG_CONFIG_HOME/libretools/libretools.conf ]; then
+if [ -e $XDG_CONFIG_HOME/libretools/libretools.conf ]; then
source $XDG_CONFIG_HOME/libretools/libretools.conf
fi
@@ -98,5 +96,4 @@ get_blacklist
check_deps
-exit $?
-
+exit $ev