Created
March 8, 2018 09:37
-
-
Save ylno/1a5933a1cd204d6ec450da28a6b528dc to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
if grep -q "com.android.support:support-v4:26.0.0" platforms/android/build.gradle; then | |
echo "build.gradle already fixed" | |
else | |
echo "configurations.all {\nresolutionStrategy.force 'com.android.support:support-v4:26.0.0'\n}" >> platforms/android/build.gradle | |
echo "android platform fixed" | |
fi |
Good afternoon,
Can you describe in more detail the folder, file and command that I should change?
This issue has wasted many hours - your solution worked for me, just wanted to say thanks!
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This is a fix for ionic if you get a building problem in android like:
Execution failed for task ':processDebugResources'.
You can find more about this problem in this thread: https://forum.ionicframework.com/t/android-build-broken-after-gradle-dependencies-update-execution-failed-for-task-processdebugresources-com-android-ide-common-process-processexception-failed-to-execute-aapt/109982
How to use
Add this file to hooks/after_platform_add/010_fix_gradle.sh. It will fix this problem if you remove and add the platform:
ionic cordova platform remove adroid ionic cordova platform add android
Please check regularly if you still need this fix or if the cordova build is fixed.