Created
March 26, 2017 09:54
-
-
Save x10w50/652a93464f5b254885eba85754051ba2 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
我的环境是MAC下,MAC默认安装了zsh(一些教程会让安装zsh,如果已经默认安装,就没必要再装了)使用命令查看是否已经安装 | |
cat /etc/shells | |
应该会看到 | |
/bin/bash | |
/bin/csh | |
/bin/ksh | |
/bin/sh | |
/bin/tcsh | |
/bin/zsh(这个哟~~) | |
已经确定zsh存在,开始安装 oh my zsh(这名字起得,想想还让人有点小激动呢~~),下面是手动安装,自动安装的请自行Google。 | |
首先将项目克隆到本地(什么?不会用git?那我想对你说,see u &有事写信) | |
git clone git://github.com/robbyrussell/oh-my-zsh.git ~/.oh-my-zsh | |
如果之前有一个~/.zshrc文件的话,建议先做备份,不过如果看到这篇帖子的话,很大比例是第一次装,我是第一次装,省略了这一步。保险起见还是看看有没有这个文件,万一别人在这台电脑上鼓捣过呢? | |
cp ~/.zshrc ~/.zshrc.orig | |
创建zsh的配置文件 | |
cp ~/.oh-my-zsh/templates/zshrc.zsh-template ~/.zshrc | |
设置zsh为你的默认的shell | |
chsh -s /bin/zsh | |
当然你可能还需要把你的bash的配置文件(~/.bash_prorile或者~/.profile等)给拷贝到zsh的配置文件~/.zshrc里,因为zsh兼容bash,所以你大可放心把bash的配置粘贴到~/.zshrc底部便可。(这一句是引用,如有雷同,不胜荣幸,大神们不会计较的,所以我很放心,哈哈) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment