Ubuntu 16.04终端安装oh-my-zsh

对于我已经用习惯linux的人来说,每天都要和终端打交道,此时想打扮一下终端,oh-my-zsh is perfect!

Go!

给出安装步骤以及修改主题、遇到问题:

①安装zsh和git:

sudo apt-get install zsh

sudo apt-get install git

②安装oh-my-zsh:

输入:sh -c “$(curl -fsSL https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh)”

到此我遇到GitHub的raw.githubusercontent.com无法连接的问题:

解决方案:

sudo vim /etc/hosts

添加并保存:

# GitHub Start
52.74.223.119 github.com
192.30.253.119 gist.github.com
54.169.195.247 api.github.com
185.199.111.153 assets-cdn.github.com
151.101.76.133 raw.githubusercontent.com
151.101.108.133 user-images.githubusercontent.com
151.101.76.133 gist.githubusercontent.com
151.101.76.133 cloud.githubusercontent.com
151.101.76.133 camo.githubusercontent.com
151.101.76.133 avatars0.githubusercontent.com
151.101.76.133 avatars1.githubusercontent.com
151.101.76.133 avatars2.githubusercontent.com
151.101.76.133 avatars3.githubusercontent.com
151.101.76.133 avatars4.githubusercontent.com
151.101.76.133 avatars5.githubusercontent.com
151.101.76.133 avatars6.githubusercontent.com
151.101.76.133 avatars7.githubusercontent.com
151.101.76.133 avatars8.githubusercontent.com
# GitHub End

再次输入:

sh -c “$(curl -fsSL https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh)”

此时可以成功连接

③切换自己喜欢的主题:

进入oh-my-zsh官网:https://ohmyz.sh/ 找到主题,选择自己喜欢的主题并且复制该主题名字

输入:

vim ~/.zshrc

在ZSH_THEME=“” 一行粘贴上主题名字,个人推荐ys比较舒服。

保存好后:

source ~/.zshrc 使配置生效

完成!

在最后在推荐一个终端分屏软件:

sudo apt-get install terminator

你下好了就知道啥感觉了。

  • 2
    点赞
  • 3
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值