On 4/29/20 6:30 PM, Tim Cross wrote:
> 
> Jude DaShiell <jdash...@panix.com> writes:
> 
>> Two different scripts one yproxy and the other nproxy.
>> Put the necessary running code in each.
>>
>> On Wed, 29 Apr 2020, Neil Cherry wrote:
>>
>>> Date: Wed, 29 Apr 2020 13:36:50
>>> From: Neil Cherry <nche...@linuxha.com>
>>> To: Org Mode <emacs-orgmode@gnu.org>
>>> Subject: org-mode setting the browser with options
>>>
>>> I need to use 2 different Windows browser (proxy and no-proxy is the 
>>> reason).
>>>
>>> What I want to do is that if it's example.com use firefox (no options). If 
>>> it's
>>> example.org use chrome --no-proxy-server. I'm not exacly sure how to 
>>> approach this.
>>>
>>> Thanks
>>>
>>>
> 
> I would look at browse-url built-in package. With browse-url you can set
> a function that will determine which browser to use based on the url and
> you can set the options for each supported browser. 
> 

Thanks, that got me thinking and search-fu found:

(setq
 browse-url-browser-function
 '(
  ("example\\.com" . browse-url-chrome)
  ("example\\.org" . browse-url-chrome)
  ("." . browse-url-default-browser)
  ))

Which works perfect!

Thanks
-- 
Linux Home Automation         Neil Cherry       nche...@linuxha.com
http://www.linuxha.com/                         Main site
http://linuxha.blogspot.com/                    My HA Blog
Author of:      Linux Smart Homes For Dummies

Reply via email to