mac shell

安装brew

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

查看SHELL

当前系统安装了哪些shell$ cat /etc/shells

当前正在使用的shell$ echo $SHELL

oh my fish

安装$ brew install fish

即可使用

  • 切换fish shell
    $ chsh -s /usr/local/bin/fish

zsh

zsh安装及配置

$ git clone git://github.com/robbyrussell/oh-my-zsh.git
$ cp ~/.zshrc ~/.zshrc.orig这个可以跳过不执行,最好是执行
$ cp ~/.oh-my-zsh/templates/zshrc.zsh-template ~/.zshrc

wget安装方式

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

mac安装

$ brew install zsh

安装完成后切换到zsh

$ chsh -s /bin/zsh

  • 如果无法切换到zsh可能是环境变量的问题,终端执行
$ source ~/.zshrc
$ chsh -s /bin/zsh

切换回默认shell

$ chsh -s /bin/bash

配置zsh时需要修改.zshrc文件
//找到.zshrc文件
//修改theme
exportZSHTHEME=afowler//themes.ohmyzsh/themes cd ~/
$ cd .oh-my-zsh/themes就到了theme目录

> - **中文乱码问题**
编辑 ~/.zshrc在文件内容末端添加:

export LC_ALL=en_US.UTF-8
export LANG=en_US.UTF-8

重启终端,或终端执行
$ source ~/.zshrc“`

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值