-
Notifications
You must be signed in to change notification settings - Fork 0
/
.zshrc
80 lines (69 loc) · 1.61 KB
/
.zshrc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
# Path
eval "$(/opt/homebrew/bin/brew shellenv)"
# Terminal Colors
export CLICOLOR=1
export LSCOLORS=GxFxCxDxBxegedabagaced
# Prompt
hash "git-radar" 2>/dev/null && {
export PS1=$'%B%F{green}→%B%F %B%F{cyan}$(basename "\$(pwd)")/%B%F\$(git-radar --zsh --fetch) '
}
# Include local bin
export PATH="/usr/local/bin:$PATH"
export PATH="/usr/local/sbin:$PATH"
# dotfiles
function dotfiles {
if [[ $@ == "install" ]]; then
command bash "$HOME/.install/install.bash"
else
command git --git-dir="$HOME/.dotfiles" --work-tree="$HOME" "$@"
fi
}
dotfiles config status.showUntrackedFiles no
# thefuck
hash "thefuck" 2>/dev/null && {
eval "$(thefuck --alias)"
}
# asdf
export ASDF_DATA_DIR="$HOME/.asdf"
export ASDF_GROOVY_DISABLE_JAVA_HOME_EXPORT=true
hash "asdf" 2>/dev/null && {
source "$(brew --prefix asdf)/libexec/asdf.sh"
test -s "$ASDF_DATA_DIR/plugins/dotnet/set-dotnet-home.zsh" && {
source "$ASDF_DATA_DIR/plugins/dotnet/set-dotnet-home.zsh"
}
test -s "$ASDF_DATA_DIR/plugins/java/set-java-home.zsh" && {
source "$ASDF_DATA_DIR/plugins/java/set-java-home.zsh"
}
}
# direnv
hash "direnv" 2>/dev/null && {
eval "$(direnv hook zsh)"
}
# podman
alias docker=podman
alias docker-compose=podman-compose
# Visual Studio Code
alias code="open -b com.microsoft.VSCode"
# Oh My Zsh
export ZSH="$HOME/.oh-my-zsh"
test -s "$ZSH/oh-my-zsh.sh" && {
plugins=(
asdf
thefuck
bundler
docker
dotnet
git
golang
node
npm
python
ruby
vscode
xcode
zsh-autosuggestions
zsh-syntax-highlighting
zsh-history-substring-search
)
source "$ZSH/oh-my-zsh.sh"
}