diff options
author | Shubham Saini <shubham6405@gmail.com> | 2020-05-28 17:13:05 +0000 |
---|---|---|
committer | Shubham Saini <shubham6405@gmail.com> | 2020-05-28 17:13:05 +0000 |
commit | 5262da31979f82a27dd53a60a8bf3fc411a1a848 (patch) | |
tree | a2bed06ea8c627cd4a933d870716469e57be2029 /zsh | |
parent | c86ab2f8695dd41b722e00ca36c5ded1f7626a21 (diff) |
updated zsh
Diffstat (limited to 'zsh')
-rw-r--r-- | zsh/.zshrc | 160 |
1 files changed, 51 insertions, 109 deletions
@@ -1,122 +1,64 @@ | |||
1 | # If you come from bash you might have to change your $PATH. | 1 | # history |
2 | # export PATH=$HOME/bin:/usr/local/bin:$PATH | 2 | HISTFILE=~/.cache/zsh/history |
3 | HISTSIZE=1000 | ||
4 | SAVEHIST=1000 | ||
5 | setopt appendhistory hist_ignore_all_dups hist_ignore_space | ||
3 | 6 | ||
4 | # Path to your oh-my-zsh installation. | 7 | #exports |
5 | export ZSH="/home/fd0e/.oh-my-zsh" | ||
6 | export VISUAL=nvim | 8 | export VISUAL=nvim |
7 | export EDITOR="$VISUAL" | 9 | export EDITOR="$VISUAL" |
8 | export BROWSER=firefox | 10 | export BROWSER=firefox |
9 | export PATH=$PATH:$HOME/.local/bin:$HOME/bin | 11 | export PATH=$PATH:$HOME/.local/bin:$HOME/bin |
10 | export XDG_CURRENT_DESKTOP=bspwm | 12 | export XDG_CURRENT_DESKTOP=spectrwm |
11 | 13 | ||
12 | # Set name of the theme to load --- if set to "random", it will | 14 | setopt autocd extendedglob nomatch globdots correctall |
13 | # load a random theme each time oh-my-zsh is loaded, in which case, | 15 | unsetopt beep |
14 | # to know which specific one was loaded, run: echo $RANDOM_THEME | 16 | bindkey -v |
15 | # See https://github.com/robbyrussell/oh-my-zsh/wiki/Themes | 17 | |
16 | ZSH_THEME="sammy" | 18 | # completions |
17 | 19 | zstyle :compinstall filename '/home/x/.zshrc' | |
18 | # Set list of themes to pick from when loading at random | 20 | autoload -U colors && colors |
19 | # Setting this variable when ZSH_THEME=random will cause zsh to load | 21 | autoload -Uz compinit && compinit |
20 | # a theme from this variable instead of looking in ~/.oh-my-zsh/themes/ | 22 | zstyle ':completion:*' menu select |
21 | # If set to an empty array, this variable will have no effect. | 23 | zstyle ':completion:*' matcher-list '' 'm:{a-zA-Z}={A-Za-z}' 'r:|[._-]=* r:|=*' 'l:|=* r:|=*' |
22 | # ZSH_THEME_RANDOM_CANDIDATES=( "robbyrussell" "agnoster" ) | 24 | #zstyle ':completion:*:descriptions' format '%U%B%d%b%u' |
23 | 25 | #zstyle ':completion:*:warnings' format '%BSorry, no matches for: %d%b' | |
24 | # Uncomment the following line to use case-sensitive completion. | 26 | |
25 | # CASE_SENSITIVE="true" | 27 | # sources |
26 | 28 | source /usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh | |
27 | # Uncomment the following line to use hyphen-insensitive completion. | 29 | source /usr/share/zsh/plugins/zsh-autosuggestions/zsh-autosuggestions.zsh |
28 | # Case-sensitive completion must be off. _ and - will be interchangeable. | 30 | |
29 | # HYPHEN_INSENSITIVE="true" | 31 | # prompt |
30 | 32 | PROMPT=$'\n'"%B%F{240}%m "$'\n'"%(?.%F{248}▲.%F{red}?%?)%f " | |
31 | # Uncomment the following line to disable bi-weekly auto-update checks. | 33 | git_branch() { |
32 | # DISABLE_AUTO_UPDATE="true" | 34 | git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/ (\1)/' |
33 | 35 | } | |
34 | # Uncomment the following line to automatically update without prompting. | 36 | setopt PROMPT_SUBST |
35 | # DISABLE_UPDATE_PROMPT="true" | 37 | RPROMPT='%9c%{%F{green}%}$(git_branch)%{%F{none}%} $ ' |
36 | 38 | ||
37 | # Uncomment the following line to change how often to auto-update (in days). | 39 | # aliases |
38 | # export UPDATE_ZSH_DAYS=13 | 40 | alias ls='ls --color=auto' |
39 | 41 | alias ll='ls --color=auto -al' | |
40 | # Uncomment the following line if pasting URLs and other text is messed up. | 42 | alias key="vim $HOME/.config/spectrwm/keybindings.conf" |
41 | # DISABLE_MAGIC_FUNCTIONS=true | 43 | alias wm="vim ~/.config/spectrwm/spectrwm.conf" |
42 | |||
43 | # Uncomment the following line to disable colors in ls. | ||
44 | # DISABLE_LS_COLORS="true" | ||
45 | |||
46 | # Uncomment the following line to disable auto-setting terminal title. | ||
47 | # DISABLE_AUTO_TITLE="true" | ||
48 | |||
49 | # Uncomment the following line to enable command auto-correction. | ||
50 | # ENABLE_CORRECTION="true" | ||
51 | |||
52 | # Uncomment the following line to display red dots whilst waiting for completion. | ||
53 | # COMPLETION_WAITING_DOTS="true" | ||
54 | |||
55 | # Uncomment the following line if you want to disable marking untracked files | ||
56 | # under VCS as dirty. This makes repository status check for large repositories | ||
57 | # much, much faster. | ||
58 | # DISABLE_UNTRACKED_FILES_DIRTY="true" | ||
59 | |||
60 | # Uncomment the following line if you want to change the command execution time | ||
61 | # stamp shown in the history command output. | ||
62 | # You can set one of the optional three formats: | ||
63 | # "mm/dd/yyyy"|"dd.mm.yyyy"|"yyyy-mm-dd" | ||
64 | # or set a custom format using the strftime function format specifications, | ||
65 | # see 'man strftime' for details. | ||
66 | # HIST_STAMPS="mm/dd/yyyy" | ||
67 | |||
68 | # Would you like to use another custom folder than $ZSH/custom? | ||
69 | # ZSH_CUSTOM=/path/to/new-custom-folder | ||
70 | |||
71 | # Which plugins would you like to load? | ||
72 | # Standard plugins can be found in ~/.oh-my-zsh/plugins/* | ||
73 | # Custom plugins may be added to ~/.oh-my-zsh/custom/plugins/ | ||
74 | # Example format: plugins=(rails git textmate ruby lighthouse) | ||
75 | # Add wisely, as too many plugins slow down shell startup. | ||
76 | plugins=(git sudo extract python common-aliases) | ||
77 | |||
78 | source $ZSH/oh-my-zsh.sh | ||
79 | |||
80 | # User configuration | ||
81 | |||
82 | # export MANPATH="/usr/local/man:$MANPATH" | ||
83 | |||
84 | # You may need to manually set your language environment | ||
85 | # export LANG=en_US.UTF-8 | ||
86 | |||
87 | # Preferred editor for local and remote sessions | ||
88 | # if [[ -n $SSH_CONNECTION ]]; then | ||
89 | # export EDITOR='vim' | ||
90 | # else | ||
91 | # export EDITOR='mvim' | ||
92 | # fi | ||
93 | |||
94 | # Compilation flags | ||
95 | # export ARCHFLAGS="-arch x86_64" | ||
96 | |||
97 | # Set personal aliases, overriding those provided by oh-my-zsh libs, | ||
98 | # plugins, and themes. Aliases can be placed here, though oh-my-zsh | ||
99 | # users are encouraged to define aliases within the ZSH_CUSTOM folder. | ||
100 | # For a full list of active aliases, run `alias`. | ||
101 | # | ||
102 | # Example aliases | ||
103 | # alias zshconfig="mate ~/.zshrc" | ||
104 | # alias ohmyzsh="mate ~/.oh-my-zsh" | ||
105 | alias key="vim $HOME/.config/sxhkd/sxhkdrc" | ||
106 | alias wm="vim ~/.config/bspwm/bspwmrc" | ||
107 | alias f="ranger" | 44 | alias f="ranger" |
108 | alias nu="nmcli connection up " | ||
109 | alias weather="curl wttr.in" | 45 | alias weather="curl wttr.in" |
110 | alias py="/bin/python" | 46 | alias py="/usr/bin/python" |
111 | alias py2="/bin/python2" | ||
112 | alias pg="ping google.com" | 47 | alias pg="ping google.com" |
113 | alias pubip="curl ipinfo.io/ip" | 48 | alias pubip="curl ipinfo.io/ip" |
114 | alias k="pkill " | 49 | alias k="pkill " |
115 | alias m="cmus" | 50 | alias m="cmus" |
116 | alias vimrc="vim $HOME/.config/nvim/init.vim" | 51 | alias vimrc="vim $HOME/.config/nvim/init.vim" |
117 | alias poly="vim $HOME/.config/polybar/config" | 52 | alias v="nvim" |
118 | alias v="/usr/bin/nvim" | 53 | alias vim="nvim" |
119 | alias vim="/usr/bin/nvim" | 54 | alias sudo="sudo " |
120 | alias sudo="doas " | 55 | alias parrot="VBoxManage startvm Parrot" |
56 | |||
57 | up() { | ||
58 | curl -F "file=@$*" https://0x0.st | xclip -selection clipboard | ||
59 | } | ||
60 | |||
61 | dict() { | ||
62 | curl dict://dict.org/d:$* | ||
63 | } | ||
121 | 64 | ||
122 | source /usr/share/zsh/site-functions/zsh-syntax-highlighting.zsh | ||