Skip to content

Installation

GGEZUS edited this page Sep 23, 2026 · 8 revisions

The patchset applies on top of a stock niri release, so installing means building niri with the patches. The release tags are named v<niri-version>.<patch-count> (current: v26.04.20, niri v26.04 plus 20 patches).

Arch Linux

Easiest, with the bundled updater (it handles first installs too):

git clone https://github.com/GGEZUS/niri-tablet.git
cd niri-tablet
./update-niri-tablet.sh

It fetches the latest release, builds it (the sudo prompt for the install comes from makepkg), pins IgnorePkg = niri in /etc/pacman.conf if that pin is missing, and sets up the EasySetup GUI: build, launcher entry and icon (no sudo). Manual equivalent:

cd niri-tablet/pkg
makepkg -si        # builds upstream niri + patches; replaces stock niri

pacman will ask to remove stock niri:

Remove niri? [y/N]

The default is N; answer y. With N the install simply aborts. The package niri-tablet provides and conflicts with niri, so the swap itself is automatic.

Then protect it from repo updates in /etc/pacman.conf (the updater does this for you):

IgnorePkg = niri

Build requirements: rust, cargo, clang and git. The first build takes a while; the PKGBUILD shares a cargo target dir (~/.cache/niri-tablet-target) so rebuilds are incremental.

Verify the install

After a re-login, niri --version prints 26.04 (v26.04-modified): the patchset applies uncommitted on top of the release tag, so git-describe reports that rather than the pkgver's 26.04.20….

The positive check that the patched binary is running:

niri validate

with a gestures {} block in your config. The patched niri accepts it; stock niri rejects the unknown node. If validate rejects it, your session is still running the stock binary: re-login, and check that only one niri is on PATH (which -a niri).

NixOS

From the README, credit lamarios (PR #1):

let
  niri-tablet-repo = pkgs.fetchFromGitHub {
    owner = "GGEZUS";
    repo = "niri-tablet";
    rev = "v26.04.20";
    hash = ""; # Leave empty on first run; Nix will fail and provide the correct hash
  };

  niri-tablet = pkgs.niri.overrideAttrs (previousAttrs: {
      postPatch = (previousAttrs.postPatch or "") + ''
        echo "Applying GGEZUS niri-tablet patches..."
        # Shell globbing automatically applies 0001, 0002, etc. in numerical order
        for patch_file in ${niri-tablet-repo}/pkg/*.patch; do
          echo "Applying $patch_file"
          patch -Np1 < "$patch_file"
        done
      '';
    });
in
{
 programs.niri.package = niri-tablet;
}

To update, bump rev to the newest release tag; the hash changes with it (leave it empty once and Nix prints the right one).

Other distros

The patchset is plain git/patch + cargo, nothing Arch-specific in it:

git clone https://github.com/niri-wm/niri
cd niri
git checkout v26.04        # the release named by _tag in pkg/PKGBUILD
for p in /path/to/niri-tablet/pkg/*.patch; do patch -Np1 < "$p"; done
cargo build --release      # binary lands in target/release/niri

You need rust, cargo and clang plus the system libraries niri links against. The PKGBUILD's depends list doubles as the checklist:

cairo glib2 glibc libdisplay-info libgcc libinput libpipewire libxkbcommon
mesa pango pixman seatd systemd-libs xdg-desktop-portal-impl

cargo test touch_ runs the patchset's unit tests.

The helpers in scripts/ and the config fragment in config/ are distro-agnostic (POSIX sh + python3). For the on-screen keyboard, build wvkbd from source instead of using the AUR package; see OSK and auto-rotation.

After installing

  1. Copy the gesture config: Configuration. Or skip the KDL entirely and pick actions in the GUI: EasySetup.
  2. Optional: the OSK and auto-rotate helpers, which also work on stock niri: OSK and auto-rotation.
  3. Re-login, then run the verify steps above.

Clone this wiki locally