-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdot_zshrc
More file actions
99 lines (75 loc) · 2.26 KB
/
dot_zshrc
File metadata and controls
99 lines (75 loc) · 2.26 KB
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
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
fastfetch
# Load functions
FUNCTION_DIR=~/.zsh_functions
# Load all function scripts from the directory
for func_file in $FUNCTION_DIR/*.sh; do
source $func_file
done
HISTFILE=~/.history
HISTSIZE=10000
SAVEHIST=50000
setopt inc_append_history
autoload -Uz compinit && compinit
# Aliases
## This ensures vscode doesn't open multiple times
alias code="open -b com.microsoft.VSCode"
# alias python="python3"
## ---------git----------
alias gp="git pull"
alias gpp="git push"
alias gs="git switch"
alias gsc="git switch -C"
alias gc="git commit -m"
alias gca="git add . && git commit -m"
alias gclean="git reset --hard && git clean -fd"
alias dev="gs dev && gp"
alias main='
cd "$(git rev-parse --show-toplevel)" &&
if git show-ref --quiet refs/heads/main; then
gs main
elif git show-ref --quiet refs/heads/master; then
gs master
else
echo >&2 "Neither main nor master branch exists."
exit 1
fi
gp
'
# Variables
export EDITOR="vim"
export SUDO_EDITOR="$EDITOR"
## $PATH Configs
export PATH="${HOME}/bin:${PATH}"
export PATH="/opt/homebrew/opt/libpq/bin:$PATH"
export PATH="/opt/homebrew/opt/openjdk/bin:$PATH"
export PATH="${HOME}/.local/bin:$PATH"
export PATH="/Users/aidencline/.cargo/bin:$PATH"
export LDFLAGS="-L/opt/homebrew/opt/libpq/lib"
export CPPFLAGS="-I/opt/homebrew/opt/libpq/include"
export PATH="/opt/homebrew/opt/libpq/bin:$PATH"
## go specific path cfg
export GOPATH="$HOME/go"
export PATH="$GOPATH/bin:$PATH"
# GOPRIVATE is defined in .zshenv
## java specifc path cfg
# export JAVA_HOME="/opt/homebrew/opt/openjdk@11/libexec/openjdk.jdk/Contents/Home"
export JAVA_HOME="$(brew --prefix openjdk@17)"
export PATH="$JAVA_HOME/bin:$PATH"
# Tooling configurations
eval "$(starship init zsh)"
eval "$(zoxide init zsh)"
eval "$(pyenv init --path)"
## FZF
# source <(fzf --zsh)
[ -f ~/.fzf.zsh ] && source ~/.fzf.zsh
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion
# sst
export PATH=/Users/aidencline/.sst/bin:$PATH
# bun completions
[ -s "/Users/aidencline/.bun/_bun" ] && source "/Users/aidencline/.bun/_bun"
# bun
export BUN_INSTALL="$HOME/.bun"
export PATH="$BUN_INSTALL/bin:$PATH"
source ~/.zshenv