{"id":18960661,"url":"https://github.com/maxiberta/kwin-system76-scheduler-integration","last_synced_at":"2025-04-19T10:49:45.547Z","repository":{"id":41235273,"uuid":"490897855","full_name":"maxiberta/kwin-system76-scheduler-integration","owner":"maxiberta","description":"Notify the System76 Scheduler which app has focus so it can be prioritized","archived":false,"fork":false,"pushed_at":"2024-04-25T15:40:39.000Z","size":26,"stargazers_count":45,"open_issues_count":0,"forks_count":5,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-04-16T04:44:53.517Z","etag":null,"topics":["kde","kde-desktop","kde-plasma","kde-plasma-desktop","kwin","kwin-script","linux","plasma-desktop","pop-os","system76","ubuntu"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/maxiberta.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2022-05-11T00:03:19.000Z","updated_at":"2025-04-15T19:19:53.000Z","dependencies_parsed_at":"2024-04-25T16:57:48.756Z","dependency_job_id":null,"html_url":"https://github.com/maxiberta/kwin-system76-scheduler-integration","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/maxiberta%2Fkwin-system76-scheduler-integration","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/maxiberta%2Fkwin-system76-scheduler-integration/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/maxiberta%2Fkwin-system76-scheduler-integration/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/maxiberta%2Fkwin-system76-scheduler-integration/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/maxiberta","download_url":"https://codeload.github.com/maxiberta/kwin-system76-scheduler-integration/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249677480,"owners_count":21309558,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["kde","kde-desktop","kde-plasma","kde-plasma-desktop","kwin","kwin-script","linux","plasma-desktop","pop-os","system76","ubuntu"],"created_at":"2024-11-08T14:08:49.012Z","updated_at":"2025-04-19T10:49:45.528Z","avatar_url":"https://github.com/maxiberta.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# KWin Script for system76-scheduler Integration\n\n[System76 Scheduler](https://github.com/pop-os/system76-scheduler) is a service which optimizes Linux's CPU scheduler and automatically assigns process priorities for improved desktop responsiveness.\n\nThis KWin Script interactively notifies [System76 Scheduler](https://github.com/pop-os/system76-scheduler) which app has focus via D-Bus, so it is prioritized.\n\n# Limitations\n\nThe `system76-scheduler` service is published on the _systemwide D-Bus bus_; but [KWin Scripts](https://develop.kde.org/docs/extend/plasma/kwin/api/#functions) can only call D-Bus methods on the _user session bus_ (as far as I can tell).\nThis can be worked around by forwarding these specific messages from the _session bus_ to the _system bus_. See the installation instructions below.\n\n# Installation\n\nThis KWin Script is [published at the KDE Store](https://store.kde.org/p/1789957) and can be downloaded and installed via \"Get New Scripts\" at the Window Management \u0026rarr; KWin Scripts settings.\n\n## Manual Installation\n\n```sh\ngit clone https://github.com/maxiberta/kwin-system76-scheduler-integration.git\ncd kwin-system76-scheduler-integration\nkpackagetool6 --type KWin/Script -i .\n```\n\nor if updating:\n\n```sh\nkpackagetool5 --type=KWin/Script -u .\n```\n\n## D-Bus Workaround (forward messages from session bus to the system bus)\n\nSave [this script](system76-scheduler-dbus-proxy.sh) as `~/.local/bin/system76-scheduler-dbus-proxy.sh` (or anywhere else), and make it executable:\n\n```sh\nchmod +x /usr/local/bin/system76-scheduler-dbus-proxy.sh\n```\n\nThis script can be run manually; or can be installed as a systemd user service so that it runs automatically on login.\nFor example, save the following service definition as `~/.config/systemd/user/com.system76.Scheduler.dbusproxy.service`:\n\n```systemd\n[Unit]\nDescription=Forward com.system76.Scheduler session DBus messages to the system bus\n\n[Service]\nExecStart=/usr/local/bin/system76-scheduler-dbus-proxy.sh\n\n[Install]\nWantedBy=default.target\n\n```\n\nAnd enable it:\n\n```sh\nsystemctl --user enable --now com.system76.Scheduler.dbusproxy.service\n```\n\n# Usage\n\n1. Install and configure [System76 Scheduler](https://github.com/pop-os/system76-scheduler).\n2. Install this KWin script.\n3. Activate the script at System Settings \u0026rarr; Window Management \u0026rarr; KWin Scripts (or run `kcmshell5 kwinscripts`).\n4. Run the dedicated D-Bus proxy as described above.\n5. Process priority (_niceness_) of focused apps should interactively update (e.g. check the `NICE` column in `System Activity`, `htop`, or any other process manager).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmaxiberta%2Fkwin-system76-scheduler-integration","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmaxiberta%2Fkwin-system76-scheduler-integration","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmaxiberta%2Fkwin-system76-scheduler-integration/lists"}