Can anyone tell me how to open a browser from the Terminal on a Mac?
To have your OS X machine open the default browser to a specific page, you just have to type:
Simple as pie. The
open command was introduced way back on the NeXT operating system, and in its modern incarnation, uses LaunchServices to determine the appropriate application to open the given file or URL.
If the default application for opening HTML files has been changed to a text editor,
open test.html would open the file in the editor.
You could open it in the default browser with
open test.html -a "$(VERSIONER_PERL_PREFER_32_BIT=true perl -MMac::InternetConfig -le 'print +(GetICHelper "http")')".