Skip to content

GenerateSources gradle task in javaSE incorrectly reads the version from gradle.properties instead of VERSION file #1763

@bilal-alsharifi

Description

@bilal-alsharifi

Bug Report

Before maven central:

Android, JavaSE, and JavaEE were set up to pull versions from VERSION file to make that file a central location for the projects version number.
In JavaSE & JavaEE , the generateSources task reads the VERSION file and makes a BuildConfig.java file that contains the correct version.

After moving to maven central:

After adding the new gradle.properties file for sonatype, the generateSources got broken as it reads the version from gradle.properties instead of VERSION file.

The gradle setup should be updated to make all projects pull versions from VERSION file.

Reproduction Steps
  1. Update the version in VERSION file to any unique version (like 5.3.0_xyz for example)
  2. Run ./gradlew build
  3. Upload the JavaSE binary to maven central staging
Expected Behavior

The generated BuildConfig and uploaded library have the version that was set in VERSION file

Observed Behavior

The generated BuildConfig and uploaded library still use the old version that was set in gradle.properties

OS & Version Information
  • Android Version: n/a
  • SDL Android Version: 5.3
  • Testing Against: n/a

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugA defect in the library

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions