Closed rafialikhan closed 7 years ago
We set up another clean yo m-ionic project and still get the above error when running gulp --cordova "platform add android --save"
Have seen the same error gulp-shell
for other gulp --cordova commands and npm commands as well.
Also npm install takes for ever to complete. Are there any deprecated/removed npm packages that are being referred?
As mentioned before, this is happening on Mac OS.
Ok some thoughts:
Here is another one...
[19:36:24] Finished 'eslint' after 6.26 s
[19:36:24] Starting 'linting'...
[19:36:24] Finished 'linting' after 6.77 μs
[19:36:25] Finished 'clean' after 4.54 s
[19:36:25] Starting 'styles'...
[19:36:27] Starting 'bower-fonts'...
[19:36:27] Starting 'build-templates'...
[19:36:29] Finished 'bower-fonts' after 1.95 s
[19:36:29] Starting 'build-assets'...
[19:36:29] Finished 'styles' after 4.54 s
[19:36:29] Starting 'inject-all'...
[19:36:30] Finished 'build-templates' after 2.53 s
[19:36:30] gulp-inject 33 files into index.html.
[19:36:30] gulp-inject 14 files into index.html.
[19:36:30] Finished 'inject-all' after 417 ms
[19:36:30] Starting 'build-app'...
[19:36:32] Finished 'build-app' after 1.78 s
[19:36:32] gulp-imagemin: Minified 0 images
[19:36:32] Finished 'build-assets' after 2.74 s
[19:36:32] Starting 'build'...
...
*Bunch of project files listed*
...
[19:36:32] Finished 'build' after 317 ms
[19:36:32] Starting 'cordova-with-build'...
Error: Cordova does not know “prepare”; try `cordova help` for a list of all the available commands.
[19:36:36] 'cordova-with-build' errored after 4.42 s
[19:36:36] Error in plugin 'gulp-shell'
The rest of it is mostly link errors....a whole bunch of them. ✖ 1971 problems (1568 errors, 403 warnings)
The Error in plugin 'gulp-shell'
is happening consistently for ios and android. (gulp run OS). Its also happening for gulp build.
<?xml version='1.0' encoding='utf-8'?>
<widget id="com.zool.presence" version="1.0.0" xmlns="http://www.w3.org/ns/widgets" xmlns:cdv="http://cordova.apache.org/ns/1.0">
<name>Test App</name>
<description>
Test APP
</description>
<author email="dev@cool.in" href="http://cool.in">
Dev Team
</author>
<content src="index.html" />
<plugin name="cordova-plugin-whitelist" spec="1" />
<access origin="*" />
<allow-intent href="http://*/*" />
<allow-intent href="https://*/*" />
<allow-intent href="tel:*" />
<allow-intent href="sms:*" />
<allow-intent href="mailto:*" />
<allow-intent href="geo:*" />
<platform name="android">
<allow-intent href="market:*" />
</platform>
<platform name="ios">
<allow-intent href="itms:*" />
<allow-intent href="itms-apps:*" />
</platform>
<engine name="ios" spec="~4.3.1" />
<engine name="android" spec="~6.1.2" />
<engine name="windows" spec="~4.4.3" />
<engine name="browser" spec="~4.1.0" />
<plugin name="cordova-plugin-device" spec="~1.1.5" />
<plugin name="cordova-plugin-dialogs" spec="~1.3.2" />
<plugin name="cordova-plugin-inappbrowser" spec="~1.7.0" />
<plugin name="ionic-plugin-keyboard" spec="~2.2.1" />
<plugin name="cordova-plugin-network-information" spec="~1.3.2" />
<plugin name="cordova-plugin-splashscreen" spec="~4.0.2" />
<plugin name="cordova-plugin-statusbar" spec="~2.2.2" />
<plugin name="ionic-plugin-deploy" spec="~0.6.6" />
</widget>
Sorry for the late answer. I cannot see whats wrong here. Most colleagues at @mwaylabs run macOS and do not have this issues.
Sometimes it helps deleting the node_modules
folder and install it again with npm install
.
Besides from that I really have no clue...
This is on a Windows 10 machine. Was seeing similar Gulp-shell error, when running gulp --cordova "run android"
Trying to run this on a connected device (Moto G4)
BUILD SUCCESSFUL
Total time: 1.675 secs
Built the following apk(s):
E:/Project/XXXXXX/fe/platforms/android/build/outputs/apk/android-debug.apk
ANDROID_HOME=C:\Users\XXXXXX\AppData\Local\Android\android-sdk
JAVA_HOME=C:\Program Files\Java\jdk1.8.0_101
No target specified, deploying to device 'ZZZZZZ'.
Skipping build...
Built the following apk(s):
E:/Project/XXXXXX/fe/platforms/android/build/outputs/apk/android-debug.apk
Using apk: E:/Project/XXXXXX/fe/platforms/android/build/outputs/apk/android-debug.apk
Package name: com.zzz.XXXXXX
Error: C:\Users\XXXXXX\AppData\Local\Android\android-sdk\platform-tools\adb.exe: Command failed with exit code 1 Error output:
Failed to install E:/Project/XXXXXX/fe/platforms/android/build/outputs/apk/android-debug.apk: Failure [INSTALL_FAILED_UPDATE_INCOMPATIBLE: Package com.zzz.XXXXXX signatures do not match the previously installed version; ignoring!]
[20:33:21] 'cordova-with-build' errored after 8.66 s
[20:33:21] Error in plugin 'gulp-shell'
Message:
Command `node_modules\cordova\bin\cordova run android` failed with exit code 1
Based on the error removed the pre-installed app from the device and it worked.
However when running gulp --livereload "run android"
, getting an error saying www\undefined and notice that in the www folder the index.html is removed which is not the case when you do gulp --cordova "run android"
Not seeing this issue anymore, so closing this. If anyone else is getting this - do reopen. Thanks @MathiasTim for all your inputs.
I had started with the m-ionic demo app so didnt install the generator-m gobally
gulp watch runs fine in the browser.
Also
gulp --cordova "platform add android --save"
had given a similar error but i could see the platform folder created, so tried to do a run.