d05b9f8a0e
Replace the workspace-based minimize (declared 'minimized' workspace + +1 offset + window-restore.py) with a native Sway-style scratchpad built into niri. Ships as niri-patches/0001-scratchpad.patch + a niri-scratchpad PKGBUILD. Mod+M stashes; Mod+Shift+M shows/toggles/cycles. Mod+1..9 no longer offset. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
49 lines
1.6 KiB
Bash
49 lines
1.6 KiB
Bash
# Maintainer: alex <funman300@gmail.com>
|
|
pkgname=niri-scratchpad
|
|
pkgver=26.04
|
|
pkgrel=1
|
|
_commit=8ed0da4
|
|
pkgdesc="niri with a native Sway-style scratchpad (local patch set)"
|
|
arch=('x86_64')
|
|
url="https://github.com/YaLTeR/niri"
|
|
license=('GPL-3.0-or-later')
|
|
depends=('cairo' 'glib2' 'glibc' 'libdisplay-info' 'libgcc' 'libinput'
|
|
'libpipewire' 'libxkbcommon' 'mesa' 'pango' 'pixman' 'seatd'
|
|
'systemd-libs' 'xdg-desktop-portal-impl')
|
|
makedepends=('git' 'cargo' 'clang' 'mesa')
|
|
provides=('niri')
|
|
conflicts=('niri')
|
|
options=('!lto')
|
|
source=("niri::git+https://github.com/YaLTeR/niri.git#commit=${_commit}"
|
|
"0001-scratchpad.patch")
|
|
sha256sums=('SKIP'
|
|
'SKIP')
|
|
|
|
prepare() {
|
|
cd niri
|
|
git apply "${srcdir}/0001-scratchpad.patch"
|
|
export RUSTUP_TOOLCHAIN=stable
|
|
cargo fetch --locked --target "$(rustc -vV | sed -n 's/host: //p')"
|
|
}
|
|
|
|
build() {
|
|
cd niri
|
|
export RUSTUP_TOOLCHAIN=stable
|
|
export CARGO_TARGET_DIR=target
|
|
cargo build --release --frozen
|
|
}
|
|
|
|
package() {
|
|
cd niri
|
|
install -Dm755 target/release/niri "${pkgdir}/usr/bin/niri"
|
|
install -Dm755 resources/niri-session "${pkgdir}/usr/bin/niri-session"
|
|
install -Dm644 resources/niri.desktop \
|
|
"${pkgdir}/usr/share/wayland-sessions/niri.desktop"
|
|
install -Dm644 resources/niri-portals.conf \
|
|
"${pkgdir}/usr/share/xdg-desktop-portal/niri-portals.conf"
|
|
install -Dm644 resources/niri.service \
|
|
"${pkgdir}/usr/lib/systemd/user/niri.service"
|
|
install -Dm644 resources/niri-shutdown.target \
|
|
"${pkgdir}/usr/lib/systemd/user/niri-shutdown.target"
|
|
}
|