Bug 2437604

Summary: Review Request: kmonad - Advanced keyboard remapping utility
Product: [Fedora] Fedora Reporter: solomoncyj
Component: Package ReviewAssignee: Jens Petersen <petersen>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: haskell-devel, package-review
Target Milestone: ---Flags: petersen: fedora-review+
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
URL: https://hackage.haskell.org/package/kmonad
Whiteboard:
Fixed In Version: Doc Type: ---
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2026-02-19 01:32:47 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description solomoncyj 2026-02-08 12:01:07 UTC
Spec URL: https://solomoncyj.fedorapeople.org/reviews/ghc-kmonad/ghc-kmonad.spec
SRPM URL: https://solomoncyj.fedorapeople.org/reviews/ghc-kmonad/ghc-kmonad-0.4.4-1.fc43.src.rpm

Description:
KMonad is a cross-platform command-line utility that runs as a daemon.
It captures keyboard input (exactly how depends on the OS) and remaps it.
The mapping is highly configurable, and provides options like (transparent)
layer overlays, tap-mod buttons, multi-tap buttons, leader-key style buttons,
and keyboard macros. Functionality heavily inspired by the QMK-firmware.

Fedora Account System Username: solomoncyj

Comment 1 solomoncyj 2026-02-08 12:09:39 UTC
Spec URL: https://solomoncyj.fedorapeople.org/reviews/kmonad/kmonad.spec
SRPM URL: https://solomoncyj.fedorapeople.org/reviews/kmonad/kmonad-0.4.4-1.fc43.src.rpm

- spec file generated by cabal-rpm-2.3.0

Comment 2 Fedora Review Service 2026-02-08 18:51:20 UTC
Copr build:
https://copr.fedorainfracloud.org/coprs/build/10104593
(succeeded)

Review template:
https://download.copr.fedorainfracloud.org/results/@fedora-review/fedora-review-2437604-ghc-kmonad/fedora-rawhide-x86_64/10104593-ghc-kmonad/fedora-review/review.txt

Found issues:

- No gcc, gcc-c++ or clang found in BuildRequires
  Read more: https://docs.fedoraproject.org/en-US/packaging-guidelines/C_and_C++/

Please know that there can be false-positives.

---
This comment was created by the fedora-review-service
https://github.com/FrostyX/fedora-review-service

If you want to trigger a new Copr build, add a comment containing new
Spec and SRPM URLs or [fedora-review-service-build] string.

Comment 3 Fedora Review Service 2026-02-08 18:56:04 UTC
Copr build:
https://copr.fedorainfracloud.org/coprs/build/10104594
(succeeded)

Review template:
https://download.copr.fedorainfracloud.org/results/@fedora-review/fedora-review-2437604-kmonad/fedora-rawhide-x86_64/10104594-kmonad/fedora-review/review.txt

Found issues:

- No gcc, gcc-c++ or clang found in BuildRequires
  Read more: https://docs.fedoraproject.org/en-US/packaging-guidelines/C_and_C++/
- Package has .a files: ghc-kmonad-devel, ghc-kmonad-prof. Illegal package name: ghc-kmonad-prof. Does not provide -static: ghc-kmonad-prof.
  Read more: https://docs.fedoraproject.org/en-US/packaging-guidelines/#packaging-static-libraries

Please know that there can be false-positives.

---
This comment was created by the fedora-review-service
https://github.com/FrostyX/fedora-review-service

If you want to trigger a new Copr build, add a comment containing new
Spec and SRPM URLs or [fedora-review-service-build] string.

Comment 4 Jens Petersen 2026-02-09 07:01:58 UTC
Overall this looks good.

(Btw I am going to add -prof-static provides to cabal-rpm in the following release.)

I checked the upstream git submodules but they are only for macos, so I think they can be ignored here.

I think the unit tests could be enabled: cabal-rpm can do that - you might need to install ghc-hspec-devel.

Also the systemd unit should live under %{_unitdir} (not /etc/).
(Arguably it might be more consistent to take the systemd file from the release tag, though it hasn't changed since.)
(It wouldn't hurt if upstream included the file in the tarball, though I don't think it's a blocker.)

Further the systemd unit should live in the main kmonad package (it doesn't pull in ghc-kmonad).

You can add `doc/quick-reference.md` to the kmonad %doc's I think, maybe also `keymap/tutorial.kbd`.

Comment 5 Jens Petersen 2026-02-09 07:25:37 UTC
Koji scratch build: https://koji.fedoraproject.org/koji/taskinfo?taskID=142110958

Comment 6 Jens Petersen 2026-02-09 07:59:20 UTC
Actually wondering if the systemd unit should be a user unit rather than system?

Comment 7 solomoncyj 2026-02-09 08:00:52 UTC
System, it needs to reed device files

Comment 8 solomoncyj 2026-02-10 04:54:41 UTC
Spec URL: https://solomoncyj.fedorapeople.org/reviews/kmonad/kmonad.spec
SRPM URL: https://solomoncyj.fedorapeople.org/reviews/kmonad/kmonad-0.4.4-1.fc43.src.rpm

- spec file generated by cabal-rpm-2.3.0

Comment 9 Jens Petersen 2026-02-10 10:03:05 UTC
I think you broke the build with:

-mkdir -p %{buildroot}/etc/systemd/system/
-cp %{S:1} %{buildroot}/etc/systemd/system/
+cp %{S:1} %{buildroot}/%{_unitdir}

The directory still needs to be created: if you don't want to create it separately
you could use say

    install -Dp -m 0644 -t %{buildroot}/%{_unitdir} %{S:1}


Otherwise the package looks fine to me:

- MIT license (most of the src files are tagged)
- complies with Haskell Packaging guides
- cabal-rpm spec file with small tweaks

I tested it lightly in a VM with the following "test.kbd" config file:

```
(defcfg
  input  (device-file "/dev/input/event1")
  output (uinput-sink "KMonad-Test-Device")
  fallthrough true
  allow-cmd false
)

(defsrc
  caps
)

(deflayer default
  esc
)
```

using both `sudo kmonad test.kbd` and `systemctl start kmonad@test` (for `/etc/kmonad/test.kbd`)

Package is APPROVED

Please fix the above minor build issue when importing :)

Comment 10 Fedora Admin user for bugzilla script actions 2026-02-10 12:18:15 UTC
The Pagure repository was created at https://src.fedoraproject.org/rpms/kmonad

Comment 12 Fedora Update System 2026-02-10 14:57:07 UTC
FEDORA-2026-89de5f9d29 (kmonad-0.4.4-1.fc42) has been submitted as an update to Fedora 42.
https://bodhi.fedoraproject.org/updates/FEDORA-2026-89de5f9d29

Comment 13 Fedora Update System 2026-02-11 05:38:00 UTC
FEDORA-2026-89de5f9d29 has been pushed to the Fedora 42 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf install --enablerepo=updates-testing --refresh --advisory=FEDORA-2026-89de5f9d29 \*`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2026-89de5f9d29

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 14 Fedora Update System 2026-02-19 01:32:47 UTC
FEDORA-2026-89de5f9d29 (kmonad-0.4.4-1.fc42) has been pushed to the Fedora 42 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 15 Fedora Update System 2026-02-23 09:58:06 UTC
FEDORA-2026-b2c9a05665 (kmonad-0.4.4-1.fc44) has been submitted as an update to Fedora 44.
https://bodhi.fedoraproject.org/updates/FEDORA-2026-b2c9a05665

Comment 16 Fedora Update System 2026-02-23 09:58:40 UTC
FEDORA-2026-7cf9b2ff84 (kmonad-0.4.4-1.fc43) has been submitted as an update to Fedora 43.
https://bodhi.fedoraproject.org/updates/FEDORA-2026-7cf9b2ff84

Comment 17 Fedora Update System 2026-02-24 01:14:58 UTC
FEDORA-2026-b2c9a05665 has been pushed to the Fedora 44 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf install --enablerepo=updates-testing --refresh --advisory=FEDORA-2026-b2c9a05665 \*`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2026-b2c9a05665

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 18 Fedora Update System 2026-02-24 01:30:02 UTC
FEDORA-2026-7cf9b2ff84 has been pushed to the Fedora 43 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf install --enablerepo=updates-testing --refresh --advisory=FEDORA-2026-7cf9b2ff84 \*`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2026-7cf9b2ff84

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 19 Fedora Update System 2026-03-04 00:56:06 UTC
FEDORA-2026-7cf9b2ff84 (kmonad-0.4.4-1.fc43) has been pushed to the Fedora 43 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 20 Fedora Update System 2026-03-07 00:24:58 UTC
FEDORA-2026-b2c9a05665 (kmonad-0.4.4-1.fc44) has been pushed to the Fedora 44 stable repository.
If problem still persists, please make note of it in this bug report.