Advertisement
zezaocapoeira

~/.zshrc

Sep 14th, 2014
372
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 7.14 KB | None | 0 0
  1. ###===== ZSHRC =============================================================================
  2. ###=========================================================================================
  3. ##Tabela de cores
  4. fg_black=%{$'\e[0;30m'%}
  5. fg_red=%{$'\e[0;31m'%}
  6. fg_green=%{$'\e[0;32m'%}
  7. fg_brown=%{$'\e[0;33m'%}
  8. fg_blue=%{$'\e[0;34m'%}
  9. fg_purple=%{$'\e[0;35m'%}
  10. fg_cyan=%{$'\e[0;36m'%}
  11. fg_lgray=%{$'\e[0;37m'%}
  12. fg_dgray=%{$'\e[1;30m'%}
  13. fg_lred=%{$'\e[1;31m'%}
  14. fg_lgreen=%{$'\e[1;32m'%}
  15. fg_yellow=%{$'\e[1;33m'%}
  16. fg_lblue=%{$'\e[1;34m'%}
  17. fg_pink=%{$'\e[1;35m'%}
  18. fg_lcyan=%{$'\e[1;36m'%}
  19. fg_white=%{$'\e[1;37m'%}
  20. ###=========================================================================================
  21. ###=========================================================================================
  22. #Text Background Colors
  23. bg_red=%{$'\e[0;41m'%}
  24. bg_green=%{$'\e[0;42m'%}
  25. bg_brown=%{$'\e[0;43m'%}
  26. bg_blue=%{$'\e[0;44m'%}
  27. bg_purple=%{$'\e[0;45m'%}
  28. bg_cyan=%{$'\e[0;46m'%}
  29. bg_gray=%{$'\e[0;47m'%}
  30. #Attributes
  31. at_normal=%{$'\e[0m'%}
  32. at_bold=%{$'\e[1m'%}
  33. at_italics=%{$'\e[3m'%}
  34. at_underl=%{$'\e[4m'%}
  35. at_blink=%{$'\e[5m'%}
  36. at_outline=%{$'\e[6m'%}
  37. at_reverse=%{$'\e[7m'%}
  38. at_nondisp=%{$'\e[8m'%}
  39. at_strike=%{$'\e[9m'%}
  40. at_boldoff=%{$'\e[22m'%}
  41. at_italicsoff=%{$'\e[23m'%}
  42. at_underloff=%{$'\e[24m'%}
  43. at_blinkoff=%{$'\e[25m'%}
  44. at_reverseoff=%{$'\e[27m'%}
  45. at_strikeoff=%{$'\e[29m'%}
  46. ###=========================================================================================
  47. ###=========================================================================================
  48.  
  49. ###=====ESTILO 1 ===========================================================================
  50. #PROMPT="
  51. #${fg_lgreen}%n@%m %{$fg_dgray%}%D{[%I:%M:%S]}${fg_white}[${fg_cyan}%~${fg_white}]
  52. #%{$fg_lblue%}->%{$fg_lblue%} %#% ${at_normal}"
  53.  
  54. ###=========================================================================================
  55. ####======ESTILO 2 =========================================================================
  56. PROMPT=$'%{\e[0;34m%}%B┌─[%b%{\e[0m%}%{\e[1;30m%}%n%{\e[0;34m%}%B@%{\e[0m%}%{\e[1;30m%}%m%{\e[0;34m%}%B]%b%{\e[0;34m%}%B➫ %b%{\e[1;34m%}%B[%b%{\e[1;30m%}%~%{\e[0;34m%}%B]%b%{\e[0;34m%}%B➫ %{\e[0;34m%}%B[\e[0;33m%}%B'%D{"%A %d-%m-%Y %H:%M:%S"}%b$'%{\e[0;34m%}%B]%b%{\e[0m%}
  57. %{\e[0;34m%}%B└─%B[%{\e[0;37m%}$%{\e[0;34m%}%B]%{\e[0;34m%}%B➫%{\e[0m%}%B % '
  58. PS2=$' \e[0;34m%}%B>%{\e[0m%}%b '
  59.  
  60. ###=========================================================================================
  61. ####======ESTILO 3 =========================================================================
  62.  
  63. #PROMPT="%{$fg_lblue%}❱%{$fg_lgreen%}❱%{$fg_lblue%}❱%{$fg_lgreen%}❱%{$fg_lblue%}❱ %f"
  64. #RPS1="%{$fg_lblue%}❰%{$fg_lgreen%}❰%{$fg_dgray%}%B%~%{$fg_lblue%}❱%{$fg_lgreen%}❱%{$at_normal%} %B"
  65.  
  66. ###=========================================================================================
  67. ###=========================================================================================
  68. ## Lets set some options
  69. setopt correctall
  70. setopt autocd
  71. setopt auto_resume
  72. setopt extendedglob
  73. setopt completeinword
  74. unsetopt caseglob
  75. setopt CORRECT
  76. setopt ALWAYS_TO_END
  77. setopt NOTIFY
  78. setopt NOBEEP
  79. setopt AUTOLIST
  80. setopt PRINT_EIGHT_BIT
  81. ###=========================================================================================
  82. ###=========================================================================================
  83. ## Set some ZSH auto complete options
  84. zstyle ':completion:*:descriptions' format '%U%B%d%b%u'
  85. zstyle ':completion:*:warnings' format '%BSorry, no matches for: %d%b'
  86. zstyle ':completion:*:killall:*' command 'ps -u $USER -o cmd'
  87. zstyle ':completion:*' matcher-list 'm:{a-z}={A-Z}'
  88. zstyle ':completion:*:processes' command 'ps -au$USER'
  89. zstyle ':completion:*:*:kill:*:processes' list-colors "=(#b) #([0-9]#)*=36=31"
  90. zstyle ':completion:*' completer _expand _complete _ignored
  91. zstyle ':completion:*' list-colors ${(s.:.)LS_COLORS}
  92. zstyle ':completion:*' menu select=2
  93. zstyle ':completion:*' select-prompt '%SScrolling active: current selection at %p%s'
  94. ###=========================================================================================
  95. ###=========================================================================================
  96. ## History stuffs
  97. HISTFILE=~/.zsh-histfile
  98. HISTSIZE=5000
  99. SAVEHIST=5000
  100. setopt incappendhistory
  101. setopt sharehistory
  102. setopt extendedhistory
  103. ###=========================================================================================
  104. ###=========================================================================================
  105. ##ls, the common ones I use a lot shortened for rapid fire usage
  106. alias ls='ls --color' #I like color
  107. alias l='ls -lFh' #size,show type,human readable
  108. alias la='ls -lAFh' #long list,show almost all,show type,human readable
  109. alias lr='ls -tRFh' #sorted by date,recursive,show type,human readable
  110. alias lt='ls -ltFh' #long list,sorted by date,show type,human readable
  111. ###=========================================================================================
  112. ###=========================================================================================
  113. ## cd, because typing the backslash is A LOT of work!!
  114. ## not needed due to ZSH autocd opt
  115. #alias .='cd ../'
  116. #alias ..='cd ../../'
  117. #alias ...='cd ../../../'
  118. #alias ....='cd ../../../../'
  119. ###=========================================================================================
  120. ###=========================================================================================
  121. autoload -U zutil
  122. autoload -U compinit
  123. autoload -U complist
  124. ###=========================================================================================
  125. ###=========================================================================================
  126. bindkey '\e[A' history-search-backward
  127. bindkey '\e[B' history-search-forward
  128. bindkey '^K' kill-whole-line
  129. bindkey "\e[H" beginning-of-line # Home (xorg)
  130. bindkey "\e[1~" beginning-of-line # Home (console)
  131. bindkey "\e[4~" end-of-line # End (console)
  132. bindkey "\e[F" end-of-line # End (xorg)
  133. bindkey "\e[2~" overwrite-mode # Ins
  134. bindkey "\e[3~" delete-char # Delete
  135. bindkey '\eOH' beginning-of-line
  136. bindkey '\eOF' end-of-line
  137. ###=========================================================================================
  138. ###=========================================================================================
  139.  
  140. # Stupid Welcome intro.
  141.  
  142. setterm -foreground red -bold on -term linux
  143. echo ' _ '
  144. echo ' °v° ** Bem-vindo ao Slackware **'
  145. echo ' /(_)\ '
  146. echo ' ^ ^ ' `date`
  147. echo ' '
  148. setterm -foreground green -bold on -term linux
  149. cal -3
  150. echo
  151. echo " " `uptime`
  152. echo
  153. echo
  154. ###=========================================================================================
  155. ###=========================================================================================
  156. # Teclado abnt-2 e Ctrl+Alt+Backspace.
  157.  
  158. setxkbmap -model abnt2 -layout br -variant abnt2
  159. setxkbmap -option terminate:ctrl_alt_bksp
  160. ###=========================================================================================
  161. ###=========================================================================================
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement