# Clash入门 **Published by:** [kethylar](https://paragraph.com/@kethylar/) **Published on:** 2023-02-15 **URL:** https://paragraph.com/@kethylar/clash ## Content 安装go,配置go镜像代理brew install go go env -w GO111MODULE=on go env -w GOPROXY="https://goproxy.io,direct" 镜像配置参考 https://goproxy.io/GOPATH环境变量配置(根据自己需求调整)export GOPATH=$HOME/go export PATH=$PATH:$GOPATH/bin 安装clashgo get -u -v http://github.com/Dreamacro/clash 配置clash参考 https://github.com/Dreamacro/clash/wiki/configurationmixed-port: 7890 allow-lan: false bind-address: '*' mode: rule log-level: info proxies: - name: "myal" type: ss server: xxxxxxxx port: "xxxx" cipher: xxxxxxx password: xxxxxxx - name: "mydo" type: ss server: xxxxxxxx port: "xxxx" cipher: xxxxxxxx password: xxxxxxxxx proxy-groups: - name: Proxy type: url-test proxies: - myal - mydo url: 'https://www.google.com' interval: 300 rules: - DOMAIN-SUFFIX,google.com,Proxy - DOMAIN-KEYWORD,google,Proxy - DOMAIN-KEYWORD,google-analytics.com,Proxy - DOMAIN-KEYWORD,gtatic.com,Proxy - DOMAIN-KEYWORD,tensorflow.org,Proxy - DOMAIN-KEYWORD,github.io,Proxy - DOMAIN-KEYWORD,github.com,Proxy - DOMAIN-KEYWORD,quora.com,Proxy - DOMAIN-KEYWORD,twitter,Proxy - IP-CIDR,127.0.0.0/8,DIRECT - GEOIP,CN,DIRECT - MATCH,Proxy 启动clash ## Publication Information - [kethylar](https://paragraph.com/@kethylar/): Publication homepage - [All Posts](https://paragraph.com/@kethylar/): More posts from this publication - [RSS Feed](https://api.paragraph.com/blogs/rss/@kethylar): Subscribe to updates