Skip to content

Upgrade gradle & gradlew wrapper scripts (./gradlew & ./gradlew.bat) #6

Description

@emanuelb

The ./gradlew & ./gradlew.bat files are old, the ./gradlew require bash dependency which is removed in newer version, gradle version in distributionUrl (in file gradle/wrapper/gradle-wrapper.properties) was updated in the past without updating the related gradle scripts.

newer versions of the scripts are used which avoid the bash dependency, future updates to gradle will include updates to scripts as well.

running:

./gradlew wrapper --gradle-version 7.2
which is the command to upgrade the gradle wrapper:
https://docs.gradle.org/current/userguide/gradle_wrapper.html#sec:upgrading_wrapper

will result in changes in both gradlew and gradlew.bat files.

the history of ./gradle/wrapper/gradle-wrapper.properties shows that the gradle version was updated several times, but in each update the related wrapper files wasn't updated, thus in the future it's also recommended to run the above command when upgrading the gradle version (as it's change the gradle version in distributionUrl as well)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions