diff --git a/modules/git/gitconfig b/modules/git/gitconfig index f95ca34..bfeb6fe 100644 --- a/modules/git/gitconfig +++ b/modules/git/gitconfig @@ -235,8 +235,6 @@ # https://github.com/git/git/blob/90f7b16b3adc78d4bbabbd426fb69aa78c714f71/Documentation/config.txt#L2847-L2855 useConfigOnly = true - email = daniel@hails.info - name = Daniel Hails # [!] DO NOT store sensitive information such as the Git user # credentials (`name` / `email`), or things such as the `signingkey` diff --git a/modules/git/setup.github.sh b/modules/git/setup.github.sh index ae2a682..c3fe44d 100644 --- a/modules/git/setup.github.sh +++ b/modules/git/setup.github.sh @@ -88,7 +88,7 @@ github::get_gpg_key_id() { gpgKeyId="$(gpg --list-secret-keys --keyid-format LONG \ | grep git-auto -B 2 \ | grep sec \ - | perl -nle 'print && while m{(?<=/)[A-Z0-9]{16}}g')" + | perl -nle 'print $& while m{(?<=/)[A-Z0-9]{16}}g')" } github::set_gpg_key() { diff --git a/modules/zsh/zshenv b/modules/zsh/zshenv index 4c1c5f9..50fc000 100644 --- a/modules/zsh/zshenv +++ b/modules/zsh/zshenv @@ -7,4 +7,4 @@ for i in ${fpath[@]}; do fi done -. "$HOME/.cargo/env" +[[ -f "$HOME/.cargo/env" ]] && . "$HOME/.cargo/env" diff --git a/scripts/link.sh b/scripts/link.sh index 8624c8c..40f61c7 100644 --- a/scripts/link.sh +++ b/scripts/link.sh @@ -69,17 +69,11 @@ link::file () { } link::extract_and_link() { - declare -A links local sep=' -> ' - while read line + while read -r line || [[ -n "$line" ]] do - src=${line%%$sep*} - dst=${line#*$sep} - links[$src]=$dst - done < $1 - - for src in ${!links[*]} - do - link::file "$(dirname $1)/$src" "${links[$src]/#\~/$HOME}" - done + local src=${line%%$sep*} + local dst=${line#*$sep} + link::file "$(dirname "$1")/$src" "${dst/#\~/$HOME}" + done < "$1" }