Thanks for considering contributing! Whether you're fixing bugs, translating, or adding features, your help is incredibly valuable.
If you found a bug, please check the Troubleshooting section first.
When opening an issue on GitHub, please include:
- GNOME Shell version
- Extension version
- Focus Timer version
- GNOME Shell logs relevant to the issue
- Steps to reproduce the bug
Suggestions are welcomed too!
Ensure that the Focus Timer app is running.
Then, please check the Extensions app:
- Check if extensions are enabled globally
- Check if Focus Timer extension is enabled and there are no errors
If you updated the extension, the new version will only be fully loaded after you log out and log back in.
The extension uses the GNOME Shell log.
View logs since boot:
journalctl /usr/bin/gnome-shell -bView logs in real time:
journalctl /usr/bin/gnome-shell -fWe use Gettext for translations. The .pot template and language .po files are located in the po/ directory. The app and the extension have separate translations.
If you'd like to add or update a language:
- Generate/Update the
.pofile for your language usingmsginitor by editing an existing one in the po/ directory. - Ensure your language is in LINGUAS file
- Submit your changes via a Pull Request.
LLM prompt to ease the process:
Fill-in missing translations and update fuzzy translations for the given file. Translations are for an desktop Pomodoro timer app. Take care to use consistent same translations for words: "break", "pause", "start", "stop", "rewind", "interruption". "pause" refers to the timer action, while "break" refers to taking a break from work, "interruption" refers to a distraction. Translations does not need to be exact, but must convey same meaning - make them sound natural. Mark modified entries as fuzzy. Output the updated .po file for download, do not truncate it.
We keep .po files in sync with the .pot file. Generally, there's no need to sync it manually.
If you're touching code, to test changes it's best to run gnome-shell container:
dbus-run-session -- gnome-shell --devkit --waylandThis way you don't need to log out to test changes.
But, that's not all. Inside the container, run:
gnome-extensions enable focus-timer@focustimerhq.github.io
flatpak run io.github.focustimerhq.FocusTimer
The Focus Timer app inside the container is isolated from your user session to some extent — the data is shared. You'll need to run it each time.
For making larger changes, we strongly suggest using GNOME Builder.
GNOME Builder will allow you to automate the installation and running process:
-
Create a Command
Shell Command:
dbus-run-session -- gnome-shell --devkit --waylandAdd env:
SHELL_DEBUG=backtrace-warningsto show traceback on warnings. -
In Application settings
Change Run Command to the newly created.
Ensure Install Before Running is on.
-
In Default configuration
Ensure that Installation Prefix is:
~/.localEnsure that Configure Options is:
--prefix=~/.localYou may need to select the Runtime to: gnome-shell-devel
Instead of running the project like an app, you run gnome-shell.
Clone gnome-shell repo and setup toolbox:
git clone https://gitlab.gnome.org/GNOME/gnome-shell.git contrib/gnome-shell
cd contrib/gnome-shell
./tools/toolbox/create-toolbox.sh
./tools/toolbox/run-gnome-shell.shWe follow the standard GNOME styling rules. Please ensure your code adheres to:
Linting: The repository includes an ESLint configuration. You can check your code by running:
./run-es-lint.sh src/
If it's the first run, set it up:
cd tools
npm installThe extension uses the D-Bus service of the main Focus Timer app, and the extension is running its own service. The communication goes both ways. Helpful commands for debugging the connection:
dbus-monitor --session --monitor "sender='io.github.focustimerhq.FocusTimer'"
dbus-monitor --session --monitor "sender='io.github.focustimerhq.FocusTimer.ShellIntegration'"Documentation for the app services: