Use when the user explicitly asks for a desktop or system screenshot (full screen, specific app or window, or a pixel region), or when tool-specific capture capabilities are unavailable and an OS-level capture is needed.
79
83%
Does it follow best practices?
Impact
69%
3.63xAverage score across 5 eval scenarios
Advisory
Suggest reviewing before use
Follow these save-location rules every time:
On macOS, run the preflight helper once before window/app capture. It checks Screen Recording permission, explains why it is needed, and requests it in one place.
The helpers route Swift's module cache to $TMPDIR/codex-swift-module-cache
to avoid extra sandbox module-cache prompts.
bash <path-to-skill>/scripts/ensure_macos_permissions.shTo avoid multiple sandbox approval prompts, combine preflight + capture in one command when possible:
bash <path-to-skill>/scripts/ensure_macos_permissions.sh && \
python3 <path-to-skill>/scripts/take_screenshot.py --app "Codex"For Codex inspection runs, keep the output in temp:
bash <path-to-skill>/scripts/ensure_macos_permissions.sh && \
python3 <path-to-skill>/scripts/take_screenshot.py --app "<App>" --mode tempUse the bundled scripts to avoid re-deriving OS-specific commands.
Run the helper from the repo root:
python3 <path-to-skill>/scripts/take_screenshot.pyCommon patterns:
python3 <path-to-skill>/scripts/take_screenshot.pypython3 <path-to-skill>/scripts/take_screenshot.py --mode temppython3 <path-to-skill>/scripts/take_screenshot.py --path output/screen.pngpython3 <path-to-skill>/scripts/take_screenshot.py --app "Codex"python3 <path-to-skill>/scripts/take_screenshot.py --app "Codex" --window-name "Settings"python3 <path-to-skill>/scripts/take_screenshot.py --list-windows --app "Codex"python3 <path-to-skill>/scripts/take_screenshot.py --mode temp --region 100,200,800,600--app to capture all windows):python3 <path-to-skill>/scripts/take_screenshot.py --mode temp --active-windowpython3 <path-to-skill>/scripts/take_screenshot.py --window-id 12345The script prints one path per capture. When multiple windows or displays match, it prints multiple paths (one per line) and adds suffixes like -w<windowId> or -d<display>. View each path sequentially with the image viewer tool, and only manipulate images if needed or requested.
bash <path-to-skill>/scripts/ensure_macos_permissions.sh && \
python3 <path-to-skill>/scripts/take_screenshot.py --app "<App>" --mode temp--region to isolate a single display when needed.The helper automatically selects the first available tool:
scrotgnome-screenshotimportIf none are available, ask the user to install one of them and retry.
Coordinate regions require scrot or ImageMagick import.
--app, --window-name, and --list-windows are macOS-only. On Linux, use
--active-window or provide --window-id when available.
Run the PowerShell helper:
powershell -ExecutionPolicy Bypass -File <path-to-skill>/scripts/take_screenshot.ps1Common patterns:
powershell -ExecutionPolicy Bypass -File <path-to-skill>/scripts/take_screenshot.ps1powershell -ExecutionPolicy Bypass -File <path-to-skill>/scripts/take_screenshot.ps1 -Mode temppowershell -ExecutionPolicy Bypass -File <path-to-skill>/scripts/take_screenshot.ps1 -Path "C:\Temp\screen.png"powershell -ExecutionPolicy Bypass -File <path-to-skill>/scripts/take_screenshot.ps1 -Mode temp -Region 100,200,800,600powershell -ExecutionPolicy Bypass -File <path-to-skill>/scripts/take_screenshot.ps1 -Mode temp -ActiveWindowpowershell -ExecutionPolicy Bypass -File <path-to-skill>/scripts/take_screenshot.ps1 -WindowHandle 123456Use these when you cannot run the helpers.
screencapture -x output/screen.pngscreencapture -x -R100,200,800,600 output/region.pngscreencapture -x -l12345 output/window.pngscreencapture -x -i output/interactive.pngscrot output/screen.pnggnome-screenshot -f output/screen.pngimport -window root output/screen.pngscrot -a 100,200,800,600 output/region.pngimport -window root -crop 800x600+100+200 output/region.pngscrot -u output/window.pnggnome-screenshot -w -f output/window.pngbash <path-to-skill>/scripts/ensure_macos_permissions.sh first to request Screen Recording in one place.ModuleCache permission errors in a sandboxed run, rerun the command with escalated permissions.--list-windows --app "AppName" and retry with --window-id, and make sure the app is visible on screen.command -v scrot, command -v gnome-screenshot, and command -v import.736f600
If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.