-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdot_zimrc.tmpl
More file actions
80 lines (77 loc) · 2.72 KB
/
dot_zimrc.tmpl
File metadata and controls
80 lines (77 loc) · 2.72 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
# Modules
## Sane defaults per Zim maintainers
### sets sane zsh built-in environment options
zmodule environment
### applies correct bindkeys for input events
zmodule input
### utility aliases and functions (incl. adding color to ls, grep, less)
zmodule utility
zmodule termtitle
### find best help and use it
zmodule run-help
## ohmyzsh stuff
zmodule ohmyzsh/ohmyzsh --root plugins/sudo
{{ if lookPath "brew" }}
zmodule ohmyzsh/ohmyzsh --root plugins/brew
{{ end -}}
zmodule ohmyzsh/ohmyzsh --root plugins/emoji
zmodule ohmyzsh/ohmyzsh --root plugins/common-aliases
{{- if lookPath "systemctl" }}
zmodule ohmyzsh/ohmyzsh --root plugins/systemd
{{ end -}}
{{- if and (hasKey .chezmoi.osRelease "id") (eq .chezmoi.osRelease.id "arch") }}
### Arch Linux-specific
zmodule ohmyzsh/ohmyzsh --root plugins/archlinux
{{- else if and (hasKey .chezmoi.osRelease "id") (or (eq .chezmoi.osRelease.id "fedora") (and (hasKey .chezmoi.osRelease "idLike") (contains "fedora" .chezmoi.osRelease.idLike))) }}
# Fedora family-specific
{{- if (lookPath "dnf") }}
zmodule ohmyzsh/ohmyzsh --root plugins/dnf
{{- else if and (lookPath "yum") (not (lookPath "dnf")) }}
zmodule ohmyzsh/ohmyzsh --root plugins/yum
{{ end -}}
{{ end }}
{{- if and (hasKey .chezmoi.osRelease "id") (or (contains "suse" .chezmoi.osRelease.id) (and (hasKey .chezmoi.osRelease "idLike") (contains "suse" .chezmoi.osRelease.idLike))) }}
# SUSE-specific
zmodule ohmyzsh/ohmyzsh --root plugins/suse
{{ end }}
## Things I like to have
zmodule joke/zim-chezmoi
zmodule MichaelAquilina/zsh-you-should-use
{{- if lookPath "git" }}
zmodule unixorn/git-extra-commands
zmodule peterhurford/git-it-on.zsh --source git-it-on.plugin.zsh
{{ end -}}
zmodule zlsun/solarized-man
{{- if eq .chezmoi.os "darwin" }}
zmodule unixorn/tumult.plugin.zsh
{{ end }}
# Completion
## Additional completion definitions for zsh
zmodule zsh-users/zsh-completions --fpath src
## Enables and configures smart and extensive tab completion
### completion must be sourced after all modules that add completion definitions!
zmodule completion
# Prompt stuff
## Expose current working directory to prompt
zmodule prompt-pwd
{{- if lookPath "git" }}
## Expose git repo status info to prompts
zmodule git-info
{{ end -}}
## Choice of prompt
zmodule minimal
## Add-on for magic enter
zmodule magic-enter
# Must be initialized last
{{- if lookPath "git" }}
zmodule ohmyzsh/ohmyzsh --root plugins/git
{{ end -}}
{{- if eq .chezmoi.os "darwin" -}}
### macOS-specific
zmodule ohmyzsh/ohmyzsh --root plugins/macos
{{ else if and (hasKey .chezmoi.osRelease "idLike") (eq .chezmoi.osRelease.idLike "debian") }}
### Debian family-specific
zmodule ohmyzsh/ohmyzsh --root plugins/debian
{{ end -}}
zmodule zsh-users/zsh-syntax-highlighting
zmodule zsh-users/zsh-autosuggestions