Commit Graph

31 Commits

Author SHA1 Message Date
funman300 05cc026d75 fix(window-restore): re-read workspace/window state after the wofi pick
The picker blocks on user input for however long they take. In that
window niri can destroy a dynamic workspace (its last window closed)
and renumber every later one down, so the pre-pick current["idx"] can
point at the wrong workspace by the time move-window-to-workspace
runs — restoring to the wrong place. The stashed window itself can
also have closed in the meantime, in which case the move/focus calls
would silently no-op. main() now re-reads workspaces/windows after
pick() returns, recomputes the current workspace, and confirms the
chosen window still exists before acting; each bails with a notify
and the documented exit code otherwise. Adds window_exists() as a
pure, tested helper alongside the existing pure functions.

Also: clarify the focus=false comment in niri/config.kdl (it read as
if focus=false caused the problem it actually prevents), and note in
the design doc's Out of scope section that the stash's index-1
pinning is per-output, so a second monitor would need its own
analysis of the Mod+1..9 offset.
2026-07-16 10:10:40 -07:00
funman300 5979eb229f window-restore: wofi picker to restore minimized windows
Pure logic split from the niri/wofi calls so it unit-tests without a
compositor. Restores to the current workspace, so no origin tracking.
2026-07-16 09:58:25 -07:00
funman300 2e168053c6 volume: keep the OSD visible in gamemode and fullscreen
Two effects were hiding the volume slider:

- gamemode-session turns on mako's do-not-disturb mode, whose invisible=1
  suppressed every notification, the OSD included.
- niri draws fullscreen windows above the top layer, mako's default, so the
  OSD rendered underneath fullscreen windows even outside gamemode.

Tag the OSD with its own app name so mako can match it, then exempt just that
name: invisible=0 to survive DND, layer=overlay to clear fullscreen. The block
is listed after [mode=do-not-disturb] because later criteria win in mako.

Verified with DND active and a fullscreen window: the OSD shows, while another
app's notification under the same conditions stays suppressed.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-16 08:48:41 -07:00
funman300 3d08abb060 gamemode-watch: single-instance flock guard
Prevents a manually-launched watcher and the spawn-at-startup one from
racing the same winwatch source; the second instance exits immediately.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-15 21:54:17 -07:00
funman300 0ab08e8561 gamemode: global auto-trigger via niri window watch
Add scripts/gamemode-watch.py, launched at niri startup, which subscribes
to niri's event stream and toggles gamemode whenever a game window
(steam_app_*, RuneLite, gamescope) is open — so Steam games trigger
gamemode with zero per-game setup instead of needing gamemoderun %command%.

'winwatch' is a third reference-counted source alongside feral + manual.
Pure Watcher class is unit-tested; SIGTERM/finally guarantee cleanup so
the watcher stopping never leaves gamemode stuck on.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-15 21:51:52 -07:00
funman300 2c9cff6bb9 gamemode-session: discard effect-command stdout
makoctl/fw-fanctrl echo confirmations to stdout that leaked into add/del
output during integration. run() now discards stdout, keeps stderr.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-15 21:37:40 -07:00
funman300 4b1773ac4e gamemode-session: real effects (idle, DND, perf+fan, waybar)
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-15 21:32:32 -07:00
funman300 05707afc04 gamemode-session: reference-counted state machine core
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-15 21:31:52 -07:00
funman300 5305bb78c6 scripts: also wire fingerprint into greetd login
Adds /etc/pam.d/greetd to the TARGETS array so re-running
enable-fingerprint.sh extends fprintd auth to the regreet login
screen. Cold-boot timing and silent-touch UX caveats documented
in the spec are accepted as-is — fingerprint failure falls back to
password, no risk of lockout.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-25 11:45:05 -07:00
funman300 2fcfc62cdd scripts: enable-fingerprint targets hyprlock PAM file
Replace /etc/pam.d/gtklock with /etc/pam.d/hyprlock in the TARGETS
array now that hyprlock is the session locker. Update the header
comment to match.
2026-05-25 11:17:10 -07:00
funman300 b34d4269af scripts: add enable-fingerprint.sh (one-time PAM bootstrap)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-25 10:33:00 -07:00
funman300 45ce4594aa volume: add notification wrapper script
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 11:18:22 -07:00
funman300 0de20dcd12 power-profile: signal fan widget on profile change
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-10 17:55:54 -07:00
funman300 096ac3f76a powermenu: route Sleep through suspend-then-hibernate
Aligns the third sleep path (power menu) with the lid handler and
the swayidle 30-min timer — all three now suspend immediately and
hibernate after HibernateDelaySec (30 min).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-10 17:30:32 -07:00
funman300 126b03ad26 scripts: guard enable-hibernation against empty root PARTUUID
If `findmnt -no PARTUUID /` returns nothing (root on LVM, no GPT,
unusual mount state) the script would silently write a broken
resume=PARTUUID= line to /etc/kernel/cmdline. Bail with an error
message instead.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-10 17:18:25 -07:00
funman300 86cfcb0da5 scripts: add enable-hibernation.sh (one-time bootstrap)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-10 17:08:28 -07:00
funman300 85ef13492e screenshot: revert flameshot, use grim+slurp+satty pipeline
Flameshot's portal-based capture path on niri triggers an
xdg-desktop-portal access prompt on every invocation, blocking
the screenshot itself. grim talks to wlr-screencopy directly and
never touches the portal, so no prompt.

Pipeline: slurp (region) → grim (capture) → satty (annotate +
copy + save). satty replaces the wofi action menu by being the
post-capture surface itself.

- scripts/screenshot.sh added
- install.sh symlinks it; flameshot.ini generator removed
- niri Mod+Print → "screenshot"
- packages.txt drops flameshot
- docs tables updated

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-06 10:27:16 -07:00
funman300 d9f4538ea7 screenshot: remove old grim/slurp/wofi pipeline (replaced by flameshot)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-05 23:11:20 -07:00
funman300 370b4aa096 fan-profile: drop redundant 2>/dev/null on mapping function call
map_profile_to_strategy never writes to stderr — the suppression was
silencing nothing real and would mislead a future reader.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-01 11:33:50 -07:00
funman300 9ff1190549 fan-profile: render auto mode and reconcile fw-fanctrl on poll
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-01 11:29:56 -07:00
funman300 cc164dfa50 fan-profile: route 'auto' menu choice through state file
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-01 11:24:58 -07:00
funman300 b04357de87 fan-profile: add state path and profile→strategy mapping (unused yet)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-01 11:05:14 -07:00
funman300 6372695b16 remove orphan files: autostart.sh and tracked mako/config
scripts/autostart.sh was never symlinked or referenced — niri's
spawn-at-startup directives cover everything it launched.

mako/config is gitignored (install.sh generates it from
theme/colors.json) but was still tracked from the initial commit.
The stale ~/.config/mako/config symlink that pointed at the repo
caused install.sh's writes to land back in the repo. Removed both
so install.sh now correctly produces a real generated file in
~/.config/mako/.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-01 09:53:46 -07:00
funman300 2c851c7561 add waybar-restart script and Mod+Shift+B keybind
scripts/waybar-restart.sh: kills waybar, waits for it to exit, then
relaunches detached via setsid. Symlinked into ~/.local/bin and bound
to Mod+Shift+B in niri.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-30 21:59:33 -07:00
funman300 d923cfb5cf screenshot: fix action separator and add Pictures dir guard 2026-04-28 11:28:50 -07:00
funman300 b2c2f2d394 screenshot: add post-capture notification and wofi action picker 2026-04-28 11:26:56 -07:00
funman300 54689f9781 Add power profile and fan strategy waybar modules - scripts/power-profile.sh: waybar module + wofi menu for powerprofilesctl - scripts/fan-profile.sh: waybar module + wofi menu for fw-fanctrl - waybar/config.jsonc: add custom/power-profile and custom/fan-profile modules - waybar/style.css: add padding and class colors for new modules - packages.txt: add power-profiles-daemon and fw-fanctrl - install.sh: symlink new scripts to ~/.local/bin 2026-04-22 17:27:29 -07:00
funman300 0cd43b9e54 Switch greeter from tuigreet to regreet
- Replace greetd-tuigreet with greetd-regreet + cage in packages.txt
- Add greetd/config.toml and greetd/regreet.toml (Materia-dark theme)
- Update install.sh to deploy greetd configs to /etc/greetd/
- Fix powermenu.sh awk parsing (use $NF instead of $2 for icon glyphs)
2026-04-22 17:15:17 -07:00
funman300 c6f96bcac8 Add clipboard, idle timeouts, night light, bluetooth, and waybar improvements
- Add cliphist clipboard manager with wofi picker (Mod+Shift+C)
- Add wl-paste watch for clipboard history
- Add swayidle idle timeouts: blank at 5min, lock at 10min
- Add blueman-applet autostart (bluetooth tray)
- Add wlsunset night light for Vancouver (49.2N, 123.1W)
- Add clipboard-picker script and symlink in install.sh
- Waybar: add battery charging format, warning/critical states, tray config
- Waybar CSS: add warning (yellow) and critical (red) battery colors
2026-04-22 16:14:30 -07:00
funman300 44e1dc2eee Add powermenu script and apply Tomorrow Night color theme
- Add scripts/powermenu.sh with logout, restart, sleep, shutdown options
- Create wofi/style.css with Tomorrow Night colors
- Apply Tomorrow Night theme to niri, waybar, mako, alacritty, and wofi
2026-04-22 12:48:03 -07:00
funman300 2c9d9c7c32 Initial Niri + Wayland dotfiles 2026-04-22 11:40:31 -07:00