Allow configuring default browser to use when opening a URL

Description

Original runwar issue #131

The list of browsers is hard-coded, expose a way to configure which is tried first.

Activity

Show:
Miguel Mathus
August 17, 2020, 11:37 PM

Hello can you take a look on this?
Runwar


Commandbox

Brad Wood
August 19, 2020, 5:01 PM

This is a pretty good start. CommandBox has a duplicate open browser function inside the FileSystem.cfc that also needs to use this settings.

Also, it should be noted that the new server.json setting you added is only used for Linux. We haven’t modified the Windows or Mac logic. We should at least do a precursory check to see if we can force the browser on other operating systems since I think CommandBox users will expect this setting to work all the time.

You refactored out the section of code that looks for browsers on Unix, but in reality that entire open browser bit needs to be abstracted. The logic you moved to the Utils class actually belonged in the openbrowser.java class. What should have happened is you needed to remove the entire browser opening logic from launchUtil and replaced it with a call to the openbrowser class.

Miguel Mathus
August 31, 2020, 3:51 PM

Hi I have made several changes

adding the logic to the remainings OS.

Miguel Mathus
September 30, 2020, 6:01 PM

Documentation:

To set prefered browser is necesary the next command:

i.e.

Assignee

Miguel Mathus

Reporter

Brad Wood

Labels

None

Affects versions

Fix versions

Priority

Minor

Components

Configure