Give this a try: "ios": "sudo ionic build && npx cap sync ios && npx cap open ios", "android": "sudo ionic build && npx cap sync android && npx cap open android",
You can add there to your package json and when you want a new build just go npm run [platform]. You can also try running it without sudo
Alex.
Hey, type npx cap open android, this will open the android studio automatically. Wait till the gradle downloads successful and click on the play button (that’s if you have an android device connected to the pc) else click on Build -- >Build Bundle /Apk and you are good to go
I have a current project in Cordova and it is integrated with Team City CI / CD.
We generate .apk and Xcode archives by running Cordova build whenever we push something to the master branch.
I like Capacitor but didn’t find the capacitor build commands for my scenario.
After spending a whole night trying to configure Android studio, which wouldn’t let a simple ionic app build properly, and then trying to fix issues for cordova, this post of yours gave me my spirits back! You’re really awesome man!!