Commit 4edb0165015335f39755c987d1751463c381c952
Exists in
master
and in
2 other branches
conflict
Showing 6 changed files Inline Diff
templates/bash_aliases.sh
| File was created | 1 | # nav: | |
| 2 | alias ..="cd ../" | ||
| 3 | alias ...="cd ../../" | ||
| 4 | alias ....="cd ../../../" | ||
| 5 | alias .....="cd ../../../../" | ||
| 6 | |||
| 7 | alias ch="cat /etc/hosts" | ||
| 8 | alias lh="less /etc/hosts" | ||
| 9 | alias nh="sudo nano /etc/hosts" | ||
| 10 | |||
| 11 | alias na="nano ~/.bash_aliases" | ||
| 12 | alias nz="nano ~/.zshrc" | ||
| 13 | |||
| 14 | alias c="cat" | ||
| 15 | |||
| 16 | # docker: | ||
| 17 | alias docker="sudo docker" | ||
| 18 | |||
| 19 | alias de="sudo docker execute" | ||
| 20 | alias di="sudo docker inspect" | ||
| 21 | alias dim="sudo docker images" | ||
| 22 | alias dl="sudo docker logs -f" | ||
| 23 | alias dr="sudo docker rm" | ||
| 24 | alias dri="sudo docker rmi" | ||
| 25 | alias ds="sudo docker stop" | ||
| 26 | alias dsta="sudo docker start" | ||
| 27 | alias dps="sudo docker ps" | ||
| 28 | alias fig="sudo fig" | ||
| 29 | |||
| 30 | export LS_OPTIONS='--color=always' | ||
| 31 | alias ll="ls $LS_OPTIONS -Alh" | ||
| 32 | alias l="ls $LS_OPTIONS -lh" | ||
| 33 | |||
| 34 | # misc: | ||
| 35 | alias e="exit" | ||
| 36 | alias mkp="makepasswd --chars" | ||
| 37 | alias n="nano" | ||
| 38 | alias p="python" | ||
| 39 | alias ports="netstat -tulanp" | ||
| 40 | |||
| 41 | alias tt="touch" | ||
| 42 | |||
| 43 | # OpenVZ: | ||
| 44 | alias vl="vzlist" | ||
| 45 | alias ve="vzctl enter" | ||
| 46 | |||
| 47 | # fix common_aliases (zsh): | ||
| 1 | # nav: | 48 | alias rm='rm' |
| 2 | alias ..="cd ../" | 49 | alias cp='cp' |
| 3 | alias ...="cd ../../" | 50 | alias mv='mv' |
templates/bashrc.sh
| File was created | 1 | # If not running interactively, don't do anything | |
| 2 | case $- in | ||
| 3 | *i*) ;; | ||
| 4 | *) return;; | ||
| 5 | esac | ||
| 6 | |||
| 7 | ######################## | ||
| 8 | # ******************** # | ||
| 9 | # * * # | ||
| 10 | # * COMPLETION * # | ||
| 11 | # * * # | ||
| 12 | # ******************** # | ||
| 13 | ######################## | ||
| 14 | |||
| 15 | # enable bash completion in interactive shells | ||
| 16 | if [ -f /etc/bash_completion ]; then | ||
| 17 | . /etc/bash_completion | ||
| 18 | fi | ||
| 19 | |||
| 20 | # if the command-not-found package is installed, use it | ||
| 21 | if [ -x /usr/lib/command-not-found ]; then | ||
| 22 | function command_not_found_handle { | ||
| 23 | # check because c-n-f could've been removed in the meantime | ||
| 24 | if [ -x /usr/lib/command-not-found ]; then | ||
| 25 | /usr/bin/python /usr/lib/command-not-found -- $1 | ||
| 26 | return $? | ||
| 27 | else | ||
| 28 | return 127 | ||
| 29 | fi | ||
| 30 | } | ||
| 31 | fi | ||
| 32 | |||
| 33 | ######################## | ||
| 34 | # ******************** # | ||
| 35 | # * * # | ||
| 36 | # * HISTORY * # | ||
| 37 | # * * # | ||
| 38 | # ******************** # | ||
| 39 | ######################## | ||
| 40 | |||
| 41 | # Eternal bash history. | ||
| 42 | # --------------------- | ||
| 43 | export HISTFILESIZE= | ||
| 44 | export HISTSIZE= | ||
| 45 | export HISTTIMEFORMAT="[%F %T] " | ||
| 46 | # Change the file location | ||
| 47 | export HISTFILE=~/.new_bash_history | ||
| 48 | # Force prompt to write history after every command | ||
| 49 | PROMPT_COMMAND="history -a; $PROMPT_COMMAND" | ||
| 50 | |||
| 51 | |||
| 52 | # check the window size after each command | ||
| 53 | shopt -s checkwinsize | ||
| 54 | |||
| 55 | # If set, the pattern "**" used in a pathname expansion context will | ||
| 56 | # match all files and zero or more directories and subdirectories. | ||
| 57 | #shopt -s globstar | ||
| 58 | |||
| 59 | # set variable identifying the chroot you work in (used in the prompt below) | ||
| 60 | if [ -z "${debian_chroot:-}" ] && [ -r /etc/debian_chroot ]; then | ||
| 61 | debian_chroot=$(cat /etc/debian_chroot) | ||
| 62 | fi | ||
| 63 | |||
| 64 | # set a fancy prompt | ||
| 65 | case "$TERM" in | ||
| 66 | xterm-color) color_prompt=yes;; | ||
| 67 | esac | ||
| 68 | |||
| 69 | # colored prompt | ||
| 70 | force_color_prompt=yes | ||
| 71 | |||
| 72 | if [ -n "$force_color_prompt" ]; then | ||
| 73 | if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then | ||
| 74 | # We have color support; assume it's compliant with Ecma-48 | ||
| 75 | # (ISO/IEC-6429). (Lack of such support is extremely rare, and such | ||
| 76 | # a case would tend to support setf rather than setaf.) | ||
| 77 | color_prompt=yes | ||
| 78 | else | ||
| 79 | color_prompt= | ||
| 80 | fi | ||
| 81 | fi | ||
| 82 | |||
| 83 | if [ "$color_prompt" = yes ]; then | ||
| 84 | PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ ' | ||
| 85 | else | ||
| 86 | PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ ' | ||
| 87 | fi | ||
| 88 | #unset color_prompt force_color_prompt | ||
| 89 | |||
| 90 | # enable color support of ls and also add handy aliases | ||
| 91 | if [ -x /usr/bin/dircolors ]; then | ||
| 92 | test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)" | ||
| 93 | alias ls='ls --color=auto' | ||
| 94 | alias dir='dir --color=auto' | ||
| 95 | alias vdir='vdir --color=auto' | ||
| 96 | |||
| 97 | alias grep='grep --color=auto' | ||
| 98 | alias fgrep='fgrep --color=auto' | ||
| 99 | alias egrep='egrep --color=auto' | ||
| 100 | fi | ||
| 101 | |||
| 102 | |||
| 103 | # Alias definitions | ||
| 104 | |||
| 105 | if [ -f ~/.bash_aliases ]; then | ||
| 106 | . ~/.bash_aliases | ||
| 107 | fi | ||
| 1 | # If not running interactively, don't do anything | 108 |
templates/zshrc.sh
| File was created | 1 | #@IgnoreInspection AddShebang | |
| 2 | # ENVIRONMENT: | ||
| 3 | export GJ_DEVENV=local_aptproxy | ||
| 4 | |||
| 5 | export ZCFG=~/.config/zsh-config | ||
| 6 | # Path to your oh-my-zsh installation. | ||
| 7 | export ZSH=$ZCFG/tools/oh-my-zsh | ||
| 8 | |||
| 9 | # Set name of the theme to load. | ||
| 10 | # Look in ~/.oh-my-zsh/themes/ | ||
| 11 | # Optionally, if you set this to "random", it'll load a random theme each | ||
| 12 | # time that oh-my-zsh is loaded. | ||
| 13 | ZSH_THEME="muse" | ||
| 14 | |||
| 15 | CASE_SENSITIVE="true" | ||
| 16 | DISABLE_AUTO_UPDATE="true" | ||
| 17 | DISABLE_AUTO_TITLE="true" | ||
| 18 | ENABLE_CORRECTION="true" | ||
| 19 | COMPLETION_WAITING_DOTS="true" | ||
| 20 | DISABLE_UNTRACKED_FILES_DIRTY="true" | ||
| 21 | HIST_STAMPS="dd.mm.yyyy" | ||
| 22 | ZSH_CUSTOM=ZCFG/custom | ||
| 23 | |||
| 24 | plugins=(command-not-found common-aliases debian dirhistory git history history-substring-search systemadmin zsh_reload | ||
| 25 | pip python virtualenv virtualenvwrapper | ||
| 26 | meteor node npm | ||
| 27 | ) | ||
| 28 | |||
| 29 | # User configuration | ||
| 30 | export PATH=$HOME/bin:/usr/local/bin:$PATH | ||
| 31 | # export MANPATH="/usr/local/man:$MANPATH" | ||
| 32 | |||
| 33 | source $ZSH/oh-my-zsh.sh | ||
| 34 | export LANG=en_US.UTF-8 | ||
| 35 | |||
| 36 | # ANTIGEN: | ||
| 37 | # | ||
| 38 | # source $ZCFG/tools/antigen/antigen.zsh | ||
| 39 | # | ||
| 40 | # MUST: | ||
| 41 | #antigen bundle extract | ||
| 42 | # | ||
| 43 | # | ||
| 44 | # NICE: | ||
| 45 | #antigen bundle iwhois | ||
| 46 | #antigen bundle screen | ||
| 47 | #antigen bundle ssh-agent | ||
| 48 | #antigen bundle web-search | ||
| 49 | # # if webdev: | ||
| 50 | #antigen bundle catimg | ||
| 51 | # | ||
| 52 | # docker: | ||
| 53 | #antigen bundle docker | ||
| 54 | # | ||
| 55 | # kde: | ||
| 56 | #antigen bundle kate | ||
| 57 | # | ||
| 58 | # removed: | ||
| 59 | #antigen bundle autoenv | ||
| 60 | #antigen bundle iwhois | ||
| 61 | #antigen bundle per-directory-history | ||
| 62 | #antigen bundle screen | ||
| 63 | # | ||
| 64 | # THEME #---------- | ||
| 65 | # | ||
| 66 | #antigen theme muse | ||
| 67 | # | ||
| 68 | #antigen apply | ||
| 69 | |||
| 70 | # ssh | ||
| 71 | # export SSH_KEY_PATH="~/.ssh/id_rsa" | ||
| 72 | # zstyle :omz:plugins:ssh-agent agent-forwarding on | ||
| 73 | |||
| 74 | # Preferred editor for local and remote sessions | ||
| 75 | # if [[ -n $SSH_CONNECTION ]]; then | ||
| 76 | # export EDITOR='vim' | ||
| 77 | # else | ||
| 78 | # export EDITOR='mvim' | ||
| 79 | # fi | ||
| 80 | |||
| 81 | # Compilation flags | ||
| 82 | export ARCHFLAGS="-arch x86_64" | ||
| 83 | |||
| 84 | if [ -f ~/.bash_aliases ]; then | ||
| 85 | . ~/.bash_aliases | ||
| 86 | fi | ||
| 87 |