Tips-Terminal

203 阅读1分钟

Alias(别名)

  1. vim ~/.bashrc
  2. alias pi='pod install --no-repo-update --verbose'
  3. source ~/.bashrc
  4. vim ~/.bash_profile
  5. source ~/.bashrc

代理

设置代理

git config --global http.proxy "localhost:7890"

取消代理

unset http_proxy

git clone 慢

原因

github.global.ssl.fastly.net域名被限制

找到ip

www.ipaddress.com/

  • github.global.ssl.fastly.net
  • github.com

host 映射

  • 151.101.185.194 github.global-ssl.fastly.net
  • 192.30.253.112 github.com

重启iTerm2

hosts

  • sudo vim /etc/hosts

iTerm2 快捷键

  • 垂直分屏 command + d
  • 清除当前行 ctrl + u
  • 到行首 ctrl + a
  • 到行尾 ctrl + e