From ad9fd71b36593a7d168c5917eb59bbbf2c4231b9 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Mon, 1 Jun 2009 11:04:13 +0200 Subject: pkg: Set default value for XDG_CONFIG_HOME --- bin/pkg | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/bin/pkg b/bin/pkg index 172c648..aed46a6 100755 --- a/bin/pkg +++ b/bin/pkg @@ -70,8 +70,9 @@ function clear_line { } # Read local configuration -if [[ -r ${XDG_CONFIG_HOME-$HOME/.config/pkg/pkg.conf} ]] { - source ${XDG_CONFIG_HOME-$HOME/.config/pkg/pkg.conf} +: ${XDG_CONFIG_HOME=$HOME/.config} +if [[ -r $XDG_CONFIG_HOME/pkg/pkg.conf ]] { + source $XDG_CONFIG_HOME/pkg/pkg.conf } elif [[ -r $HOME/.pkg.conf ]] { source $HOME/.pkg.conf } -- cgit v1.2.3