banner
AcoFork

AcoFork

LOVETOLOVE

Deepin安裝Oh My Zsh

  1. 更新軟體源並安裝 zsh 和基本依賴
# 更新軟體源
sudo apt update && sudo apt upgrade -y
# 安裝 zsh git curl wget
sudo apt install zsh git curl wget -y
  1. 設置預設終端為 zsh(若你使用 Deepin 終端需要手動配置)
chsh -s /bin/zsh

image

  1. 安裝 Oh My Zsh
# 官方源
sh -c "$(wget -O- https://install.ohmyz.sh/)"
# 國內鏡像
sh -c "$(wget -O- https://gitee.com/pocmon/ohmyzsh/raw/master/tools/install.sh)"
  1. 安裝 haoomz 主題
sudo wget -O $ZSH_CUSTOM/themes/haoomz.zsh-theme https://cdn.haoyep.com/gh/leegical/Blog_img/zsh/haoomz.zsh-theme
  1. 啟用 haoomz 主題
nano ~/.zshrc
## 更改主題
ZSH_THEME="haoomz"

source ~/.zshrc

image

  1. 安裝命令預測插件 zsh -autosuggestions
git clone https://github.com/zsh-users/zsh-autosuggestions ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions
  1. 安裝命令校驗插件 zsh-syntax-highlighting
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting
  1. 更改配置文件以啟用插件
nano ~/.zshrc

plugins=(
  git
  zsh-autosuggestions
  zsh-syntax-highlighting
)

source ~/.zshrc

image

  1. 大功告成

image

image

image

image

載入中......
此文章數據所有權由區塊鏈加密技術和智能合約保障僅歸創作者所有。