The Barista Logo

barista

An i3status alternative in golang

Download sample-bar Download i3status example View on GitHub

Customising Barista

Building your own bar requires a few additional steps, because we cannot distribute API keys or client secrets in an open source project.

The simplest way to build a custom bar is to start with simple.go as a template, and experiment with changes to the file.

Screenshot of simple bar
Another screenshot of simple bar
go get barista.run
curl -L https://git.io/fxw62 -o mybar.go
curl -L https://git.io/fA7iZ -o build.sh
chmod +x build.sh
TARGET_FILE="mybar.go"
OWM_API_KEY="..."
GITHUB_CLIENT_ID="..."
GITHUB_CLIENT_SECRET="..."
./build.sh -o ~/bin/mybar -i mybar.go
i3-msg restart

The rest of the steps, for saving oauth tokens and setting up icon fonts, are the same as the quickstart.

Caching HTTP Requests for Development

When customising the bar, you may need to rebuild and restart the bar a lot, and each restart will issue HTTP requests to external services (weather, calendar, etc.). To avoid consuming excessive quota during development, it may be desirable to use the httpcache package.

See the package documentation for a simple example of setting up global HTTP caching for the binary. Remember to remove the caching once you’re satisfied with your barista setup.

OAuth and Client Keys

Quick links to the sign-up pages for the various available services: