A native, blazing-fast 🚀🚀🚀 screenshot tool for wlroots based compositors such as sway and river written in Rust.
xdg-desktop-portal-luminous is a xdg-desktop-portal backend for wlroots based compositors, providing screenshot and screencast capabilities.
NOTE: Read man 7 wayshot for more examples.
NOTE: Read man 5 wayshot for config file information.
NOTE: Read man wayshot for flag information.
Screenshot and crop region:
wayshot -gFullscreen:
wayshotScreenshot and copy to clipboard:
wayshot --clipboardPick color with information:
wayshot --colorCapture a specific output:
wayshot --list-outputs # see available output names
wayshot -o eDP-1Interactively choose a window to capture:
wayshot --choose-toplevelPick a hex color code, using ImageMagick:
wayshot -g - | convert - -format '%[pixel:p{0,0}]' txt:-|grep -E "#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})" -oAll features are enabled in the default build. To reduce binary size or compile-time dependencies, features can be selectively disabled:
cargo build --no-default-features --features clipboard,logger,notifications| Feature | What it adds | Extra dependency |
|---|---|---|
avif |
AVIF encoding (--encoding avif) |
rav1e (via image) |
clipboard |
--clipboard flag, copy to Wayland clipboard |
wl-clipboard-rs |
color_picker |
--color flag, freeze screen and pick a pixel color |
— |
jxl |
JPEG-XL encoding (--encoding jxl) |
libjxl / jpegxl-rs |
logger |
--log-level flag, tracing output to stderr |
tracing-subscriber |
notifications |
Desktop notifications after each capture | notify-rust |
selector |
--geometry flag, interactive region selection |
libwaysip |
If you build without the clipboard feature, you can still pipe stdout to wl-copy:
wayshot - | wl-copyAlternatively, set stdout = true in your config file to always write to stdout, then pipe as usual.
wayshot-git & wayshot-bin have been packaged.
- scdoc (If present, man-pages will be generated.)
- rustup
- make
- pkg-config
- libjxl (optional — only needed when the
jxlfeature is enabled)
git clone https://github.com/waycrate/wayshot && cd wayshotmake setupmakesudo make install
Massive thanks to smithay developer Cmeissl and Victor Berger. Without them this project won't be possible as my wayland knowledge is limited.
