diff options
author | Einhard Leichtfuß <alguien@respiranto.de> | 2018-12-25 17:04:47 +0100 |
---|---|---|
committer | Einhard Leichtfuß <alguien@respiranto.de> | 2018-12-25 17:09:43 +0100 |
commit | 0dd0716c761e328292bf8aac1b15edbdc4f73d2e (patch) | |
tree | bbc60135e23ba0fb31239123b5614719bf7d63dd /bash_completion.in | |
parent | 194052e67ed30121d7b66e8e7db559a32d001dab (diff) |
Globally use the same (default_)user_config_dir
Also,
- Fix issues with doubled slashes in man pages (in configure.ac).
- Update some copyright years.
Diffstat (limited to 'bash_completion.in')
-rw-r--r-- | bash_completion.in | 19 |
1 files changed, 8 insertions, 11 deletions
diff --git a/bash_completion.in b/bash_completion.in index a8fa219..eb6eb10 100644 --- a/bash_completion.in +++ b/bash_completion.in @@ -2,7 +2,7 @@ # # bash completion script for ctct # -# Copyright 2015 - 2017 Einhard Leichtfuß +# Copyright 2015 - 2018 Einhard Leichtfuß # # This file is part of ctct. # @@ -23,21 +23,18 @@ _ctct() { ## DEFAULT SETTINGS: + local sysconfdir="@sysconfdir_expanded@" + local user_config_file="@default_user_config_file@" local datadir="@default_datadir@" - local system_config_dir="@default_confdir@" - local user_config_dir="@default_user_config_dir@" local temp ## USER SETTINGS: - temp=$( - test -f "$system_config_dir/config.sh" \ - && source "$system_config_dir/config.sh" - test -f "$user_config_dir/config.sh" \ - && source "$user_config_dir/config.sh" - echo "$datadir" - ) - test -n "$temp" && datadir="$temp" + test -f "$sysconfdir/ctct_config" \ + && source "$sysconfdir/ctct_config" + test -f "$user_config_file" \ + && source "$user_config_file" + echo "$datadir" local cur action opts typeset -i i |