desktop

Controls a live Fedora niri desktop session via accessibility APIs, tmux, and compositor IPC.

2|Updated May 18, 2022
One-click install
npx skills add https://github.com/saifulapm/dotfiles --skill desktop-saifulapm
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: desktop
Source: https://github.com/saifulapm/dotfiles/tree/main/home/dot_claude/skills/desktop
Command: npx skills add https://github.com/saifulapm/dotfiles --skill desktop-saifulapm

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires pygobject, and includes scripts (resource) components.

What problem does it solve? Automating tasks on a live Linux desktop session requires safely launching apps, typing, clicking, reading screens, and driving the shell without disrupting the user who shares keyboard focus, clipboard, and windows. ## Core Features & Use Cases - Four control surfaces: drive web apps with playwright-cli, GUI apps by widget name over the AT-SPI accessibility bus (scripts/gui), CLI/TUI programs through tmux send-keys and capture-pane, and the quickshell bar/panels via qs ipc and niri msg. - Safe input injection: hot-zone-aware pointer positioning and dragging (scripts/mouse with wlrctl/ydotool), focus verification before wtype keystrokes, and atomic focus-verify-type bursts to avoid hijacking the user's session. - Cost-aware verification: prefer text channels (tmux capture, IPC, OCR via tesseract) over screenshots, with region-only grim captures and jev-based judging for large page snapshots. - Use Case: Ask the agent to open a Laravel dev site at https://project.test, log in, click through a checkout flow, and confirm the order was placed — it picks the cheapest channel, verifies each effect, and cleans up spawned windows and tmux sessions. ## Quick Start Ask the agent to open an app, interact with it, and verify the result on screen, for example: open Chromium to my project.test site, click the login button, and confirm the dashboard loads.

Frequently Asked Questions about desktop

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I automate clicking and typing in Linux GUI apps?▼

Use the AT-SPI accessibility bus to read and activate widgets by name instead of pixel coordinates. The gui script lists apps on the bus, dumps interactive widget trees with coordinates and state flags, and clicks or types semantically without moving the pointer or stealing focus.

How to drive a TUI or interactive CLI programmatically?▼

Run the program in a headless tmux session, send input with tmux send-keys, and read output as text with tmux capture-pane. Use capture-pane -e with reverse-video regex to detect highlighted rows before destructive keystrokes, and always kill the session when done.

What is the safest way to move the mouse on niri Wayland?▼

wlrctl only supports relative movement, so absolute positioning requires pinning to an inert corner first. The mouse script pins to the bar's right end, clamps targets 2 px inside the screen, and uses ydotool for held-button drags, avoiding niri's hot corners and edge strips.

Does Playwright work with the user's logged-in Chromium session?▼

Yes, playwright-cli attach --extension connects to the running browser through the Playwright Extension with real cookies and logins. Set PLAYWRIGHT_MCP_EXECUTABLE_PATH=/usr/bin/chromium-browser, and always detach rather than close so the user's tabs survive.

Why did my automated click do nothing on a tiled window?▼

niri's scrolling layout does not expose window x-positions through IPC, so clicks computed from assumed tile coordinates miss silently. Fullscreen the window first with niri msg action fullscreen-window, then click coordinates taken from a grim -s 1 region capture.

When should I use OCR instead of screenshots for screen reading?▼

Use tesseract OCR whenever the answer is text on screen, since it returns plain text without vision tokens. Capture at native scale rather than -s 1 because tesseract needs the full-resolution pixels for small fonts.