capacitor-app-spm-migration

Migrates Capacitor app iOS dependency management from CocoaPods to Swift Package Manager.

1|Updated Aug 25, 2026
One-click install
npx skills add https://github.com/involvex/ionic-everywhere --skill capacitor-app-spm-migration-involvex
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: capacitor-app-spm-migration
Source: https://github.com/involvex/ionic-everywhere/tree/main/.agents/skills/capacitor-app-spm-migration
Command: npx skills add https://github.com/involvex/ionic-everywhere --skill capacitor-app-spm-migration-involvex

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Migrating a Capacitor app's iOS project from CocoaPods to Swift Package Manager is destructive and error-prone: the ios/ folder must be deleted and re-scaffolded, and user-authored files like Info.plist, AppDelegate.swift, entitlements, and signing configuration can be lost. This Skill guides the entire migration safely with backup, restore, and verification steps. ## Core Features & Use Cases - Pre-migration validation: Verifies the project is a Capacitor app on Capacitor 6+, confirms CocoaPods usage, and requires a clean git working tree before any destructive step. - Backup and restore workflow: Inventories installed Capacitor plugins, backs up user-authored iOS files (Info.plist, AppDelegate.swift, Assets.xcassets, entitlements, GoogleService-Info.plist), deletes ios/, re-scaffolds with npx cap add ios --packagemanager SPM, and restores everything. - Signing and capability recovery: Extracts bundle identifier, development team, and version values from the old project.pbxproj and reapplies them to the new SPM scaffold, with guidance for re-adding capabilities in Xcode. - Use Case: A team with a Capacitor 6 app using CocoaPods wants to adopt SPM. The Skill walks through backup, re-scaffolding, plugin re-sync via npx cap sync ios, and build verification, flagging any plugin lacking SPM support. ## Quick Start Migrate my Capacitor app's iOS project from CocoaPods to Swift Package Manager, preserving my existing configuration and signing setup.

Frequently Asked Questions about capacitor-app-spm-migration

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I migrate a Capacitor app from CocoaPods to SPM?

Back up user-authored iOS files, delete the ios/ folder, re-scaffold with npx cap add ios --packagemanager SPM, restore the backed-up files, reapply signing values in project.pbxproj, then run npx cap sync ios and verify the build in Xcode.

What files should I back up before deleting the Capacitor ios folder?

Preserve Info.plist, AppDelegate.swift, SceneDelegate.swift, Assets.xcassets, Base.lproj, App.entitlements, GoogleService-Info.plist, any .xcconfig files, custom Swift sources, and project.pbxproj for extracting signing values.

What are the requirements for Capacitor SPM migration?

The project must be a Capacitor app (not a plugin) on Capacitor 6 or higher, with Node.js 18+, Xcode 15+, an existing ios/App/Podfile, and a clean git working tree so the destructive migration can be reverted.

What happens if a Capacitor plugin does not support SPM?

npx cap sync ios reports plugins without SPM support. You must wait for upstream support, fork the plugin and add a Package.swift yourself, or remove the plugin — the migration should pause rather than silently drop it.

Why do push notifications stop working after SPM migration?

The Push Notifications capability was not re-added in Xcode's Signing & Capabilities tab, or App.entitlements is not linked via the CODE_SIGN_ENTITLEMENTS build setting in the new project.pbxproj.

Can I use this migration for a Capacitor plugin project?

No. This procedure applies only to Capacitor app projects with an existing ios/ folder using CocoaPods. Plugin projects, apps already on SPM, and non-Capacitor frameworks are explicitly out of scope.