stuartcryan / defaultbrowser

Command line script for getting and setting a default browser (HTTP handler) in Mac OS X

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

defaultbrowser

Command line script for getting and setting a default browser (HTTP handler) in Mac OS X.

As there seems no other elegant way of doing it you need some Objective-C code.

The code uses Launch Services. More info on Launch Services Reference

Usage

Open the XCode project and build it or download the build/defaultbrowser and put it somewhere in your path. chmod +x defaultbrowser is probably also necessary.

You can set the default browser with:

defaultbrowser -set chrome

Running defaultbrowser without arguments shows the current setting.

About

Command line script for getting and setting a default browser (HTTP handler) in Mac OS X

License:MIT License


Languages

Language:Objective-C 50.6%Language:Groff 49.4%