fix(windows): get gradle path with which command #1793
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Motivation and Context
Resolves #1792
Description
Before Android Studio 3.5, Gradle was bundled with the IDE.
In the past, for Windows environments, we attempted to locate the Android Studio installation path to use its bundled Gradle executable.
However, Cordova has not supported old versions of Android Studio for a long time, making this logic obsolete. Additionally, past release announcements have indicated increasing Android Studio requirements:
Documentation also stated that since Cordova-Android 6.4.0, a system-level Gradle installation is required. Cordova would then uses this to generate the project-level Gradle wrapper.
Given these changes, this PR will remove the outdated Windows-specific logic. The
.bat
file will remain for now but will be removed in the next major release.Testing
cordova build android
command on Windows.Checklist
(platform)
if this change only applies to one platform (e.g.(android)
)