zsh + oh-my-zsh 默认shell的最佳替代品

2022-12-28 08:38:57 浏览数 (1)

项目地址

zsh -----> http://www.zsh.org oh-my-zsh ----> http://ohmyz.sh

The last shell you’ll ever need!

使用方法

为你的MAC、Linux安装zsh

代码语言:javascript复制
# Centos
yum install zsh git -y

# OSX
brew install zsh git -y

安装oh-my-zsh

代码语言:javascript复制
# via curl

curl -L https://raw.github.com/robbyrussell/oh-my-zsh/master/tools/install.sh | sh

# via wget

wget https://raw.github.com/robbyrussell/oh-my-zsh/master/tools/install.sh -O - | sh

设置zsh为系统默认shell

代码语言:javascript复制
# 为root用户修改默认shell为zsh
chsh -s /bin/zsh root
# 为当前用户修改默认shell为zsh
chsh -s /bin/zsh
# or
chsh -s `which zsh`

# 恢复命令
chsh -s /bin/bash

add to ~/.zshrc

代码语言:javascript复制
export PATH=$PATH:/usr/local/go/bin
#export PATH=$PATH:/Applications/MAMP/bin/php/php5.6.10/bin:/Users/GZM/composer:/Users/GZM/.composer/vendor/bin
#export GOPATH=/Users/GZM/work/go
#export GOPATH=/Volumes/Transcend/git/360/private_cloud_server_code/tools/gowork/
#export GOBIN=$GOPATH/bin
#export GO15VENDOREXPERIMENT=1
LC_CTYPE=en_US.UTF-8
LC_ALL=en_US.UTF-8

插件

Plugins

升级

代码语言:javascript复制
upgrade_oh_my_zsh

0 人点赞