Files
rcfiles/zshrc.minimal

107 lines
3.2 KiB
Plaintext

export SHELL=/bin/zsh
# If you come from bash you might have to change your $PATH.
export PATH=$HOME/.local/bin:/usr/local/bin:$PATH
export PROMPT='%n@%m:%~$ '
export HISTFILE="$HOME/.zhistory"
export HISTSIZE=8000
export SAVEHIST=8000
setopt BANG_HIST # Treat the '!' character specially during expansion.
setopt EXTENDED_HISTORY # Write the history file in the ":start:elapsed;command" format.
#setopt INC_APPEND_HISTORY # Write to the history file immediately, not when the shell exits.
setopt SHARE_HISTORY # Share history between all sessions.
setopt HIST_EXPIRE_DUPS_FIRST # Expire duplicate entries first when trimming history.
setopt HIST_IGNORE_DUPS # Don't record an entry that was just recorded again.
setopt HIST_IGNORE_ALL_DUPS # Delete old recorded entry if new entry is a duplicate.
setopt HIST_FIND_NO_DUPS # Do not display a line previously found.
setopt HIST_IGNORE_SPACE # Don't record an entry starting with a space.
setopt HIST_SAVE_NO_DUPS # Don't write duplicate entries in the history file.
setopt HIST_REDUCE_BLANKS # Remove superfluous blanks before recording entry.
setopt HIST_VERIFY # Don't execute immediately upon history expansion.
setopt HIST_BEEP # Beep when accessing nonexistent history.
# 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_KEY_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"
# Customized
export EDITOR="vim"
bindkey -v
alias ls='ls --color'
alias ll='ls -l'
alias la='ls -a'
alias javac="javac -J-Dfile.encoding=utf8"
alias grep="grep --color=auto"
alias mc='mkcpp'
alias mcv='mkcpp -V'
alias fasm='fasm -m 1677216'
alias pacman='sudo pacman'
alias sctl='sudo systemctl'
alias steamcmd='sudo -u steam steamcmd'
alias gdbtui='gdb -q -tui'
alias gdb='gdb -q'
alias nethack='TERM=xterm-color nethack'
alias -s c=vim
alias -s cpp=vim
alias -s h=vim
alias -s hpp=vim
alias -s go=vim
alias -s java=vim
alias -s txt=vim
alias -s gz='tar -xzvf'
alias -s tgz='tar -xzvf'
alias -s zip='unzip'
alias -s bz2='tar -xjvf'
bindkey '^[OA' history-beginning-search-backward
bindkey '^[[A' history-beginning-search-backward
bindkey '^[OB' history-beginning-search-forward
bindkey '^[[B' history-beginning-search-forward
export LANG="zh_CN.UTF-8"
#export LANGUAGE="zh_CN.UTF-8"
# The following lines were added by compinstall
zstyle ':completion:*' matcher-list 'm:{[:lower:]}={[:upper:]} r:|[._-]=** r:|=** l:|=*'
zstyle :compinstall filename '/home/edgar/.zshrc'
autoload -Uz compinit
compinit
# End of lines added by compinstall