Stuck at capacitor init

Hi!
Sorry if this is a dumb question, I’m a newbie in Ionic deployment (I’ve been playing for some time on my dev machine with an Ionic frontend project, but never deployed it).

I wanted to start deploying my project to iOS and Android, and followed the procedure at Deploying to iOS and Android - Ionic Documentation

But… I wont go very far because the cap add task never finishes.
After this last log, nothing happens for minutes (I waited about 15min):

> capacitor init zef io.ionic.starter --web-dir www
[?] Cordova preferences can be automatically ported to capacitor.config.json.
    Keep in mind: Not all values can be automatically migrated from config.xml. There may be more work to do.
    More info: https://capacitorjs.com/docs/v3/cordova/migrating-from-cordova-to-capacitor

I googled around but didn’t find anything about that particular problem or how to investigate further.

A couple more info:

  • I’m on mac
  • it’s an Ionic + Angular project
  • ionic build succeeds
  • ionic --version: 6.16.1
  • npm -v: 6.13.4

Could someone help me understand what’s going on?

Thanks!

It’s a bug, it has been reported

Should be fixed on next @capacitor/cli release

As workaround you can run npx cap init and add capacitor inside the integrations object in ionic.config.json

"integrations": {
    "capacitor": {}
},
1 Like