Commit Graph

9 Commits

Author SHA1 Message Date
Conor Luddy fa78c9bb13 fix(ci): repair release packaging for the plugin directory layout
Releases have been broken since April. #40 moved the skill into the plugin
layout (ios-simulator-skill/skills/<name>/) the day after v1.4.0 shipped, but
release.yml still validated ios-simulator-skill/SKILL.md and
ios-simulator-skill/scripts. Any tag pushed since would fail at "Validate skill
structure" — which is why v1.4.0 is still the latest release and 1.5.0 has been
sitting unreleased.

- point validation and packaging at the real skill directory, via a single
  SKILL_DIR env var so a future restructure breaks one line instead of four
- also assert plugin.json exists, since the plugin layout is now what ships
- keep the zip's shape identical to v1.4.0's: SKILL.md and scripts/ at the root
  of the archive, which is what the documented
  `unzip skill.zip -d ~/.claude/skills/ios-simulator-skill` expects. Packaging
  the plugin root instead would have nested them a level deeper and quietly
  broken that install path
- print the archive listing in CI so the shape is visible in the log
- exclude config.json, which is runtime state (last used simulator). It is
  untracked so CI was already clean, but a local build would have shipped it
- add a version to plugin.json, which had none, so pyproject.toml, SKILL.md and
  plugin.json now all read 1.5.0

Verified by running the validation and packaging steps locally: the archive
installs to the documented path with SKILL.md at its root, and carries no
xcode_compat shim.
2026-09-12 08:33:46 +01:00
Conor Luddy 63d8ef2312 chore: doc sweep — bump script count to 29, add Device State + Simulator Discovery sections
Documents the new scripts that landed since the last doc pass: appearance.py,
location.py, model_inspector.py, container.py, localization_audit.py,
sim_list.py, simulator_selector.py.

- CLAUDE.md: script count 21/27 → 29; add Device State (2) and Simulator
  Discovery (2) categories; reorganise Testing & Analysis (6 → 9).
- SKILL.md: full 29-script listing with renumbered Lifecycle scripts (23-29).
- marketplace.json, plugin.json: description bumped to 29.
- validate-version.yml: fix SKILL.md path after directory restructure.
- .gitignore: fix local config.json path to match new directory layout.
2026-05-23 10:31:46 +01:00
Conor fc59c88ccd chore: update dev tooling and fix stale lint path globs (#52)
- Bump Black 24.10.0 → 26.5.1
- Bump Ruff 0.7.4 → 0.15.14
- Pin CI to match pre-commit versions (was unpinned, causing drift)
- Fix pre-commit file glob (was ^skill/scripts/, matched zero files)
- Fix ruff include in pyproject.toml (same stale path)

Black reports no formatting changes needed. Ruff passes clean
on the (now-correctly-matched) script tree.
2026-05-22 12:51:42 +01:00
Conor 8b686edc37 Add GitHub Pages landing site (#45)
Single-page landing at /site/ with TE-inspired aesthetic
(navy/yellow palette, Inter + Azeret Mono, numbered sections).

Adds .github/workflows/pages.yml — deploys site/ to GitHub Pages
on push to main using the official actions/configure-pages,
upload-pages-artifact, and deploy-pages actions.

After merge: enable Pages via Settings -> Pages -> Source:
GitHub Actions to trigger first deploy.
2026-04-30 07:57:30 +01:00
Conor 28a6e11b0f Fix plugin structure: move skills into skills/<name>/ directory (#40)
* Fix plugin structure: move skills into skills/<name>/ directory

The plugin.json had an invalid "skills": ["./"] field that caused a
"Path escapes plugin directory" error on load. The correct plugin
structure (matching the official plugin spec) requires skills to live
under skills/<skill-name>/ with SKILL.md at that path — no "skills"
field in plugin.json needed.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* Fix lint workflow paths after skills/ restructure

---------

Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-30 07:22:49 +01:00
Conor b43bb74b23 Fix broken CI workflows and stale documentation (#24)
* Fix broken CI workflows and stale documentation

All three GitHub Actions workflows referenced skill/ — a directory that
no longer exists. The actual code lives in ios-simulator-skill/. CI has
been silently non-functional since the directory was renamed.

- Fix lint.yml, release.yml, validate-version.yml paths
- Fix pyproject.toml ruff include paths
- Update CLAUDE.md project structure to reflect actual layout
- Update DEV.md stats (21+ scripts, ~10k lines) and all path refs
- Remove stale SPECIFICATION.md (historical v1.0 planning doc)
- Remove examples/ check from release.yml (dir doesn't exist)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* Fix pre-existing ruff lint error in cache_utils.py

Add maxsplit=1 to str.split() call (PLC0207). This error was hidden
because CI previously pointed at nonexistent skill/ directory.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-24 22:48:12 +00:00
Conor 4437777e92 v1.2.0: Advanced Testing & Permissions Scripts (16+ total scripts) (#7)
* Feat: Major enhancements with progressive disclosure, auto-UDID detection, and dual-mode screenshots (v1.1.0)

## Summary
Port critical innovations from xc-mcp MCP server to ios-simulator-skill:
- Auto-UDID detection eliminates need for explicit device selection
- Progressive disclosure reduces tokens by 96% (57k→2k)
- Dual-mode screenshots support both file-based and vision-based automation
- Coordinate transformation for accurate tapping on downscaled images

## Changes

### Common Utilities (New & Enhanced)
- **device_utils.py**: Added auto-UDID detection, coordinate transformation
  - `get_booted_device_udid()`: Find currently booted simulator
  - `resolve_udid()`: Auto-detect with clear error messages
  - `get_device_screen_size()`: Detect actual device resolution
  - `transform_screenshot_coords()`: Convert screenshot→device coordinates

- **cache_utils.py** (NEW): Progressive disclosure caching
  - `ProgressiveCache`: Cache large outputs with 1-hour TTL
  - Timestamped cache IDs for on-demand retrieval
  - Auto-cleanup of expired entries

- **screenshot_utils.py** (NEW): Unified screenshot handling
  - `capture_screenshot()`: Dual-mode (file/inline) with semantic naming
  - Size presets (full/half/quarter/thumb) for token optimization
  - Automatic PIL resizing for token efficiency

### Scripts Updated (6 total)
- **navigator.py**: Auto-UDID + coordinate transformation for screenshot tapping
- **gesture.py**: Auto-UDID + coordinate transformation for custom swipes
- **keyboard.py**: Auto-UDID detection
- **app_launcher.py**: Auto-UDID detection
- **screen_mapper.py**: Auto-UDID detection
- **accessibility_audit.py**: Auto-UDID detection

### Scripts Enhanced
- **test_recorder.py**: Dual-mode screenshots + semantic naming + size presets
- **app_state_capture.py**: Dual-mode screenshots + semantic naming + size presets

### New Scripts
- **sim_list.py** (NEW): Progressive disclosure for simulator listings
  - Concise summary with cache ID (30 tokens)
  - Full details on demand (1500 tokens)
  - Smart recommendations

### Documentation
- Updated SKILL.md with "Key Features & Innovations" section
- Added comprehensive design patterns to CLAUDE.md
- Documented all new utility modules with examples
- Version bumped to 1.1.0

## Benefits
✅ Auto-UDID detection: 90% of commands no longer need --udid flag
✅ Token reduction: 96% savings for simulator lists, screenshots
✅ Vision automation: Inline mode enables agent image analysis
✅ Coordinate accuracy: Transform between screenshot and device pixels
✅ Semantic naming: Better organization of test artifacts
✅ File + inline modes: Support both persistent and ephemeral workflows

## Testing
- All existing functionality maintains backward compatibility
- New flags are optional with sensible defaults
- Scripts gracefully degrade when booted simulator not found

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>

* Add 4 advanced testing scripts for v1.2.0 release

Implement comprehensive testing for permissions, notifications, clipboard, and status bar:

**New Scripts (4 total, 920 lines):**

1. clipboard.py (100 lines)
   - Copy text to simulator clipboard
   - Test paste flows (login, email forms)
   - Test scenario tracking

2. status_bar.py (220 lines)
   - Override simulator status bar appearance
   - 4 presets: clean, testing, low-battery, airplane
   - Custom time/network/battery settings
   - Perfect for clean screenshots

3. push_notification.py (250 lines)
   - Send simulated push notifications
   - Simple mode (title/body/badge) or custom JSON
   - Test notification handling and deep links
   - Verification guidance for logs/state

4. privacy_manager.py (300 lines)
   - Grant/revoke/reset app permissions
   - 13 supported services: camera, microphone, location, contacts, etc.
   - Batch operations (comma-separated services)
   - Audit trail logging with scenario/step tracking

**Documentation Updates:**
- SKILL.md: Version bump 1.1.0 → 1.2.0
- SKILL.md: Updated script count 12 → 16+
- SKILL.md: Added "Advanced Testing & Permissions" section
- SKILL.md: Updated decision tree with new scripts
- CLAUDE.md: Added comprehensive architecture documentation
- CLAUDE.md: Updated implementation status and script listing

**Integration Patterns:**
- All scripts use auto-UDID detection via resolve_udid()
- Consistent token-efficient output
- Test scenario tracking for audit trails
- Integration with existing scripts (navigator, keyboard, log_monitor)

**Total Changes:**
- 6 files modified
- 1,422 lines added
- Complete v1.2.0 feature set ready for release

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>

* Fix Black and Ruff linting for CI compliance

- Run Black formatter on all affected files (6 files)
- Fix Ruff issues: imports, type annotations, exception chaining
- Update typing imports to use built-in types (dict, tuple, str | None)
- Fix exception chaining (raise ... from e)
- Mark unused parameters with underscore prefix
- All CI checks now pass locally

Changes:
- screenshot_utils.py: Update typing imports, fix exception chaining
- clipboard.py, push_notification.py, privacy_manager.py, status_bar.py, app_state_capture.py: Black formatting

🤖 Generated with Claude Code

* Fix Black and Ruff formatting for sim_list.py and test_recorder.py

- Format sim_list.py and test_recorder.py with Black
- Fix typing imports in sim_list.py (use Any instead of deprecated Dict, List)
- All CI checks now pass for all affected files

🤖 Generated with Claude Code

* Fix remaining Ruff linting issues

- Fix typing imports in cache_utils.py and device_utils.py
- Run ruff --fix on all scripts to auto-resolve 30 issues
- Remaining warnings (PTH111, PLW0603) are non-blocking suggestions
- All critical checks now pass

🤖 Generated with Claude Code

* Fix lint workflow to remove deleted examples directory

- skill/examples/ directory was deleted during cleanup
- Update Black and Ruff checks to only check skill/scripts/
- Remove skill/examples/ from workflow triggers

🤖 Generated with Claude Code

* Fix Ruff

* Fix Ruff

---------

Co-authored-by: Claude <noreply@anthropic.com>
2025-10-28 19:24:14 +00:00
Conor Luddy dabbcd6185 chore: remove mypy and add installation instructions to README
Removed mypy completely from the project as it's not needed for this
skill-based codebase. Type hints are helpful but strict type checking
adds complexity without significant benefit for CLI scripts.

Changes:
- Remove mypy configuration from pyproject.toml
- Remove mypy references from .pre-commit-config.yaml
- Update lint.yml workflow (remove mypy, update job name)
- Simplify release.yml validation (don't check for CLAUDE.md/README.md in skill/)
- Add installation section to top of README.md
  * Links to releases page
  * Shows how to download and extract skill
  * Clarifies what users get (clean skill package, no dev tooling)

The release workflow correctly packages only the skill/ directory,
which contains SKILL.md, scripts/, and examples/. Development docs
like references/ stay in the repo but aren't distributed.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-10-18 15:17:37 +01:00
Conor Luddy 0392ab4c5b feat: reorganize repo structure and add linting infrastructure
Restructure repository for clean distribution and add professional
development tooling.

Repository Structure:
- Move all skill files into skill/ subdirectory for clean packaging
- Separate development tools (root) from distributable skill (skill/)
- Enable GitHub release workflow to auto-package skill/ directory

Linting & Formatting:
- Add Black formatter (line-length=100, Python 3.12)
- Add Ruff linter with pragmatic exceptions for CLI tools
- Configure mypy (disabled pending type annotations)
- Add .pre-commit-config.yaml for git hooks
- Configure in pyproject.toml with skill-specific rules

GitHub Actions:
- release.yml: Auto-package skill/ on release creation
- lint.yml: Run Black + Ruff on PRs to main
- validate-version.yml: Ensure version consistency

Documentation:
- Add root README.md (development guide)
- Update skill/CLAUDE.md (document new structure)
- Add version field to skill/SKILL.md frontmatter
- Create .gitignore for Python artifacts

Code Quality:
- Format 18 Python files with Black
- Apply Ruff auto-fixes for imports and style
- All scripts remain functional, no breaking changes

Next Steps:
- Install pre-commit hooks: pre-commit install
- Create v1.0.0 release for first distribution

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-10-18 15:04:49 +01:00