using-screenshots
$
npx mdskill add microsoft/FluidFramework/using-screenshotsYou CAN take screenshots by combining the Bash tool with platform-specific screenshot commands. Screenshots are saved as image files, then loaded into your context using the Read tool for visual analysis.
SKILL.md
.github/skills/using-screenshotsView on GitHub ↗
--- name: using-screenshots description: Use this to capture screen context. --- # Taking and Analyzing Screenshots ## Overview You CAN take screenshots by combining the Bash tool with platform-specific screenshot commands. Screenshots are saved as image files, then loaded into your context using the Read tool for visual analysis. ## When to Use Use this skill when I ask you to: - "Take a screenshot" - "Look at my screen" - "Analyze this UI bug visually" - "Review what's currently displayed" - "Capture and examine the interface" ## Quick Reference | Platform | Command | Interactive Selection | | -------- | ---------------------------------------- | -------------------------- | | macOS | `screencapture` | `-i` flag (area selection) | | Linux | `gnome-screenshot`, `scrot`, or `import` | `-a` or `-s` flag | **Standard workflow**: 1. Detect platform with `uname -s` 2. Check for available screenshot tool 3. Capture to `/tmp/screenshot_$(date +%s).png` 4. Use Read tool with the file path 5. Analyze the image 6. Optionally clean up temp file ## Step-by-Step Instructions ### 1. Detect Platform ```bash uname -s ``` - Returns `Darwin` for macOS - Returns `Linux` for Linux ### 2. Check Available Tools **macOS**: `screencapture` is always available (built-in) **Linux**: Check in priority order: ```bash which gnome-screenshot || which scrot || which import || echo "none" ``` Priority order (best compatibility): 1. `gnome-screenshot` - works on both X11 and Wayland 2. `scrot` - lightweight, X11 only 3. `import` - part of ImageMagick ### 3. Capture Screenshot Use timestamped filename to avoid conflicts: **macOS**: ```bash screencapture -i /tmp/screenshot_$(date +%s).png ``` - `-i` enables interactive area selection - User clicks and drags to select region **Linux with gnome-screenshot**: ```bash gnome-screenshot -af /tmp/screenshot_$(date +%s).png ``` - `-a` for area selection - `-f` specifies filename **Linux with scrot**: ```bash scrot -s /tmp/screenshot_$(date +%s).png ``` - `-s` enables selection mode **Linux with import**: ```bash import /tmp/screenshot_$(date +%s).png ``` - Provides crosshair for click-and-drag selection ### 4. Load Image into Context ```bash Read tool: file_path="/tmp/screenshot_12345.png" ``` The Read tool displays images visually. You'll see the screenshot and can analyze it. ### 5. Analyze the Image Once loaded, you can: - Identify UI elements - Spot visual bugs - Review design elements - Read text content - Examine layout issues ### 6. Optional Cleanup ```bash rm /tmp/screenshot_12345.png ``` Only remove if I won't need the file again. ## Handling Missing Tools If no screenshot tool is available on Linux: 1. **Inform me** which tool is missing 2. **Suggest installation**: - Ubuntu/Debian: `sudo apt install gnome-screenshot` - Fedora: `sudo dnf install gnome-screenshot` - Arch: `sudo pacman -S gnome-screenshot` - ImageMagick: `sudo apt install imagemagick` (or equivalent) 3. **Alternative**: Ask user to manually take screenshot and provide path ## Common Mistakes ### ❌ Saying "I cannot take screenshots" **Reality**: You CAN via Bash + screenshot CLI tools ### ❌ Forgetting to use Read tool after capture **Reality**: The screenshot file must be loaded with Read tool to see it ### ❌ Using relative paths **Reality**: Always use absolute paths (`/tmp/...`) for Read tool ### ❌ Not checking for available tools on Linux **Reality**: Must detect which tool is installed before attempting capture ## Example Workflow ``` User: "Take a screenshot and help me debug this UI bug" 1. Check platform: uname -s → Linux 2. Check available tools: which gnome-screenshot → /usr/bin/gnome-screenshot 3. Capture screenshot: gnome-screenshot -af /tmp/screenshot_1729012345.png → User selects area, file saved 4. Load into context: Read: file_path="/tmp/screenshot_1729012345.png" → Image displays visually 5. Analyze: "I can see the button alignment is off. The 'Submit' button is 5px lower than the 'Cancel' button..." 6. Optional cleanup: rm /tmp/screenshot_1729012345.png ```
More from microsoft/FluidFramework
- api-changesUse when customer-facing API changes were made — i.e., API report .md files differ from main. Guides through release tag assignment, API Council review requirements, breaking change classification, deprecation process, and changeset guidance. Triggered automatically by ci-readiness-check when api-report diffs are detected.
- brainstormingIMMEDIATELY USE THIS SKILL when creating or develop anything and before writing code or implementation plans - refines rough ideas into fully-formed designs through structured Socratic questioning, alternative exploration, and incremental validation
- building-ui-uxUse when implementing user interfaces or user experiences - guides through exploration of design variations, frontend setup, iteration, and proper integration
- ci-readiness-checkUse when the user explicitly asks for a CI check or to push their branch — e.g. "ci readiness", "check ci", "pre-push check", "ready for CI", "ci check", "ready to push", "push my changes", "push the branch", "let's push". Catches common CI failures before pushing — formatting, stale API reports, missing changesets, policy violations.
- creating-debug-tests-and-iteratingUse this skill when faced with a difficult debugging task where you need to replicate some bug or behavior in order to see what is going wrong.
- creating-skillsUse when you need to create a new custom skill for a profile - guides through gathering requirements, creating directory structure, writing SKILL.md, and optionally adding bundled scripts
- ff-oce-dashboardGenerate the OCE shift status dashboard. Triggers on: 'generate shift dashboard', 'show dashboard', 'shift status', 'status dashboard', 'what's going on', or any request for a NON-SPECIFIC overview of current OCE status (incidents, pipelines, errors).
- ff-oce-kustoUse this skill for any Kusto query or telemetry investigation specifically related to Fluid Framework or its partners. Triggers include: writing or running a Kusto query against the Office Fluid database, investigating Fluid Framework telemetry or error rates, querying Office_Fluid_FluidRuntime_* tables, looking up a Fluid session by Session_Id or docId, investigating a Fluid-related error in Loop or Whiteboard telemetry, monitoring an FF bump or partner ring deployment, checking Fluid render reliability or Scriptor errors, or when the user mentions Fluid-specific tables (Office_Fluid_FluidRuntime_*, OwhLoads, HostTracker, Scriptor) or Fluid-specific error types (dataCorruptionError, dataProcessingError, DeltaConnectionFailureToConnect, ICE, ACE). Do NOT trigger for general Kusto questions that are not related to Fluid Framework.
- finishing-a-development-branchUse this when you have completed some feature implementation and have written passing tests, and you are ready to create a PR.
- fluid-prUse when creating a pull request in the Fluid Framework repo. Composes a PR title and body following Fluid Framework conventions, proposes them to the user, then pushes the branch and creates the PR on GitHub. Triggers on "create a PR", "make a PR", "open a PR", "submit a PR", or "push and create a PR".