zsh与oh-my-zsh的安装

本文详细介绍了如何在Deepin 15.11系统中安装和配置ZSH及Oh-My-ZSH,包括安装ZSH、安装Oh-My-ZSH、设置ZSH为默认Shell、配置Oh-My-ZSH目录权限、设置跳过不安全目录验证、安装插件以及高亮显示等步骤。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

环境

Deepin 15.11

安装

  • 安装zsh
sudo apt install zsh
  • 安装oh-my-zsh
wget https://raw.github.com/robbyrussell/oh-my-zsh/master/tools/install.sh -O - | sh

配置

  • 设置zsh为默认shell
chsh -s /bin/zsh
  • 对oh-my-zsh目录授权
chmod -R 777 ~/.oh-my-zsh
  • 设置跳过不安全目录验证

~/.zshrc

# on the top of the files
ZSH_DISABLE_COMPFIX="true"

插件安装

~/.zshrc

# Which plugins would you like to load?
# Standard plugins can be found in ~/.oh-my-zsh/plugins/*
# Custom plugins may be added to ~/.oh-my-zsh/custom/plugins/
# Example format: plugins=(rails git textmate ruby lighthouse)
# Add wisely, as too many plugins slow down shell startup.
plugins=(
    git
    zsh-autosuggestions
    colored-man-pages
)

# 文件末尾
source "$ZSH_CUSTOM/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh"
  • 提示
git clone https://github.com/zsh-users/zsh-autosuggestions $ZSH_CUSTOM/plugins/zsh-autosuggestions
  • 高亮
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git $ZSH_CUSTOM/plugins/zsh-syntax-highlighting
source ~/.zshrc
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值