commit 27994c96bd319094983a1dec7ee90acfcb185352 parent 14c8d8ecd39d98002dfa839e5a5e46ef74a97921 Author: oscarbenedito <oscar@oscarbenedito.com> Date: Sun, 14 Jun 2020 19:54:55 +0200 Removed all chezmoi templates Diffstat:
A | dot_config/git/config | | | 6 | ++++++ |
D | dot_config/git/config.tmpl | | | 10 | ---------- |
A | dot_config/zsh/aliases | | | 53 | +++++++++++++++++++++++++++++++++++++++++++++++++++++ |
D | dot_config/zsh/aliases.tmpl | | | 60 | ------------------------------------------------------------ |
A | dot_config/zsh/dot_zshrc | | | 44 | ++++++++++++++++++++++++++++++++++++++++++++ |
D | dot_config/zsh/dot_zshrc.tmpl | | | 44 | -------------------------------------------- |
6 files changed, 103 insertions(+), 114 deletions(-)
diff --git a/dot_config/git/config b/dot_config/git/config @@ -0,0 +1,6 @@ +[user] + email = oscar@oscarbenedito.com + name = oscarbenedito + signingkey = 827E5A8E3AE8A499 +[commit] + gpgsign = true diff --git a/dot_config/git/config.tmpl b/dot_config/git/config.tmpl @@ -1,10 +0,0 @@ -[user] - email = oscar@oscarbenedito.com - name = oscarbenedito - {{- if .pgpkey }} - signingkey = 827E5A8E3AE8A499 - {{- end }} -{{- if .pgpkey }} -[commit] - gpgsign = true -{{- end }} diff --git a/dot_config/zsh/aliases b/dot_config/zsh/aliases @@ -0,0 +1,53 @@ +# vim: filetype=zsh +alias clear="printf '\033c'" + +# Colors +alias ls="ls -hv --color=auto --group-directories-first" +alias grep="grep --color=auto" +alias fgrep="fgrep --color=auto" +alias egrep="egrep --color=auto" +alias diff="diff --color=auto" + +# Options aliases +alias cp="cp --interactive" +alias mv="mv --interactive" +alias mkdir="mkdir --parents" +alias rm="rm -I" +alias tmux="TERM=screen-256color tmux" + +# Shortcuts +alias v="nvim" +alias vim="nvim" +alias ..="cd .." +alias ...="cd ../.." +alias vw="cd $HOME/Documents/wiki && vim index.md" +alias bvw="firefox $HOME/Documents/wiki/build/html/index.html" + +# Zsh aliases +alias -g L="|less" +alias -g NULL="> /dev/null 2>&1" + +# Chezmoi +alias c="chezmoi" +alias ce="chezmoi edit --apply" + +# Git +alias g="git" +alias gs="git status" +alias gc="git commit -m" +alias gd="git diff" +alias ga="git add" +alias gpl="git pull" +alias gps="git push" +alias gsh="git stash" +alias gl="git log" + +# Updates +alias upgrade="sudo apt-get update && sudo apt-get -y upgrade" +# alias upgrade="sudo pacman -Syyu --noconfirm" + +# Backup to external HD +alias backup_all='rsync -loptruzvP --delete --exclude "/.*" "$HOME/" "/media/$USER/OSCAR/.backup_$(hostname)/"' + +# Backup the contents of the USB +alias backup_usb='rsync -gloptruzvP --delete --exclude "/Varis/copia-gris.hc" --exclude "/Varis/copia-gris-git.hc" --exclude "/.Trash-1000" --exclude "/.Trashes" --exclude "/.Spotlight-V100" "/media/$USER/Oscar/" "$HOME/Documents/Backups/USB/"' diff --git a/dot_config/zsh/aliases.tmpl b/dot_config/zsh/aliases.tmpl @@ -1,60 +0,0 @@ -# vim: filetype=zsh -alias clear="printf '\033c'" - -# Colors -alias ls="ls -hv --color=auto --group-directories-first" -alias grep="grep --color=auto" -alias fgrep="fgrep --color=auto" -alias egrep="egrep --color=auto" -alias diff="diff --color=auto" - -# Options aliases -alias cp="cp --interactive" -alias mv="mv --interactive" -alias mkdir="mkdir --parents" -alias rm="rm -I" -alias tmux="TERM=screen-256color tmux" - -# Shortcuts -alias v="nvim" -alias vim="nvim" -alias ..="cd .." -alias ...="cd ../.." -alias vw="cd $HOME/Documents/wiki && vim index.md" -alias bvw="firefox $HOME/Documents/wiki/build/html/index.html" - -# Zsh aliases -alias -g L="|less" -alias -g NULL="> /dev/null 2>&1" - -# Chezmoi -alias c="chezmoi" -alias ce="chezmoi edit --apply" - -# Git -alias g="git" -alias gs="git status" -alias gc="git commit -m" -alias gd="git diff" -alias ga="git add" -alias gpl="git pull" -alias gps="git push" -alias gsh="git stash" -alias gl="git log" - -{{- if eq .chezmoi.osRelease.id "debian" -}} -alias upgrade="sudo apt-get update && sudo apt-get -y upgrade" -alias ag="sudo apt-get" -{{- else -}} -alias upgrade="sudo pacman -Syyu --noconfirm" -alias p="sudo pacman" -{{- end }} - -{{- if .backup }} - -# Backup to external HD -alias backup_all='rsync -loptruzvP --delete {{ range $i, $dir := .backup.backup_exclude }}--exclude "{{ $dir }}" {{ end }} "$HOME/" "/media/$USER/OSCAR/.{{ .backup.backup_dir }}/"' - -# Backup the contents of the USB -alias backup_usb='rsync -gloptruzvP --delete --exclude "/Varis/copia-gris.hc" --exclude "/Varis/copia-gris-git.hc" --exclude "/.Trash-1000" --exclude "/.Trashes" --exclude "/.Spotlight-V100" "/media/$USER/Oscar/" "$HOME/Documents/Backups/USB/"' -{{- end }} diff --git a/dot_config/zsh/dot_zshrc b/dot_config/zsh/dot_zshrc @@ -0,0 +1,44 @@ +# vim: filetype=zsh +# Load colors and set up prompt +autoload -U colors && colors +PS1="%B%{$fg[magenta]%}%n%{$fg[blue]%}@%{$fg[green]%}%M %{$fg[yellow]%}%~%b%{$fg[red]%}$%{$reset_color%} " + +# Set up history and history file +HISTSIZE=1000 +SAVEHIST=1000 +HISTFILE=~/.cache/zsh/history + +setopt HIST_IGNORE_DUPS +setopt HIST_FIND_NO_DUPS + +# antlr4 +[ -z "$CLASSPATH" ] && export CLASSPATH=".:/home/oscar/Desktop/antlr/antlr-4.7.2-complete.jar" || export CLASSPATH=".:/home/oscar/Desktop/antlr/antlr-4.7.2-complete.jar:$CLASSPATH" +alias grun='java org.antlr.v4.gui.TestRig' + +# Set up navigation menu when pressing tab multiple times +autoload -U compinit +zstyle ':completion:*' menu select +zmodload zsh/complist +compinit -d ~/.cache/zsh/zcompdump +#_comp_options+=(globdots) + +# Auto complete case insensitive +zstyle ':completion:*' matcher-list '' 'm:{a-zA-Z}={A-Za-z}' 'r:|[._-]=* r:|=*' 'l:|=* r:|=*' + +# Set up vi style keys +bindkey -v +export KEYTIMEOUT=1 +bindkey "^?" backward-delete-char + +# Also set vi keys to navigate the menus when double pressing tab +bindkey -M menuselect 'h' vi-backward-char +bindkey -M menuselect 'k' vi-up-line-or-history +bindkey -M menuselect 'l' vi-forward-char +bindkey -M menuselect 'j' vi-down-line-or-history + +# Process the alias file +[ -f "$XDG_CONFIG_HOME/zsh/aliases" ] && source "$XDG_CONFIG_HOME/zsh/aliases" +[ -f "$XDG_CONFIG_HOME/zsh/aliases-auto" ] && source "$XDG_CONFIG_HOME/zsh/aliases-auto" + +# Include the highlighting plug-in +source /usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh 2> /dev/null diff --git a/dot_config/zsh/dot_zshrc.tmpl b/dot_config/zsh/dot_zshrc.tmpl @@ -1,44 +0,0 @@ -# vim: filetype=zsh -# Load colors and set up prompt -autoload -U colors && colors -PS1="%B%{$fg[magenta]%}%n%{$fg[blue]%}@%{$fg[green]%}%M %{$fg[yellow]%}%~%b%{$fg[red]%}$%{$reset_color%} " - -# Set up history and history file -HISTSIZE=1000 -SAVEHIST=1000 -HISTFILE=~/.cache/zsh/history - -setopt HIST_IGNORE_DUPS -setopt HIST_FIND_NO_DUPS - -# Set up navigation menu when pressing tab multiple times -autoload -U compinit -zstyle ':completion:*' menu select -zmodload zsh/complist -compinit -d ~/.cache/zsh/zcompdump -#_comp_options+=(globdots) - -# Auto complete case insensitive -zstyle ':completion:*' matcher-list '' 'm:{a-zA-Z}={A-Za-z}' 'r:|[._-]=* r:|=*' 'l:|=* r:|=*' - -# Set up vi style keys -bindkey -v -export KEYTIMEOUT=1 -bindkey "^?" backward-delete-char - -# Also set vi keys to navigate the menus when double pressing tab -bindkey -M menuselect 'h' vi-backward-char -bindkey -M menuselect 'k' vi-up-line-or-history -bindkey -M menuselect 'l' vi-forward-char -bindkey -M menuselect 'j' vi-down-line-or-history - -# Process the alias file -[ -f "$XDG_CONFIG_HOME/zsh/aliases" ] && source "$XDG_CONFIG_HOME/zsh/aliases" -[ -f "$XDG_CONFIG_HOME/zsh/aliases-auto" ] && source "$XDG_CONFIG_HOME/zsh/aliases-auto" - -# Include the highlighting plug-in -{{- if eq .chezmoi.osRelease.id "debian" }} -source /usr/share/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh 2> /dev/null -{{- else }} -source /usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh 2> /dev/null -{{- end }}