diff options
Diffstat (limited to 'pkgbuild-check-nonfree')
-rwxr-xr-x | pkgbuild-check-nonfree | 11 |
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 |