Andreas Krennmair [email protected]
Gockel is a Twitter client for text terminals, written in the Go programming language. Currently, gockel is at a very early stage of development. Its predecessor is baconbird: http://synflood.at/baconbird.html
In order to build gockel, you first need to install libstfl. Then you can simply run
go get github.com/akrennmair/gockel
and after some time, you should have a binary named
Simply run the gockel binary. When starting for the first time, you will be asked to open a URL, where you need to confirm that gockel is authorized to read your tweets and post updates. You will then be shown a PIN code that you need to enter into gockel. After that, gockel starts up as usual, and downloads the latest updates in your home timeline. On subsequent starts, you will not be asked for a PIN code again.
Currently, the following keystrokes are available:
If you want to tweak gockel, you need to create a configuration file under the path ~/.gockel/gockelrc in an INI-style format. The examples directory contains several examples upon which you can build. General options are in the default section (i.e. those options with no section marker), the user interface color are in the "colors" section, and special highlighting configuration can be found in sections starting with "highlight" (see below).
Currently, the following configuration options are available:
The color configuration is put into a configuration section named "colors".
The color configuration string is a comma-separated list of key=value pairs.
Every configuration string can contain at most one "fg" key (to define the foreground color), at most one "bg" key (to define the background color), and optionally one or more "attr" keys (to define extended attributes).
The following color names are available:
The following attributes are available:
Please note that not all attributes may be supported by your terminal emulator.
The following user interface elements can be configured color-wise:
[colors] shorthelp = fg=white,bg=red infotext = bg=white,fg=red listfocus = fg=white,bg=green,attr=bold listnormal = fg=yellow
In addition it is also possible to configure pairs of regular expressions and color configuration strings to highlight certain text in the tweet list. For each highlighting, you need to configure an own configuration section whose name starts with "highlight" and which must be unique. Such a section needs to contain two configuration options, "attributes", which contains a color configuration string (see above), and "regex", which contains the regular expression that describes what shall be highlighted. If you regular expression starts with a special character such as '#' (comment in INI-style configuration files), you can mark start and end of regular expression with forward slashes.
[highlight_urls] attributes = fg=green regex = (mailto|ftp|https?):[^ )\]]*
If you need to manage multiple accounts, gockel provides basic support for that. When you start gockel for the first time, you need to authenticate your user. To add more accounts, run "gockel -add" and you will be provided with the same workflow to authorize the application. Gockel will save this information in ~/.gockel as files starting with "access_token.json", and usually the associated Twitter username as suffix.
In the application, you can then select the currently active user by pressing the keys 1 to 9. Which user is currently active is displayed in the user list line at the top of the application. When you start gockel, the first user that was found is active, but you can influence this by configuring
default_user = your_preferred_nick
in your ~/.gockel/gockelrc.
Andreas Krennmair [email protected]
Gockel is licensed under the MIT/X Consortium License. See the file LICENSE for further details.