Unify gsu_dir handling.
[gsu.git] / config
diff --git a/config b/config
index 09330f3..7667cf5 100644 (file)
--- a/config
+++ b/config
@@ -79,7 +79,7 @@ gsu_check_options_or_die()
 }
 
 if [[ "$(type -t _gsu_setup)" != "function" ]]; then
-       gsu_dir=${gsu_dir:=${HOME:-}/.gsu}
+       gsu_dir=${gsu_dir:-${BASH_SOURCE[0]%/*}}
        . $gsu_dir/common || exit 1
        _gsu_setup
 fi