Skip to content

fr-Fabix/DevScreenshot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

DevScreenshot icon

DevScreenshot

Pixel-exact window screenshots for the Mac App Store — straight from your menu bar.

macOS 13+ MIT License Swift

Why

App Store Connect only accepts macOS screenshots at a few exact pixel sizes2560×1600, 2880×1800, 1440×900, 1280×800 (all 16:10). Hitting those by hand is fiddly: a window screenshot on a Retina display is captured at 2× scale, window shadows add stray pixels, and most tools can't set a window to an exact size.

DevScreenshot does it for you. Pick a target size, pick an app — it resizes the app's front window to the matching point size (target ÷ backing-scale, e.g. 1280×800 pt → 2560×1600 px on a 2× display), captures exactly that rectangle, and trims to the last pixel so App Store Connect accepts it without complaint.

Features

  • 🎯 Exact pixel output — the four App Store presets, plus a custom W×H.
  • 🪟 Pick any app — live list of running apps in the menu; captures the front window.
  • 📱 iOS / iPad simulator — booted simulators captured at native App-Store resolution via simctl (needs neither Accessibility nor Screen Recording).
  • 📐 Retina-aware — computes the point size from the display's backing scale automatically.
  • ✂️ No distortion — pads or crops to the exact target only if an app enforces a minimum size.
  • 📁 Configurable save location — defaults to ~/Desktop/DevScreenshot.
  • ⏱️ Capture delay — 0 / 2 / 5 s, e.g. to open a menu before the shot.
  • 📋 Copy to clipboard and 🔔 shutter sound toggles.
  • 🚀 Launch at login (via SMAppService).
  • 🪶 Menu-bar only — no Dock icon, no window (LSUIElement).

Install

Download the notarized build from Releases, move DevScreenshot.app to ~/Applications, and launch it.

Or build from source (see below).

Not on the Mac App Store — and it can't be. The sandbox required by the MAS makes AXIsProcessTrusted() always return false, so a sandboxed app can't resize other apps' windows. That's exactly why tools like CleanShot X and Shottr are distributed directly too. DevScreenshot ships via Developer ID + notarization instead.

First run — permissions

DevScreenshot needs two one-time permissions (System Settings → Privacy & Security):

  1. Accessibility — to resize the target window. Requested on your first capture.
  2. Screen Recording — for the capture itself. After enabling it, quit and relaunch the app (a macOS requirement).

Usage

Click the camera icon in the menu bar:

  1. Choose a target size (or Custom…).
  2. Choose an app under Capture window.
  3. The shot is saved to your folder; optionally copied to the clipboard / revealed in Finder.

Capturing a specific window? Bring it to the front of its app first — DevScreenshot uses the front (main) window.

How it works

point size = target pixels ÷ display backing scale     # 2560×1600 px → 1280×800 pt @2x
screencapture -R x,y,w,h                                # capture the exact window rect (no shadow, no alpha)
sips -p / -c                                            # pad or crop to the exact target as a safety net

Because the window rect is captured directly (not the -l window mode), there's no drop shadow and no alpha channel — both of which App Store Connect rejects.

iOS / iPad simulator

Booted simulators appear under Capture iOS Simulator in the menu. DevScreenshot grabs them with xcrun simctl io <udid> screenshot, which renders at the device's native pixel resolution — already exactly what App Store Connect wants, with no device bezel and no Accessibility/Screen-Recording permission.

Boot the device whose resolution you need, then click it:

Device Pixels
iPhone 11 Pro Max / Xs Max 1242 × 2688 (6.5″)
iPhone 12–14 Pro Max 1284 × 2778 (6.7″)
iPhone 15/16/17 Pro Max 1290 × 2796 / 1320 × 2868
iPad Pro 12.9″ 2048 × 2732
iPad Pro 13″ (M4) 2064 × 2752

The notification flags whether the captured size is a valid App Store dimension. Rotate the simulator (⌘→) first for landscape shots.

Build from source

Requirements: Xcode 15+ and XcodeGen (brew install xcodegen).

git clone https://github.com/fr-Fabix/DevScreenshot.git
cd DevScreenshot
xcodegen generate          # creates DevScreenshot.xcodeproj from project.yml
open DevScreenshot.xcodeproj

Build & run in Xcode (⌘R), or from the command line:

xcodebuild -scheme DevScreenshot -configuration Release \
  -derivedDataPath build/dd build CODE_SIGN_IDENTITY="-"

To restyle the icon, edit Scripts/make-icon.swift, run swift Scripts/make-icon.swift AppIcon.png, and regenerate the sizes in Resources/Assets.xcassets/AppIcon.appiconset.

Release (Developer ID + notarization)

One-time setup:

  1. Create a Developer ID Application certificate: Xcode → Settings → Accounts → Manage Certificates+Developer ID Application.
  2. Store notarization credentials in a keychain profile:
    xcrun notarytool store-credentials DevScreenshot-notary \
      --apple-id "you@example.com" --team-id XF9U3N7W44 \
      --password "xxxx-xxxx-xxxx-xxxx"     # app-specific password

Then cut a release:

./Scripts/release.sh        # archive → Developer ID sign → notarize → staple → build/DevScreenshot.zip

Attach build/DevScreenshot.zip to a GitHub Release.

Project layout

project.yml            XcodeGen spec (no .xcodeproj churn in diffs)
Sources/main.swift     the whole app
Resources/             Info.plist, entitlements (un-sandboxed), Assets.xcassets
Scripts/make-icon.swift  icon generator
Scripts/release.sh     notarized Developer ID build

Ideas / roadmap

  • Global hotkey to re-capture the last app
  • Per-window picker when an app has multiple windows
  • "Capture all sizes" in one click
  • Optional device frame / background canvas for marketing shots
  • Multi-display backing-scale handling
  • Sparkle auto-updates

Contributions welcome.

License

MIT © fr-Fabix

About

Pixel-exact window screenshots for the Mac App Store, from your menu bar.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors