Asc Screenshot Resize

作者 rorkai9c7e769f09a1無授權條款1K 個星標收錄於 2026年10月8日更新於 2026年10月8日儲存庫3 天前更新

Resize and validate App Store screenshots with current asc screenshot-size data and macOS sips. Use when preparing or fixing screenshots for App Store Connect submission.

僅含說明Design & Creative
AI 產生的概覽

透過查詢可接受尺寸、移除透明通道、以 sips 調整尺寸並在上傳前驗證,來準備 App Store Connect 螢幕截圖。

功能
此技能引導代理為 App Store Connect 提交準備螢幕截圖。它會從 asc 命令列工具取得目前可接受的尺寸,清理檔名,使用 macOS sips 檢查影像尺寸與中繼資料,移除 alpha 透明通道,將影像調整為選定的目標尺寸,並在選擇性上傳前以 asc 驗證結果。它會在個別的輸出目錄中產生調整並驗證過的截圖檔案,同時保留原始檔案。
適用情境
適用於為 App Store Connect 提交準備或修正螢幕截圖時,尤其是影像尺寸不正確、帶有 alpha 透明通道,或檔名導致工具失敗的情況。也適合在上傳前批次調整並驗證 iPhone 或 iPad 截圖集。
執行需求
需要 asc 命令列工具及其截圖尺寸、驗證與上傳子命令,以及 macOS sips 和用於清理檔名的 python3。上傳時需要 App Store Connect 版本在地化識別碼,asc 操作需要網路存取。此技能未附帶指令碼,全部為說明與 shell 命令。

asc screenshot resize

Use this skill to prepare screenshots for App Store Connect. Do not rely on a hard-coded dimension table in this skill; the CLI owns the current size matrix.

Source of truth

Always discover current accepted sizes from asc first:

bash
asc screenshots sizes --output tableasc screenshots sizes --all --output table

For local validation before upload:

bash
asc screenshots validate --path "./screenshots/iphone" --device-type "IPHONE_65" --output tableasc screenshots validate --path "./screenshots/ipad" --device-type "IPAD_PRO_3GEN_129" --output table

Common current device-type anchors:

  • IPHONE_65 for the common 6.5-inch iPhone screenshot set.
  • IPAD_PRO_3GEN_129 for the common 12.9/13-inch iPad screenshot set.

Run asc screenshots sizes --all when targeting other display types such as 6.9-inch iPhone, Apple TV, Mac, Vision Pro, iMessage, or Watch.

Workflow

1. Sanitize filenames

macOS screenshots can contain hidden Unicode spaces that make tools fail with "not a valid file". Sanitize before batch work:

bash
python3 -c "import osfor f in os.listdir('.'):    clean = f.replace('\u202f', ' ')    if f != clean:        os.rename(f, clean)        print(f'Renamed: {clean}')"

2. Inspect dimensions and metadata

bash
sips -g pixelWidth -g pixelHeight screenshot.pngsips -g hasAlpha -g space screenshot.png

App Store Connect rejects screenshots with alpha transparency. Strip alpha by round-tripping through JPEG:

bash
sips -s format jpeg input.png --out /tmp/asc-screenshot-no-alpha.jpgsips -s format png /tmp/asc-screenshot-no-alpha.jpg --out output.pngrm /tmp/asc-screenshot-no-alpha.jpg

Batch-strip alpha from PNGs:

bash
for f in *.png; do  if sips -g hasAlpha "$f" | grep -q "yes"; then    sips -s format jpeg "$f" --out /tmp/asc-screenshot-no-alpha.jpg    sips -s format png /tmp/asc-screenshot-no-alpha.jpg --out "$f"    rm /tmp/asc-screenshot-no-alpha.jpg    echo "Stripped alpha: $f"  fidone

3. Resize only after choosing a target from asc

Pick a width and height from asc screenshots sizes --all. sips -z takes height first, then width:

bash
# Example: portrait IPHONE_65 1284 x 2778sips -z 2778 1284 input.png --out output.png

Batch resize to a chosen target:

bash
mkdir -p resizedfor f in *.png; do  sips -z 2778 1284 "$f" --out "resized/$f"done

4. Validate outputs with asc

bash
sips -g pixelWidth -g pixelHeight -g hasAlpha resized/*.pngasc screenshots validate --path "./resized" --device-type "IPHONE_65" --output table

5. Upload only after validation

bash
asc screenshots upload --version-localization "LOC_ID" --path "./resized" --device-type "IPHONE_65" --dry-run --output tableasc screenshots upload --version-localization "LOC_ID" --path "./resized" --device-type "IPHONE_65"

Guardrails

  • Treat asc screenshots sizes --all as authoritative; Apple size requirements change.
  • Do not stretch screenshots across incompatible aspect ratios unless the user accepts the visual tradeoff.
  • Always output to a separate file or directory to preserve originals.
  • Screenshots must be PNG or JPEG and must not include alpha transparency.
  • Convert Display P3 or other color spaces to sRGB when needed:
bash
sips -m "/System/Library/ColorSync/Profiles/sRGB IEC61966-2.1.icc" input.png --out output.png
  • Prefer asc screenshots validate over visual inspection before upload.

來源與署名

來源:rorkai/app-store-connect-cli-skills位於skills/asc-screenshot-resize提交9c7e769

授權條款: 無授權條款

內容歸原作者所有。SourceWeft 從公開儲存庫中收錄這些內容。

檢舉或申請下架