> For the complete documentation index, see [llms.txt](https://tmoev2.gitbook.io/tmoev2doc/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://tmoev2.gitbook.io/tmoev2doc/skills.md).

# 使用技巧

由于作者使用 Mac 较多，所以仅仅介绍一下 Mac 的,其它的慢慢补充

## 1.命令行代理

* 不使用 Oh My *Zsh 下*

推荐将下面的代码写到 `~/.bash_profile` 中去

```bash

#终端代理控制
function all_off(){
    unset http_proxy  # 如果不想设置方法，则单独执行这两句就可以删除配置的环境变量
    unset https_proxy
    echo -e "Unset ==> localhost,127.0.0.1,localaddress,.localdomain.com"
}
function v2_on(){
    export http_proxy="http://127.0.0.1:8080"; 
    export HTTP_PROXY="http://127.0.0.1:8080"; 
    export https_proxy="http://127.0.0.1:8080"; 
    export HTTPS_PROXY="http://127.0.0.1:8080"
    echo -e "V2ray 终端代理已经打开，请放心使用，请注意开启 v2代理"
}

```

使用的时候仅需要在命令行中输入 `v2_on` 即可开启代理

![](https://1260888699-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LUcv5pr-c2Ydfua63MJ%2F-LVInTmgVCVIdYdYqao0%2F-LVInZ2elxL9UD5TBWa_%2Faac4ea3cfaaef88f7291b68487c8d577.png?alt=media\&token=8b303929-f1dc-422f-8fa2-e436d0542247)

* 如果使用了 Oh My *Zsh*&#x20;

*则需要在* `~/.zshrc` 中添加一句更新语句

```bash
# 自动更新环境变量
source ~/.bash_profile
```

然后就可以快乐的使用啦
