-
-
Save et2010/5d6edeeb284e33343d0a to your computer and use it in GitHub Desktop.
(setq url-gateway-method 'socks) | |
(setq socks-server '("Default server" "127.0.0.1" 1080 5)) |
支持http协议吗?
I got sock5 proxy client(Qv2ray) running in the background, when I want to use it in the terminal, I'll use proxychains cmd, I got socks5 127.0.0.1 1080 in my proxychains.conf file, when I want to use it in my browser, I got SwitchyOmega extension and set it to socks5 127.0.0.1 1080.
I tried this gist in my emacs/spacemacs, it doesn't work at all.
BTW: How can I check if it is using socks proxy? Currently, when I install a package, it hangs and failed to install it, so I believe my emacs is not using the proxy. (When I use proxychains emacs
in terminal, it installs pacakge very quickly)
I have tried this, it worked.
;;----------------------------------------------------------------------------
;; proxy setting for url-retrieve, used by eww, w3m...
;;----------------------------------------------------------------------------
(setq url-proxy-services
'(("no_proxy" . "^.*example.com")
("https" . "localhost:1087")
("http" . "localhost:1087")
;; socks not working, @see url-default-find-proxy-for-url
;; ("socks5" . "localhost:1080")
))
Thank you