一键导入
asset-catalog-optimizer
Analyze and optimize Xcode asset catalogs - find unused assets, missing resolutions, compress images
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Analyze and optimize Xcode asset catalogs - find unused assets, missing resolutions, compress images
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
| name | asset-catalog-optimizer |
| description | Analyze and optimize Xcode asset catalogs - find unused assets, missing resolutions, compress images |
| type | skill |
| language | python |
Analyze .xcassets folders to optimize image assets and find issues.
asset_optimizer.pyPython script for asset analysis and optimization
Commands:
# Analyze asset catalog
./asset_optimizer.py PaleoRose/Assets.xcassets analyze
# Find unused assets
./asset_optimizer.py PaleoRose/Assets.xcassets find-unused --source-dir PaleoRose
# Check missing resolutions
./asset_optimizer.py PaleoRose/Assets.xcassets check-resolutions
# Compress images
./asset_optimizer.py PaleoRose/Assets.xcassets compress --quality 85
# Generate report
./asset_optimizer.py PaleoRose/Assets.xcassets report --output report.html
# Calculate sizes
./asset_optimizer.py PaleoRose/Assets.xcassets sizes
Searches Swift/ObjC code for asset references like:
NSImage(named: "icon")UIImage(named: "logo")Image("background")[NSImage imageNamed:@"button"]Verifies all imagesets have:
Run when:
Asset Catalog Analysis: Assets.xcassets
========================================
Total Assets: 47
Total Size: 12.3 MB
Missing Resolutions (5):
- icon.imageset: Missing @2x
- logo.imageset: Missing @3x
- background.imageset: Missing @2x, @3x
Unused Assets (8):
- old-button.imageset (45 KB)
- deprecated-icon.imageset (23 KB)
- test-image.imageset (156 KB)
Potential Savings:
- Compression: 3.2 MB (26%)
- Remove unused: 1.8 MB (15%)
- Total: 5.0 MB (41%)
Recommendations:
1. Compress 23 PNG files to save 3.2 MB
2. Remove 8 unused assets to save 1.8 MB
3. Add missing @2x/@3x versions for 5 assets
Generate comprehensive API documentation using DocC (Swift-DocC) for your PaleoRose project
Analyze and optimize Xcode build times by identifying slow compilation units and suggesting improvements
Generate CI/CD configurations and automation scripts for building, testing, and deploying
Calculate code quality metrics - complexity, coverage, maintainability
Parse and analyze macOS crash logs to identify crash causes and debugging information
Parse and validate XIB/Storyboard files for broken outlets, warnings, accessibility