Moved from zinit to zgenom.
This commit is contained in:
parent
0196190666
commit
535919afbb
99
dot_dotfiles/oh-my-zsh/custom/02_zgenom.zsh
Normal file
99
dot_dotfiles/oh-my-zsh/custom/02_zgenom.zsh
Normal file
@ -0,0 +1,99 @@
|
|||||||
|
#!/usr/bin/env zsh
|
||||||
|
|
||||||
|
# Install zgenom if needed
|
||||||
|
if [[ ! -f $HOME/.zgenom/zgenom.zsh ]]; then
|
||||||
|
print -P "Installing zgenom"
|
||||||
|
git clone https://github.com/jandamm/zgenom.git "${HOME}/.zgenom" && \
|
||||||
|
print -P " - Installation successful." || \
|
||||||
|
print -P " - The clone has failed."
|
||||||
|
fi
|
||||||
|
|
||||||
|
# load zgenom
|
||||||
|
source "${HOME}/.zgenom/zgenom.zsh"
|
||||||
|
|
||||||
|
# Check for plugin and zgenom updates every 7 days
|
||||||
|
# This does not increase the startup time.
|
||||||
|
zgenom autoupdate
|
||||||
|
|
||||||
|
# if the init script doesn't exist
|
||||||
|
if ! zgenom saved; then
|
||||||
|
|
||||||
|
# specify plugins here
|
||||||
|
zgenom ohmyzsh
|
||||||
|
zgenom ohmyzsh plugins/git
|
||||||
|
zgenom ohmyzsh plugins/sudo
|
||||||
|
zgenom ohmyzsh plugins/archlinux
|
||||||
|
zgenom ohmyzsh plugins/command-not-found
|
||||||
|
zgenom ohmyzsh plugins/common-aliases
|
||||||
|
zgenom ohmyzsh plugins/copypath
|
||||||
|
zgenom ohmyzsh plugins/copyfile
|
||||||
|
zgenom ohmyzsh plugins/cp
|
||||||
|
zgenom ohmyzsh plugins/dircycle
|
||||||
|
zgenom ohmyzsh plugins/docker-compose
|
||||||
|
zgenom ohmyzsh plugins/encode64
|
||||||
|
zgenom ohmyzsh plugins/extract
|
||||||
|
zgenom ohmyzsh plugins/fancy-ctrl-z
|
||||||
|
zgenom ohmyzsh plugins/gem
|
||||||
|
zgenom ohmyzsh plugins/git
|
||||||
|
zgenom ohmyzsh plugins/git/git.plugin.zsh
|
||||||
|
zgenom ohmyzsh plugins/golang
|
||||||
|
zgenom ohmyzsh plugins/gpg-agent
|
||||||
|
zgenom ohmyzsh plugins/history
|
||||||
|
zgenom ohmyzsh plugins/node
|
||||||
|
zgenom ohmyzsh plugins/npm
|
||||||
|
zgenom ohmyzsh plugins/pip
|
||||||
|
zgenom ohmyzsh plugins/rvm
|
||||||
|
zgenom ohmyzsh plugins/sudo
|
||||||
|
zgenom ohmyzsh plugins/svn
|
||||||
|
zgenom ohmyzsh plugins/systemd
|
||||||
|
zgenom ohmyzsh plugins/terraform
|
||||||
|
zgenom ohmyzsh plugins/tmux
|
||||||
|
zgenom ohmyzsh plugins/tmuxinator
|
||||||
|
zgenom ohmyzsh plugins/urltools
|
||||||
|
zgenom ohmyzsh plugins/vagrant
|
||||||
|
zgenom ohmyzsh plugins/web-search
|
||||||
|
|
||||||
|
# prezto options
|
||||||
|
zgenom prezto editor key-bindings 'emacs'
|
||||||
|
zgenom prezto prompt theme 'sorin'
|
||||||
|
|
||||||
|
# This ZSH plugin enables using fzf to search your command history and do file searches.
|
||||||
|
zgenom load unixorn/fzf-zsh-plugin
|
||||||
|
|
||||||
|
# Introduce 256 colors in terminal
|
||||||
|
zgenom load chrissicool/zsh-256color
|
||||||
|
|
||||||
|
# Because your terminal should be able to perform tasks asynchronously without external tools!
|
||||||
|
zgenom load mafredri/zsh-async
|
||||||
|
|
||||||
|
# simplistic interactive filtering tool
|
||||||
|
zgenom load peco/peco
|
||||||
|
|
||||||
|
# Bookmarks and jump
|
||||||
|
zgenom load jocelynmallon/zshmarks
|
||||||
|
|
||||||
|
# Enhanced dir list with git features
|
||||||
|
zgenom load supercrabtree/k
|
||||||
|
|
||||||
|
# Jump back to parent directory
|
||||||
|
zgenom load tarrasch/zsh-bd
|
||||||
|
|
||||||
|
zgenom load djui/alias-tips
|
||||||
|
zgenom load hlissner/zsh-autopair
|
||||||
|
|
||||||
|
# search in zsh history
|
||||||
|
zgenom load zsh-users/zsh-history-substring-search
|
||||||
|
|
||||||
|
# Additional completion definitions for Zsh.
|
||||||
|
zgenom load zsh-users/zsh-completions
|
||||||
|
|
||||||
|
# Suggests commands as you type based on history and completions.
|
||||||
|
zgenom load zsh-users/zsh-autosuggestions
|
||||||
|
|
||||||
|
# zsh-syntax-highlighting must be loaded after executing compinit command and sourcing other plugins
|
||||||
|
zgenom load zsh-users/zsh-syntax-highlighting
|
||||||
|
|
||||||
|
|
||||||
|
# generate the init script from plugins above
|
||||||
|
zgenom save
|
||||||
|
fi
|
||||||
163
dot_dotfiles/oh-my-zsh/custom/02_zplugin.zsh.depr
Normal file
163
dot_dotfiles/oh-my-zsh/custom/02_zplugin.zsh.depr
Normal file
@ -0,0 +1,163 @@
|
|||||||
|
### ZINIT
|
||||||
|
if [[ ! -f $HOME/.zinit/bin/zinit.zsh ]]; then
|
||||||
|
print -P "%F{33}▓▒░ %F{220}Installing %F{33}DHARMA%F{220} Initiative Plugin Manager (%F{33}zdharma/zinit%F{220})…%f"
|
||||||
|
command mkdir -p "$HOME/.zinit" && command chmod g-rwX "$HOME/.zinit"
|
||||||
|
command git clone https://github.com/zdharma/zinit "$HOME/.zinit/bin" && \
|
||||||
|
print -P "%F{33}▓▒░ %F{34}Installation successful.%f%b" || \
|
||||||
|
print -P "%F{160}▓▒░ The clone has failed.%f%b"
|
||||||
|
fi
|
||||||
|
|
||||||
|
source "$HOME/.zinit/bin/zinit.zsh"
|
||||||
|
autoload -Uz _zinit
|
||||||
|
(( ${+_comps} )) && _comps[zinit]=_zinit
|
||||||
|
|
||||||
|
# Load a few important annexes, without Turbo
|
||||||
|
# (this is currently required for annexes)
|
||||||
|
zinit light-mode for \
|
||||||
|
zinit-zsh/z-a-rust \
|
||||||
|
zinit-zsh/z-a-as-monitor \
|
||||||
|
zinit-zsh/z-a-patch-dl \
|
||||||
|
zinit-zsh/z-a-bin-gem-node
|
||||||
|
|
||||||
|
# Because your terminal should be able to perform tasks asynchronously without external tools!
|
||||||
|
zinit light mafredri/zsh-async
|
||||||
|
|
||||||
|
# Introduce 256 colors in terminal
|
||||||
|
zplugin light chrissicool/zsh-256color
|
||||||
|
|
||||||
|
# What the hell does this do?
|
||||||
|
zinit light mollifier/anyframe
|
||||||
|
zstyle ":anyframe:selector:" use fzf
|
||||||
|
|
||||||
|
# print github style calendar
|
||||||
|
zinit ice as"program" atclone'perl Makefile.PL PREFIX=$ZPFX' \
|
||||||
|
atpull'%atclone' make'install' pick"$ZPFX/bin/git-cal"
|
||||||
|
zinit light k4rthik/git-cal
|
||||||
|
|
||||||
|
# simplistic interactive filtering tool
|
||||||
|
zinit light peco/peco
|
||||||
|
|
||||||
|
# use package manager to install fzf (straight from github?)
|
||||||
|
zinit pack for fzf
|
||||||
|
|
||||||
|
# C^x C^x to launch fzf?
|
||||||
|
zinit light b4b4r07/easy-oneliner
|
||||||
|
|
||||||
|
# search in zsh history
|
||||||
|
zinit light zsh-users/zsh-history-substring-search
|
||||||
|
|
||||||
|
# Enhanced CD command
|
||||||
|
# wait lucid > suppress output on console, messes with p10 setup
|
||||||
|
#zinit wait lucid light-mode for \
|
||||||
|
# b4b4r07/enhancd
|
||||||
|
|
||||||
|
# Oh-My-Zsh plugins
|
||||||
|
zinit snippet OMZ::plugins/git/git.plugin.zsh
|
||||||
|
|
||||||
|
# Bookmarks and jump
|
||||||
|
zinit light jocelynmallon/zshmarks
|
||||||
|
|
||||||
|
# Enhanced dir list with git features
|
||||||
|
zinit light supercrabtree/k
|
||||||
|
|
||||||
|
# Jump back to parent directory
|
||||||
|
zinit light tarrasch/zsh-bd
|
||||||
|
|
||||||
|
# Simple zsh calculator
|
||||||
|
# Usage: $ calc 5+4
|
||||||
|
# TODO figure out mismatch with zsh-syntax-highlighting (= is invalid alias)
|
||||||
|
#zinit light arzzen/calc.plugin.zsh
|
||||||
|
|
||||||
|
zinit light djui/alias-tips
|
||||||
|
zinit light hlissner/zsh-autopair
|
||||||
|
|
||||||
|
|
||||||
|
# Additional completion definitions for Zsh.
|
||||||
|
zinit light zsh-users/zsh-completions
|
||||||
|
|
||||||
|
# Suggests commands as you type based on history and completions.
|
||||||
|
zinit light zsh-users/zsh-autosuggestions
|
||||||
|
|
||||||
|
# zsh-syntax-highlighting must be loaded after executing compinit command and sourcing other plugins
|
||||||
|
zinit load zsh-users/zsh-syntax-highlighting
|
||||||
|
|
||||||
|
# search in zsh history
|
||||||
|
zinit light zsh-users/zsh-history-substring-search
|
||||||
|
zmodload zsh/terminfo
|
||||||
|
bindkey "$terminfo[kcuu1]" history-substring-search-up
|
||||||
|
bindkey "$terminfo[kcud1]" history-substring-search-down
|
||||||
|
bindkey "^[[1;5A" history-substring-search-up
|
||||||
|
bindkey "^[[1;5B" history-substring-search-down
|
||||||
|
|
||||||
|
# oh-my-zsh plugins
|
||||||
|
zinit snippet OMZ::plugins/archlinux
|
||||||
|
zinit snippet OMZ::plugins/bundler
|
||||||
|
zinit snippet OMZ::plugins/command-not-found
|
||||||
|
zinit snippet OMZ::plugins/common-aliases
|
||||||
|
zinit snippet OMZ::plugins/copydir
|
||||||
|
zinit snippet OMZ::plugins/copyfile
|
||||||
|
zinit snippet OMZ::plugins/cp
|
||||||
|
zinit snippet OMZ::plugins/cp
|
||||||
|
zinit snippet OMZ::plugins/dircycle
|
||||||
|
zinit snippet OMZ::plugins/dnf
|
||||||
|
zinit snippet OMZ::plugins/docker-compose
|
||||||
|
zinit snippet OMZ::plugins/encode64
|
||||||
|
zinit snippet OMZ::plugins/extract
|
||||||
|
zinit snippet OMZ::plugins/fancy-ctrl-z
|
||||||
|
zinit snippet OMZ::plugins/gem
|
||||||
|
zinit snippet OMZ::plugins/git
|
||||||
|
zinit snippet OMZ::plugins/git/git.plugin.zsh
|
||||||
|
zinit snippet OMZ::plugins/golang
|
||||||
|
zinit snippet OMZ::plugins/gpg-agent
|
||||||
|
zinit snippet OMZ::plugins/history
|
||||||
|
zinit snippet OMZ::plugins/node
|
||||||
|
zinit snippet OMZ::plugins/npm
|
||||||
|
zinit snippet OMZ::plugins/pip
|
||||||
|
zinit snippet OMZ::plugins/rvm
|
||||||
|
zinit snippet OMZ::plugins/sudo
|
||||||
|
zinit snippet OMZ::plugins/svn
|
||||||
|
zinit snippet OMZ::plugins/systemd
|
||||||
|
zinit snippet OMZ::plugins/terraform
|
||||||
|
zinit snippet OMZ::plugins/tmux
|
||||||
|
zinit snippet OMZ::plugins/tmuxinator
|
||||||
|
zinit snippet OMZ::plugins/urltools
|
||||||
|
zinit snippet OMZ::plugins/vagrant
|
||||||
|
zinit snippet OMZ::plugins/web-search
|
||||||
|
|
||||||
|
|
||||||
|
# Completions
|
||||||
|
# the internal list (hash) of commands will be updated for each search by issuing the rehash command
|
||||||
|
zstyle ':completion:*' rehash true
|
||||||
|
# http://zsh.sourceforge.net/Doc/Release/Completion-System.html
|
||||||
|
zstyle ':completion:' completer _complete _match _approximate
|
||||||
|
zstyle ':completion:' group-name ''
|
||||||
|
#zstyle ':completion:' list-colors ${(s.:.)LS_COLORS}
|
||||||
|
zstyle ':completion:' matcher-list 'm:{a-z}={A-Z}'
|
||||||
|
zstyle ':completion:' use-cache true
|
||||||
|
zstyle ':completion:' verbose yes
|
||||||
|
zstyle ':completion::default' menu select=2
|
||||||
|
zstyle ':completion::descriptions' format '%F{yellow}-- %d --%f'
|
||||||
|
zstyle ':completion:*:options' description 'yes'
|
||||||
|
# case-insensitive (uppercase from lowercase) completion
|
||||||
|
#zstyle ':completion:*' matcher-list 'm:{a-z}={A-Z}'
|
||||||
|
# process completion
|
||||||
|
#zstyle ':completion:*:processes' command 'ps -au$USER'
|
||||||
|
#zstyle ':completion:*:*:kill:*:processes' list-colors "=(#b) #([0-9]#)*=36=31"
|
||||||
|
zstyle ':completion:*' completer _expand _complete _ignored _approximate
|
||||||
|
#zstyle ':completion:*' list-colors ${(s.:.)LS_COLORS}
|
||||||
|
zstyle ':completion:*' menu select=2
|
||||||
|
zstyle ':completion:*' select-prompt '%SScrolling active: current selection at %p%s'
|
||||||
|
zstyle ':completion:*:descriptions' format '%U%F{yellow}%d%f%u'
|
||||||
|
#zstyle ':completion:*:*:git:*' script ~/.git-completion.sh
|
||||||
|
zstyle ':completion:*' verbose yes
|
||||||
|
zstyle ':completion:*:descriptions' format '%B%d%b'
|
||||||
|
zstyle ':completion:*:messages' format '%d'
|
||||||
|
zstyle ':completion:*:warnings' format 'No matches for: %d'
|
||||||
|
zstyle ':completion:*' group-name ''
|
||||||
|
# case-insensitive (all), partial-word and then substring completion
|
||||||
|
zstyle ":completion:*" matcher-list \
|
||||||
|
"m:{a-zA-Z}={A-Za-z}" \
|
||||||
|
"r:|[._-]=* r:|=*" \
|
||||||
|
"l:|=* r:|=*"
|
||||||
|
zstyle ':completion:*' list-colors "${(s.:.)LS_COLORS}"
|
||||||
|
zstyle ':completion:*:default' list-colors "${(s.:.)LS_COLORS}"
|
||||||
@ -83,7 +83,7 @@ ZSH_CUSTOM=$HOME/.config/oh-my-zsh/custom/
|
|||||||
# Custom plugins may be added to $ZSH_CUSTOM/plugins/
|
# Custom plugins may be added to $ZSH_CUSTOM/plugins/
|
||||||
# Example format: plugins=(rails git textmate ruby lighthouse)
|
# Example format: plugins=(rails git textmate ruby lighthouse)
|
||||||
# Add wisely, as too many plugins slow down shell startup.
|
# Add wisely, as too many plugins slow down shell startup.
|
||||||
plugins=(git docker)
|
plugins=(git)
|
||||||
|
|
||||||
ZSH_CACHE_DIR=$HOME/.cache/oh-my-zsh
|
ZSH_CACHE_DIR=$HOME/.cache/oh-my-zsh
|
||||||
if [[ ! -d $ZSH_CACHE_DIR ]]; then
|
if [[ ! -d $ZSH_CACHE_DIR ]]; then
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user