File tree Expand file tree Collapse file tree 1 file changed +7
-6
lines changed Expand file tree Collapse file tree 1 file changed +7
-6
lines changed Original file line number Diff line number Diff line change 276
276
(defun proxy-socks-enable ()
277
277
" Enable SOCKS proxy."
278
278
(interactive )
279
- (setq url-gateway-method 'socks )
280
- (setq socks-noproxy '(" localhost" ))
281
- (setq socks-server '(" Default server" " 127.0.0.1" 1086 5 ))
279
+ (require 'socks )
280
+ (setq url-gateway-method 'socks
281
+ socks-noproxy '(" localhost" )
282
+ socks-server '(" Default server" " 127.0.0.1" 1086 5 ))
282
283
(proxy-socks-show))
283
284
284
285
(defun proxy-socks-disable ()
285
286
" Disable SOCKS proxy."
286
287
(interactive )
287
- (setq url-gateway-method 'native )
288
- ( setq socks-noproxy nil )
288
+ (setq url-gateway-method 'native
289
+ socks-noproxy nil )
289
290
(proxy-socks-show))
290
291
291
292
(defun proxy-socks-toggle ()
292
293
" Toggle SOCKS proxy."
293
294
(interactive )
294
- (if socks-noproxy
295
+ (if ( bound-and-true-p socks-noproxy)
295
296
(proxy-socks-disable)
296
297
(proxy-socks-enable)))
297
298
You can’t perform that action at this time.
0 commit comments