-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathload.zsh
More file actions
55 lines (45 loc) · 2 KB
/
Copy pathload.zsh
File metadata and controls
55 lines (45 loc) · 2 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
#!/usr/bin/env zsh
SHA1N_PROFILE_HOME="${${(%):-%x}:a:h}"
setopt prompt_subst
autoload -U colors && colors
# export locale vars
export LANG="en_US.UTF-8"
export LC_CTYPE="en_US.UTF-8"
# plugins
fpath=($SHA1N_PROFILE_HOME/zsh-plugins/zsh-completions/src $fpath)
source $SHA1N_PROFILE_HOME/zsh-plugins/path-ethic/path-ethic.plugin.zsh
# zsh-defer for deferring non-critical interactive plugins
if [[ -o interactive ]]; then
source $SHA1N_PROFILE_HOME/zsh-plugins/zsh-defer/zsh-defer.plugin.zsh
zsh-defer source $SHA1N_PROFILE_HOME/zsh-plugins/zsh-history-substring-search/zsh-history-substring-search.zsh
zsh-defer source $SHA1N_PROFILE_HOME/zsh-plugins/zsh-autosuggestions/zsh-autosuggestions.zsh
else
source $SHA1N_PROFILE_HOME/zsh-plugins/zsh-history-substring-search/zsh-history-substring-search.zsh
source $SHA1N_PROFILE_HOME/zsh-plugins/zsh-autosuggestions/zsh-autosuggestions.zsh
fi
# theme
source $SHA1N_PROFILE_HOME/zsh-theme/agnoster-zsh-theme/agnoster.zsh-theme
source $SHA1N_PROFILE_HOME/include/exports
source $SHA1N_PROFILE_HOME/include/aliases
source $SHA1N_PROFILE_HOME/include/functions
source $SHA1N_PROFILE_HOME/include/keybindings
source $SHA1N_PROFILE_HOME/include/completions
source $SHA1N_PROFILE_HOME/include/history
source $SHA1N_PROFILE_HOME/include/prompt
# fzf-tab: after compinit (include/completions), before zsh-syntax-highlighting
if [[ -o interactive ]]; then
zsh-defer source $SHA1N_PROFILE_HOME/zsh-plugins/fzf-tab/fzf-tab.plugin.zsh
else
source $SHA1N_PROFILE_HOME/zsh-plugins/fzf-tab/fzf-tab.plugin.zsh
fi
# deferred keybindings that depend on history-substring-search
if [[ -o interactive ]]; then
zsh-defer bindkey "^[[A" history-substring-search-up
zsh-defer bindkey "^[[B" history-substring-search-down
fi
# zsh-syntax-highlighting MUST be loaded LAST
if [[ -o interactive ]]; then
zsh-defer source $SHA1N_PROFILE_HOME/zsh-plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
else
source $SHA1N_PROFILE_HOME/zsh-plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
fi