HackerTray is a cross-platform Hacker News application that lets you view top HN stories in your System Tray. On Linux it uses appindicator where available (with a Gtk StatusIcon fallback). On macOS it uses a native status bar menu via pyobjc.
The inspiration for this came from Hacker Bar (now dead), which was Mac-only.
Over the years, this has been tested across multiple system tray implementations, including:
- Waybar on sway
- i3bar with i3
- ElementaryOS
- KDE Plasma 6.6
- GNOME 50
The new flatpak installation is in need of more testing.
HackerTray is distributed as a python package. Do the following to install:
pipx install hackertray --system-site-packagesThere is a Flatpak build and submission in progress.
The latest stable version is 5.0.0.
You can check which version you have installed with hackertray --version.
HackerTray will automatically check the latest version on startup, and inform you if there is an update available on the command line.
HackerTray accepts its various options via the command line. Run hackertray -h to see all options. Currently the following switches are supported:
-c: Enables comments support. Clicking on links will also open the comments page on HN. Can be switched off via the UI, but the setting is not remembered.--reverse(or-r): Switches the order for the elements in the menu, so Quit is at top. Use this if your system bar is at the bottom of the screen.--verbose: Enable debug logging.
Browser history is automatically discovered from all installed browsers (Chrome, Firefox, Safari, Brave, Edge, Arc, and many more). All profiles are searched.
Options can also be set in ~/.config/hackertray/hackertray.ini (or ~/.config/hackertray.ini):
- Minimalist Approach to HN
- Opens links in your default browser
- Shows Points/Comment count in a simple format
- Reads your browser history to mark which links you've already visited
If the app indicator fails to show in Ubuntu versions, consider installing python-appindicator with
sudo apt-get install python-appindicator
Note that appindicator is no longer supported in non-Ubuntu distros, because it only works on Python2.
To develop on hackertray, or to test out experimental versions, do the following:
- Clone the project
- Run
uv venv --system-site-packages. This is required to allow access to the global pygobject install. - Run
uv run hackertraywith the required command line options
On every launch, a request is made to https://pypi.python.org/pypi/hackertray/json to check the latest version.
No more tracking. All data every collected for this project has been deleted. You can see the wiki for what all was collected earlier (Version < 4.0.0).
- Mark Rickert for Hacker Bar (No longer active, MIT License). The macOS port references Hacker Bar's original design.
- browser-history (Apache 2.0) — browser history discovery patterns were informed by this project.
- Giridaran Manivannan for troubleshooting instructions.
- @cheeaun for the Unofficial Hacker News API
Licenced under the MIT Licence. See the LICENSE file for complete license text.
