output.mp4
I like Niri and wanted to extend its functinality for my needs.
- Sticky Floating: Moves any floating window to the focused workspace.
- Wallpaper Per Workspace: Assign a wallpaper for each individual workspace.
- Screenshot: Take screenshot then annotate it.
- Scriptisto: Required to run the script. GitHub
- Wallpaper Per Workspace:
- Screenshot:
- grim
- satty
- slurp
- wl-clipboard (only used when you don't use --annotate)
-
Clone the repo:
git clone https://github.com/0xwal/niri-scripts.git -
Make the scripts executable:
chmod +x niri-scripts/support-sticky-floatingchmod +x niri-scripts/toggle-stickychmod +x niri-scripts/wallpaper-per-workspacechmod +x niri-scripts/screenshot
niri-scripts/support-sticky-floating &
niri-scripts/wallpaper-per-workspace <WALLPAPER_DIR> &
disown
OR within your config:
spawn-sh-at-startup "niri-scripts/support-sticky-floating"
binds {
// To take a screenshot, use whatever keybind you want
Super+S { spawn-sh "niri-scripts/screeenshot <PATH_TO_SAVE_SCREENSHOT>"; }
// To take a screenshot then annotate it, use whatever keybind you want
Super+Ctrl+S { spawn-sh "niri-scripts/screeenshot <PATH_TO_SAVE_SCREENSHOT> --annotate"; }
// To make the focused window sticky, use whatever keybind you want
Super+Shift+S { spawn-sh "niri-scripts/toggle-sticky"; }
}
WALLPAPER_DIR: This directory contains each wallpaper named by the workspace index. For example:WALLPAPER_DIR/1will be active when workspace 1 is focused.WALLPAPER_DIR/2will be active when workspace 2 is focused, and so on.WALLPAPER_DIR/FALLBACKwill be used when activating a workspace with no wallpaper file.
PATH_TO_SAVE_SCREENSHOT: The path of the directory to save your screenshots.