From 3d976d8e844a15d39e81346500a2f419fa8165a2 Mon Sep 17 00:00:00 2001 From: Buddy Sandidge Date: Wed, 23 Dec 2020 11:52:42 -0800 Subject: [PATCH] Add zsh config to base package --- base-osx/.config/bash/bashrc.d/base-osx.sh | 3 --- base-osx/.config/bash/env.d/base-osx.env | 2 ++ base-osx/.config/profile/env.d/base-osx.env | 2 ++ base/.config/zsh/zshrc.d/base.sh | 3 +++ base/.zshrc | 19 +++++++++++++++++++ .../.config/bash/env.d/hellotech-config.env | 1 - starship/.config/zsh/zshrc.d/prompt.sh | 1 + 7 files changed, 27 insertions(+), 4 deletions(-) delete mode 100644 base-osx/.config/bash/bashrc.d/base-osx.sh create mode 100644 base-osx/.config/bash/env.d/base-osx.env create mode 100644 base-osx/.config/profile/env.d/base-osx.env create mode 100644 base/.config/zsh/zshrc.d/base.sh create mode 100644 base/.zshrc create mode 100644 starship/.config/zsh/zshrc.d/prompt.sh diff --git a/base-osx/.config/bash/bashrc.d/base-osx.sh b/base-osx/.config/bash/bashrc.d/base-osx.sh deleted file mode 100644 index ce07973..0000000 --- a/base-osx/.config/bash/bashrc.d/base-osx.sh +++ /dev/null @@ -1,3 +0,0 @@ -#ft=bash - -alias ls='ls -G' diff --git a/base-osx/.config/bash/env.d/base-osx.env b/base-osx/.config/bash/env.d/base-osx.env new file mode 100644 index 0000000..0e6ad46 --- /dev/null +++ b/base-osx/.config/bash/env.d/base-osx.env @@ -0,0 +1,2 @@ +#shellcheck disable=SC2034 +BASH_SILENCE_DEPRECATION_WARNING=1 diff --git a/base-osx/.config/profile/env.d/base-osx.env b/base-osx/.config/profile/env.d/base-osx.env new file mode 100644 index 0000000..19a711f --- /dev/null +++ b/base-osx/.config/profile/env.d/base-osx.env @@ -0,0 +1,2 @@ +#shellcheck disable=SC2034 +CLICOLOR=1 diff --git a/base/.config/zsh/zshrc.d/base.sh b/base/.config/zsh/zshrc.d/base.sh new file mode 100644 index 0000000..2015f76 --- /dev/null +++ b/base/.config/zsh/zshrc.d/base.sh @@ -0,0 +1,3 @@ +setopt autocd +setopt autopushd +setopt pushdignoredups diff --git a/base/.zshrc b/base/.zshrc new file mode 100644 index 0000000..d43eda2 --- /dev/null +++ b/base/.zshrc @@ -0,0 +1,19 @@ +if [[ -d "${XDG_CONFIG_HOME}/zsh/env.d" ]]; then + for file in "${XDG_CONFIG_HOME}"/zsh/env.d/*.env(N); do + eval "$( + grep -v '^\s*\#' "${file}" | + grep -v '^\s*$' | + sed 's/^\s*export//g' | + sed 's/^/export /g' + )" + done +fi + +if [ -d "${XDG_CONFIG_HOME}/zsh/zshrc.d" ]; then + for file in "${XDG_CONFIG_HOME}"/zsh/zshrc.d/*.sh(N); do + if [ -r "$file" ]; then + #shellcheck disable=1090 + . "$file" + fi + done +fi diff --git a/hellotech/.config/bash/env.d/hellotech-config.env b/hellotech/.config/bash/env.d/hellotech-config.env index 345ba64..9a8ccf9 100644 --- a/hellotech/.config/bash/env.d/hellotech-config.env +++ b/hellotech/.config/bash/env.d/hellotech-config.env @@ -1,3 +1,2 @@ # shellcheck disable=SC2034 -BASH_SILENCE_DEPRECATION_WARNING=1 PATH="${PATH}:${HOME}/.rbenv/shims:/usr/local/opt/mysql-client/bin:${HOME}/google-cloud-sdk/bin" diff --git a/starship/.config/zsh/zshrc.d/prompt.sh b/starship/.config/zsh/zshrc.d/prompt.sh new file mode 100644 index 0000000..af75929 --- /dev/null +++ b/starship/.config/zsh/zshrc.d/prompt.sh @@ -0,0 +1 @@ +eval "$(starship init zsh)"