zsh config
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
################################################################################### | |
# Welcome Info | |
################################################################################### | |
echo -ne "${red}Hoje é:\t\t${cyan}" `date`; echo "" | |
echo -e "${red}Kernel: \t${cyan}" `uname -smr` | |
PATH=$PATH:$HOME/.rvm/bin # Add RVM to PATH for scripting | |
################################################################################### | |
# Shortcuts | |
################################################################################### | |
alias home='cd ~/' | |
alias documents='cd ~/Documentos' | |
alias downloads='cd ~/Downloads' | |
alias images='cd ~/Imagens' | |
alias videos='cd ~/Videos' | |
################################################################################### | |
# Sudo fixes | |
################################################################################### | |
alias install='~/bin/install_and_log install' | |
alias remove='sudo apt-get remove' | |
alias update='sudo apt-get update' | |
alias upgrade='sudo apt-get update && sudo apt-get upgrade' | |
alias dist-upgrade='sudo apt-get update && sudo apt-get dist-upgrade' | |
alias orphand='sudo deborphan | xargs sudo apt-get -y remove --purge' | |
alias clean='sudo apt-get autoclean && sudo apt-get autoremove && sudo apt-get clean && sudo apt-get remove && orphand' | |
alias search="apt-cache search" | |
################################################################################### | |
# Configs of zsh | |
################################################################################### | |
# If you come from bash you might have to change your $PATH. | |
# export PATH=$HOME/bin:/usr/local/bin:$PATH | |
# Path to your oh-my-zsh installation. | |
export ZSH=/home/mauricio/.oh-my-zsh | |
# Set name of the theme to load. Optionally, if you set this to "random" | |
# it'll load a random theme each time that oh-my-zsh is loaded. | |
# See https://github.com/robbyrussell/oh-my-zsh/wiki/Themes | |
ZSH_THEME="agnoster" | |
# Set list of themes to load | |
# Setting this variable when ZSH_THEME=random | |
# cause zsh load theme from this variable instead of | |
# looking in ~/.oh-my-zsh/themes/ | |
# An empty array have no effect | |
# ZSH_THEME_RANDOM_CANDIDATES=( "robbyrussell" "agnoster" ) | |
# Uncomment the following line to use case-sensitive completion. | |
# CASE_SENSITIVE="true" | |
# Uncomment the following line to use hyphen-insensitive completion. Case | |
# sensitive completion must be off. _ and - will be interchangeable. | |
# HYPHEN_INSENSITIVE="true" | |
# Uncomment the following line to disable bi-weekly auto-update checks. | |
# DISABLE_AUTO_UPDATE="true" | |
# Uncomment the following line to change how often to auto-update (in days). | |
# export UPDATE_ZSH_DAYS=13 | |
# Uncomment the following line to disable colors in ls. | |
# DISABLE_LS_COLORS="true" | |
# Uncomment the following line to disable auto-setting terminal title. | |
# DISABLE_AUTO_TITLE="true" | |
# Uncomment the following line to enable command auto-correction. | |
# ENABLE_CORRECTION="true" | |
# Uncomment the following line to display red dots whilst waiting for completion. | |
# COMPLETION_WAITING_DOTS="true" | |
# Uncomment the following line if you want to disable marking untracked files | |
# under VCS as dirty. This makes repository status check for large repositories | |
# much, much faster. | |
# DISABLE_UNTRACKED_FILES_DIRTY="true" | |
# Uncomment the following line if you want to change the command execution time | |
# stamp shown in the history command output. | |
# The optional three formats: "mm/dd/yyyy"|"dd.mm.yyyy"|"yyyy-mm-dd" | |
# HIST_STAMPS="mm/dd/yyyy" | |
# Would you like to use another custom folder than $ZSH/custom? | |
# ZSH_CUSTOM=/path/to/new-custom-folder | |
# Which plugins would you like to load? (plugins can be found in ~/.oh-my-zsh/plugins/*) | |
# Custom plugins may be added to ~/.oh-my-zsh/custom/plugins/ | |
# Example format: plugins=(rails git textmate ruby lighthouse) | |
# Add wisely, as too many plugins slow down shell startup. | |
plugins=( | |
git | |
) | |
source $ZSH/oh-my-zsh.sh | |
# User configuration | |
# export MANPATH="/usr/local/man:$MANPATH" | |
# You may need to manually set your language environment | |
# export LANG=en_US.UTF-8 | |
# Preferred editor for local and remote sessions | |
# if [[ -n $SSH_CONNECTION ]]; then | |
# export EDITOR='vim' | |
# else | |
# export EDITOR='mvim' | |
# fi | |
# Compilation flags | |
# export ARCHFLAGS="-arch x86_64" | |
#ssh | |
export SSH_PATH="~/.ssh/rsa_id" | |
# Set personal aliases, overriding those provided by oh-my-zsh libs, | |
# plugins, and themes. Aliases can be placed here, though oh-my-zsh | |
# users are encouraged to define aliases within the ZSH_CUSTOM folder. | |
# For a full list of active aliases, run `alias`. | |
# Example aliases | |
alias zshconfig="mate ~/.zshrc" | |
alias ohmyzsh="mate ~/.oh-my-zsh" | |
export NVM_DIR="/home/mauricio/.nvm" | |
[ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh" # This loads nvm | |
################################################################################### | |
# Colors | |
################################################################################### | |
# Customize to your needs... | |
# | |
# -font -*-fixed-medium-r-*-*-18-*-*-*-*-*-iso8859-* -geometry 70x24 | |
#------------------------------------------//// | |
# Basic Configuration: | |
#------------------------------------------//// | |
#kill the beep alarm | |
#setopt no_beep | |
#enable auto-correct | |
#setopt correctall | |
unsetopt correct_all | |
#turn on tab completion and make it fancy | |
#autoload -U compinit && compinit | |
#zstyle ':completion:*:descriptions' format '%U%B%d%b%u' | |
#zstyle ':completion:*:warnings' format '%BSorry, no matches for: %d%b' | |
#fancy colors and prompts are set later | |
#add custom functions to path (important for prompt) | |
fpath=(~/.zsh/functions $fpath) | |
#remove right prompt after command is run (helpful if copying and pasting) | |
#setopt TRANSIENT_RPROMPT | |
#------------------------------------------//// | |
# Colors: | |
#------------------------------------------//// | |
black='\e[0;30m' | |
blue='\e[0;34m' | |
green='\e[0;32m' | |
cyan='\e[0;36m' | |
red='\e[0;31m' | |
purple='\e[0;35m' | |
brown='\e[0;33m' | |
lightgray='\e[0;37m' | |
darkgray='\e[1;30m' | |
lightblue='\e[1;34m' | |
lightgreen='\e[1;32m' | |
lightcyan='\e[1;36m' | |
lightred='\e[1;31m' | |
lightpurple='\e[1;35m' | |
yellow='\e[1;33m' | |
white='\e[1;37m' | |
nc='\e[0m' | |
#Colors for less pager (man pages) | |
export LESS_TERMCAP_mb=$'\E[01;31m' # begin blinking | |
export LESS_TERMCAP_md=$'\E[01;38;5;74m' # begin bold | |
export LESS_TERMCAP_me=$'\E[0m' # end mode | |
export LESS_TERMCAP_se=$'\E[0m' # end standout-mode | |
export LESS_TERMCAP_so=$'\E[38;5;246m' # begin standout-mode - info box | |
export LESS_TERMCAP_ue=$'\E[0m' # end underline | |
export LESS_TERMCAP_us=$'\E[04;38;5;146m' # begin underline | |
# enable color support of ls and also add handy aliases | |
if [ -x /usr/bin/dircolors ]; then | |
eval "`dircolors -b`" | |
# alias ls='ls --color=auto' | |
# alias dir='dir --color=auto' | |
# alias vdir='vdir --color=auto' | |
# alias grep='grep --color=auto' | |
# alias fgrep='fgrep --color=auto' | |
# alias egrep='egrep --color=auto' | |
fi | |
#------------------------------------------//// | |
# Custom Prompt: | |
#------------------------------------------//// | |
# Nice basic prompt | |
#export PS1="%n@%m:%~%# " | |
#export RPS1=" <%T" | |
#export PS2="%_> " | |
# Colorful basic prompt option 1 | |
#autoload -U colors && colors | |
#export PS1="%{$fg[red]%}%n%{$reset_color%}@%{$fg[blue]%}%m %{$fg[yellow]%}%~ %{$reset_color%}%% " | |
#export RPS1="%{$fg[cyan]%}<%T%{$reset_color%}" | |
#export PS2="%_> " | |
# Colorful basic prompt option 2 { Better than option 1 } | |
#export PS1=$'%{\e[1;32m%}%n%{\e[0m%}%{\e[1;34m%}@%{\e[1;31m%}%m %{\e[1;34m%}%~ %{\e[0m%}%% ' | |
#export RPS1=$'%{\e[1;30m%}<%T%{\e[0m%}' | |
#export PS2=$'%{\e[0;37m%} %_>%{\e[0m%} ' | |
# Fancy prompt system see /usr/share/zsh/functions/Prompts/ for files | |
# the "fhsm" configuration is loaded from ~/.zsh/functions, which is added to the path above. | |
# List options with: prompt -l | |
autoload -U promptinit && promptinit | |
#prompt fhsm |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment