capacitor icon indicating copy to clipboard operation
capacitor copied to clipboard

bug: Error running subprocess capacitor right after starting project

Open scarela opened this issue 5 years ago • 3 comments

There is an error showing up right after starting a new ionic app with capacitor integration just by following commands in the tutorial.

Capacitor Version

Latest Dependencies:

@capacitor/cli: 3.1.2 @capacitor/core: 3.1.2 @capacitor/android: 3.1.2 @capacitor/ios: 3.1.2

Installed Dependencies:

@capacitor/android: not installed @capacitor/ios: not installed @capacitor/cli: 3.1.2 @capacitor/core: 3.1.2

Platform(s)

OpenSuse Leap 15.2

Current Behavior

Get this error when creating a new app: ` error: unknown option '--npm-client' [ERROR] An error occurred while running subprocess capacitor.

    capacitor init myApp io.ionic.starter --web-dir www --npm-client npm exited with exit code 1.

`

Expected Behavior

The app should be created without any issues if I have @ionic/cli and @capacitor/cli on their latests versions.

Code Reproduction

Either $ ionic start myApp sidemenu --type=angular --capacitor or $ ionic start myApp sidemenu will produce the same output.

Other Technical Details

npm --version output: v6.14.13

node --version output: v14.17.3

pod --version output (iOS issues only):

Additional Context

bug capacitor

scarela avatar Jul 28 '21 14:07 scarela

--npm-client is not an option in the Capacitor 3 CLI so does removing it fix this issue? I can take a look at the docs and update them accordingly

thomasvidas avatar Jul 28 '21 15:07 thomasvidas

--npm-client is not an option in the Capacitor 3 CLI so does removing it fix this issue? I can take a look at the docs and update them accordingly

Yes, running it witout --npm-client fixes the issue. Thanks, appreciate it.

scarela avatar Jul 28 '21 15:07 scarela

Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Capacitor, please create a new issue and ensure the template is fully filled out.

ionitron-bot[bot] avatar Nov 11 '22 00:11 ionitron-bot[bot]