Stable v0.1.0

garshot

X11 screenshot utility with annotation editor

garshot is a screenshot utility for the gardesk ecosystem featuring fast MIT-SHM capture, interactive selection with blur overlay, multi-monitor support via XRandR, built-in annotation editor with 8 drawing tools, and multiple output formats including PNG, JPEG, and WebP. Supports daemon mode with IPC for quick captures.

🎯 RPM Available

Installation

garshot is available as an RPM package for Fedora and RHEL-compatible distributions.

Using DNF (Recommended)

$sudo dnf config-manager --add-repo https://repos.musicsian.com/musicsian.repo
$sudo dnf install garshot

Building from Source

$git clone https://github.com/espadon/gardesk
$cd gardesk/garshot
$cargo build --release
$sudo install -Dm755 target/release/garshot /usr/local/bin/garshot
$sudo install -Dm755 target/release/garshotctl /usr/local/bin/garshotctl

Build Dependencies

$sudo dnf install libxcb-devel libX11-devel cairo-devel# Fedora/RHEL
$sudo apt install libxcb1-dev libx11-dev libcairo2-dev# Debian/Ubuntu
$sudo pacman -S libxcb libx11 cairo# Arch Linux

Runtime Dependencies

  • xclip - Clipboard integration (or xsel as fallback)
  • libnotify - Desktop notifications (optional, for --notify)

Quick Start

Full Screen Capture

Capture the entire screen and save to the default directory:

$garshot screen
~/Pictures/Screenshots/screenshot-20260203-143052.png

Interactive Selection

Click and drag to select a region with blur overlay:

$garshot select# Opens selection overlay

Controls: Left click + drag to select, release to capture, right click or Escape to cancel.

Window Capture

$garshot window# Capture active window
$garshot window -d# Include window decorations
$garshot window -i 0x1400007# Capture by window ID

Region by Geometry

$garshot region -g 800x600+100+50# WxH+X+Y format

Capture with Annotation

Open the annotation editor immediately after capture:

$garshot screen -a# Capture and annotate
$garshot select -a# Select region and annotate
$garshot annotate ~/Pictures/screenshot.png# Edit existing file

gar Keybindings

Add to ~/.config/gar/init.lua:

-- Screenshot keybindings
gar.bind("ctrl+shift+4", function()
    gar.exec("garshot select")
end)

gar.bind("ctrl+shift+5", function()
    gar.exec("garshot screen")
end)

gar.bind("ctrl+shift+6", function()
    gar.exec("garshot window")
end)

-- With annotation editor
gar.bind("ctrl+shift+3", function()
    gar.exec("garshot select -a")
end)

Common Options

Option Type Default Description
-o, --output PATH - Auto-generated Output file path (use "-" for stdout)
-f, --format FMT - png Output format: png, jpeg, webp
-c, --cursor - false Include mouse cursor in capture
--no-clipboard - false (copies) Skip copying to clipboard
--delay SECS - none Countdown delay before capture
--notify - false Show desktop notification on save
-a, --annotate - false Open annotation editor after capture