简介

官网:https://ohmyz.sh/
Github:https://github.com/ohmyzsh/ohmyzsh
Gitee:https://gitee.com/mirrors/oh-my-zsh

准备

安装 zsh

  1. yum install zsh
  2. brew install zsh

安装 git

  1. yum install git
  2. brew install git

安装

官方脚本

  1. sh -c "$(curl -fsSL https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
  1. sh -c "$(wget https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh -O -)"

Q1: 出现“Connection refused”

  1. 192:~ yulm$ sh -c "$(wget https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh -O -)"
  2. --2022-07-19 12:38:38-- https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh
  3. 正在解析主机 raw.github.com (raw.github.com)... 185.199.110.133, 185.199.111.133, 185.199.109.133, ...
  4. 正在连接 raw.github.com (raw.github.com)|185.199.110.133|:443... 已连接。
  5. 已发出 HTTP 请求,正在等待回应... 301 Moved Permanently
  6. 位置:https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh [跟随至新的 URL]
  7. --2022-07-19 12:38:38-- https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh
  8. 正在解析主机 raw.githubusercontent.com (raw.githubusercontent.com)... 0.0.0.0
  9. 正在连接 raw.githubusercontent.com (raw.githubusercontent.com)|0.0.0.0|:443... 失败:Connection refused

使用国内源(推荐)

  1. sh -c "$(curl -fsSL https://gitee.com/mlyu555/ohmyzsh/raw/master/install.sh)"
  1. sh -c "$(wget https://gitee.com/mlyu555/ohmyzsh/raw/master/install.sh -O -)"

修改文件内容:

卸载

  • todo

bash uninstall.sh