Build and run locally
Build the app
Once you’re all set up, to build and run the app you will simply run:
Here are more detailed instructions.
Make a copy of
./electricbook-0.ymland configure the parameters as needed. You must set the Client ID and Client Secret of your own GitHub OAuth application:
github: client: "-clientID from github oauth application configuration-" secret: "-secret from github oauth application configuration-"
Do not commit this file to version control.
Get a personal access token from GitHub (Settings > Developer Settings > Personal access tokens. At “Select scopes”, you currently only need to select
Place the token and your GitHub username in
users: - token: - name:
npm installto install the rest of the dependencies.
Generate the production-ready CSS by running:
If you’re going to make changes to the SCSS in the
gulp watchto watch for changes.
If you’re going to make changes to the JS in the
srcdirectory, install DTemplate, then run
dtemplate -dir src/ts -lang ts -logtostderr -out src/ts/Templates.ts -watch
rollup -c --watch
to watch for changes.
To build, enter in the Terminal:
This will create two binaries in
electricbook, which is the EBM web app, and
ebw, which is a CLI app.
Start the app with:
(This make command simply does
bin/electricbook -logtostderr web.)
This must be run from the repo directory, since it needs access to the
publicdirectory, to some other directories it will create on the fly, and to the
You can then open the EBM in your browser at http://localhost:16101/.
For convenience, run
make dev to start the app and watch the Sass, Typescript and dTemplates all at once. Note that this runs the processes in parallel, and you may need to kill processes manually when you’re done.