Registry / devops / capacitor-identity

capacitor-identity

JSON →
library1.0.4jsnpmunverified

capacitor-identity is a focused command-line interface (CLI) tool designed to simplify the process of updating the application ID (bundle identifier for iOS, `applicationId` for Android) and the display name (`appName`) for Capacitor-based mobile applications. Currently at version 1.0.4, it serves as a utility for developers needing to quickly configure their Capacitor projects for different environments (e.g., staging vs. production) or rebranding efforts. Its primary differentiator is its simplicity and direct approach to modifying core native project settings without requiring manual edits in Xcode or Android Studio. It is executed via `npx` and directly manipulates the necessary configuration files within the Capacitor project structure. The package is likely updated on an as-needed basis to support new Capacitor versions or address specific platform changes, rather than following a frequent release cadence, given its specialized function.

npm install capacitor-identity
INSTALL
IMPORT
SIG · CAPACITOR-IDENTITY
C
capacitor-identity
devopsjavascriptv1.0.4
Install
Import
Disk
Pass rate
0/ 6
Env Coverage0 / 6
glibc
1822
musl
1822
Install & Compatibility
Where this runs
tested against v? · npm install
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
node 18226 runs
build_error
glibc
node 18226 runs
build_error
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

capacitor-identity (CLI)
npx capacitor-identity --bundleId com.example.newapp --appName "New App Staging"
import { updateIdentity } from 'capacitor-identity';
This package is a command-line interface (CLI) tool and is not intended for direct programmatic import into JavaScript/TypeScript code. It should be executed via `npx` in your project's root directory.

Demonstrates how to update the application bundle ID and display name of a Capacitor project using the CLI tool.

npx capacitor-identity --bundleId com.example.newapp --appName "New App Staging" # After running, ensure to sync and rebuild your native projects: npx cap sync npx cap open ios npx cap open android
capacitor-identity --version
Debug
Known issues
gotchaEnsure you run `capacitor-identity` from the root directory of your Capacitor project. Executing it elsewhere will result in 'file not found' errors or incorrect modifications.
fix
Navigate to your Capacitor project's root directory (where `capacitor.config.ts` or `package.json` resides) before running the command.
affects: >=1.0.0
gotchaThe `--bundleId` and `--appName` flags are mandatory for `capacitor-identity` to perform its updates. Omitting either will lead to an `Error: Missing required argument` and the operation will not complete.
fix
Always provide both `--bundleId com.your.app` and `--appName "Your App Name"` arguments.
affects: >=1.0.0
gotchaAfter running `capacitor-identity`, it is crucial to rebuild your native projects (`npx cap sync && npx cap open [ios|android]`) to ensure the changes are picked up by Xcode and Android Studio.
fix
Run `npx cap sync` followed by `npx cap open ios` and/or `npx cap open android` in your project root.
affects: >=1.0.0
Errors
Common errors & fixes
Error: ENOENT: no such file or directory, open 'capacitor.config.ts'
The `capacitor-identity` command was executed outside the root directory of a Capacitor project.
fix
Change your current directory to your Capacitor project's root, then re-run `npx capacitor-identity ...`.
Error: Missing required argument: bundleId
The `--bundleId` argument was omitted when running the `capacitor-identity` command.
fix
Include the `--bundleId com.your.app` argument in your `npx capacitor-identity` command.
Error: Missing required argument: appName
The `--appName` argument was omitted when running the `capacitor-identity` command.
fix
Include the `--appName "Your App Name"` argument in your `npx capacitor-identity` command.
Upgrade
Version history
1.0.4latest on npm
Audit
Dependencies

No dependency data recorded yet.

Agent activity
4 hits · last 30 days
node
4
Resources