Follow the install guide. Note that there is an installer for Mac.
Open your terminal of choice. Run echo $GOPATH
.
You should see something like /usr/local/go
. Inside this folder, there will be a src folder. If there isn't one created yet, run mkdir $GOPATH/src
.
Fork Browsh to your Github account. Clone this fork of Browsh to your $GOPATH/src folder you just created.
Follow Firefox's guide to installing Firefox on Mac.
Browsh needs to be able to create new instances of Firefox. Add the Firefox app to your path. It's probably something like /Applications/Firefox.app/Contents/MacOS
.
To add this to your path, edit your path file by running sudo nano /etc/paths
. Add the path to Firefox in here and save the file.
Install Node. The currently recommended version of Node for working with Browsh is v8.11.4.
Navigate to browsh/webext. Run npm install
.
Run npm install -g web-ext
. This is Mozilla's handy tool for working with Firefox web extensions.
Navigate to the root of your Browsh project. This should be $GOROOT/src/browsh
. Run ./interfacer/contrib/build_browsh.sh
. This will install several required packages.
Now that you have all of the required dependencies installed, we can run Browsh. First, open 3 terminals.
This terminal will build the Javascript. From the browsh/webext
folder, run npx webpack --watch
. This will create a dist folder inside the webext folder.
This terminal will handle the Firefox web extension. From the browsh/webext/dist
folder, run web-ext run --verbose
.
This terminal will display Browsh. From the project root, run go run ./interfacer/src/main.go --firefox.use-existing --debug
.