Google Tasks integration for the KDE Plasma desktop.
This repo builds a QML plugin and a Plasma widget that:
- Authenticates with Google (OAuth2)
- Fetches your tasks
- Lets you add and complete tasks from the widget
Below is a step-by-step guide to get it running on your machine, including Google Cloud setup and local build/run instructions.
You need:
- KDE Plasma (for the widget)
- Qt 6 + KDE Frameworks 6 development packages
- CMake + a C++ compiler
plasmoidviewer(for testing the widget)- A Google Cloud OAuth client ID/secret
On Arch Linux, the package set typically includes:
cmakeqt6-baseqt6-declarativeqt6-networkauthextra-cmake-moduleskf6-kirigamikf6-ki18nkf6-kwalletplasma-frameworkplasma-workspace(forplasmoidviewer)
If you are on another distro, install the equivalent Qt 6 / KF6 / Plasma developer packages.
You must create OAuth credentials for the Google Tasks API.
- Go to Google Cloud Console.
- Create a new project (or choose an existing one).
- Enable the Google Tasks API for the project.
- Configure the OAuth consent screen (External is fine for personal use).
- Create OAuth Client ID credentials:
- Application type: Desktop app
- Authorized redirect URI: http://localhost:8080/
- Copy the Client ID and Client Secret.
The app uses a local HTTP server on port 8080 for OAuth, so that redirect URI must match.
You can provide credentials via environment variables (recommended for dev), or via KWallet.
Create or edit .env in the project root:
QML2_IMPORT_PATH=$PWD/build/bin:$PWD/bin:/usr/lib/qt6/qml:$QML2_IMPORT_PATH
QML_IMPORT_PATH=$QML2_IMPORT_PATH
GOOGLE_TASKS_CLIENT_ID=your-client-id.apps.googleusercontent.com
GOOGLE_TASKS_CLIENT_SECRET=your-client-secretIf GOOGLE_TASKS_CLIENT_ID / GOOGLE_TASKS_CLIENT_SECRET are not set, the app will attempt to read them from KWallet under:
- Folder:
KDE Tasks - Keys:
clientId,clientSecret
If the values are found, they are reused and stored for future runs.
From the repository root:
cmake -S . -B build
cmake --build buildThis produces the QML plugin at:
build/bin/org/greenmarioh/kdetasks
The standalone window is useful for quick testing without Plasma.
source .env
/usr/lib/qt6/bin/qmlscene standalone.qmlIf qmlscene is not in that path on your system, use the Qt 6 version available in your PATH, or run:
which qmlscene
qmlscene -vMake sure you are running the Qt 6 version.
You can run the widget directly using plasmoidviewer:
source .env
plasmoidviewer -a packageIf you have an older system-installed plugin that conflicts, ensure QML2_IMPORT_PATH points to build/bin first as in the .env above.
- Click Sign In.
- A browser opens for OAuth.
- After success, the widget should fetch tasks automatically.
- Use Refresh if you want to force re-fetch.
This usually means the old plugin is being loaded. Ensure:
QML2_IMPORT_PATHincludesbuild/binfirst- You rebuilt after code changes
Check that the UI list is visible and that Loaded tasks: X at the bottom shows a nonzero count.
Make sure the redirect URI is http://localhost:8080/ and that port 8080 is not blocked.
Install Kirigami (Qt 6) and ensure /usr/lib/qt6/qml is in your QML import path.
Key files:
src/– C++ plugin (TasksController, NetworkManager, model)package/– Plasma widget packagestandalone.qml– Standalone window for testing
- The OAuth server listens on port 8080.
- The plugin is registered as
org.greenmarioh.kdetasks. - The Tasks API scope used:
https://www.googleapis.com/auth/tasks