1. zsh包含自动补全插件
@30aa0658f7f8 ~ % cat .zshrc
autoload -Uz promptinit
promptinit
prompt adam1
setopt histignorealldups sharehistory
bindkey -e
HISTSIZE = 1000
SAVEHIST = 1000
HISTFILE =~ /.zsh_history
autoload -Uz compinit
compinit
zstyle ':completion:*' auto-description 'specify: %d'
zstyle ':completion:*' completer _expand _complete _correct _approximate
zstyle ':completion:*' format 'Completing %d'
zstyle ':completion:*' group-name ''
zstyle ':completion:*' menu select = 2
eval "$( dircolors -b ) "
zstyle ':completion:*:default' list-colors ${(s.: .)LS_COLORS}
zstyle ':completion:*' list-colors ''
zstyle ':completion:*' list-prompt %SAt %p: Hit TAB for more, or the character to insert%s
zstyle ':completion:*' matcher-list '' 'm:{a-z}={A-Z}' 'm:{a-zA-Z}={A-Za-z}' 'r:|[._-]=* r:|=* l:|=*'
zstyle ':completion:*' menu select = long
zstyle ':completion:*' select-prompt %SScrolling active: current selection at %p%s
zstyle ':completion:*' use-compctl false
zstyle ':completion:*' verbose true
zstyle ':completion:*:*:kill:*:processes' list-colors '=(#b) #([0-9]#)*=0=01;31'
zstyle ':completion:*:kill:*' command 'ps -u $USER -o pid,%cpu,tty,cputime,cmd'
source /usr/share/zplug/init.zsh
zplug "plugins/git" , from:oh-my-zsh
zplug "plugins/sudo" , from:oh-my-zsh
zplug "plugins/command-not-found" , from:oh-my-zsh
zplug "zsh-users/zsh-syntax-highlighting"
zplug "zsh-users/zsh-autosuggestions"
zplug "zsh-users/zsh-history-substring-search"
zplug "zsh-users/zsh-completions"
zplug "junegunn/fzf"
zplug "themes/robbyrussell" , from:oh-my-zsh, as:theme
if ! zplug check --verbose; then
printf "Install? [y/N]: "
if read -q; then
echo ; zplug install
fi
fi
zplug load --verbose
2. apt更换软件源
sudo cp /etc/apt/sources.list /etc/apt/sources.list.backup
sudo sed -i 's/http:\/\/archive.ubuntu.com\/ubuntu\//https:\/\/mirrors.tuna.tsinghua.edu.cn\/ubuntu\//g' /etc/apt/sources.list
sudo apt update