-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy path.zshrc
44 lines (35 loc) · 891 Bytes
/
.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
# Minimal ZSH config
# Shell history
HISTFILE="$HOME/.local/share/zsh_history"
HISTSIZE=10000
SAVEHIST=20000
# All zsh sessions share history
setopt share_history
setopt append_history
setopt inc_append_history
setopt hist_reduce_blanks
# Tab completion
autoload -Uz compinit && compinit
setopt complete_in_word
setopt auto_menu
setopt autocd
# Bind alt-left and alt-right to words navigation
bindkey "[D" vi-backward-blank-word
bindkey "[C" vi-forward-blank-word
if [ -f "/opt/homebrew/bin/brew" ]; then
eval "$(/opt/homebrew/bin/brew shellenv)"
fi
# Local executable directory
typeset -U path PATH
path+="$HOME/.local/bin"
# Use VS Code as editor when in dev container, vim otherwise
if [ -n $REMOTE_CONTAINERS ]; then
export EDITOR="code -w"
else
export EDITOR="vim"
fi
# Shared aliases
if [ -f "$HOME/.alias" ]; then
source "$HOME/.alias"
fi
eval "$(starship init zsh)"