{ "id": "174591", "key": "TIMOB-27696", "fields": { "issuetype": { "id": "2", "description": "A new feature of the product, which has yet to be developed.", "name": "New Feature", "subtask": false }, "project": { "id": "10153", "key": "TIMOB", "name": "Titanium SDK/CLI", "projectCategory": { "id": "10100", "description": "Titanium and related SDKs used in application development", "name": "Client" } }, "fixVersions": [ { "id": "20033", "name": "Release 9.0.0", "archived": false, "released": true, "releaseDate": "2020-03-18" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2020-01-31T11:00:24.000+0000", "created": "2019-12-22T10:23:33.000+0000", "priority": { "name": "Low", "id": "4" }, "labels": [ "android", "build", "gradle", "properties", "settings" ], "versions": [], "issuelinks": [], "assignee": { "name": "jquick", "key": "jquick", "displayName": "Joshua Quick", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2020-01-31T11:00:24.000+0000", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "components": [ { "id": "10202", "name": "Android", "description": "Android Platform" } ], "description": "*Summary:*\r\nTitanium app developers would like the ability to set up their own \"gradle.properties\" file according to Google's documentation. We should add support for this and allow this file to override the properties defined by Titanium's build system.\r\nhttps://developer.android.com/studio/build#properties-files\r\n\r\n*Recommended Solution:*\r\nCopy the properties from the following project file...\r\n{code}\r\n./platform/android/gradle.properties\r\n{code}\r\n\r\nThese properties should be copied to the end of the Titanium generated \"gradle.properties\" file so that the app dev's properties can override the ones we set.", "attachment": [], "flagged": false, "summary": "Android: Add \"gradle.properties\" support to app builds", "creator": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "subtasks": [], "reporter": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "environment": null, "comment": { "comments": [ { "id": "453459", "author": { "name": "jquick", "key": "jquick", "displayName": "Joshua Quick", "active": true, "timeZone": "America/Los_Angeles" }, "body": "I don't think this is necessary.\r\n\r\nThe properties you set in the {{gradle.properties}} file are copied to the gradle {{project.properties}} dictionary in groovy. Which means you can set these properties in your {{build.gradle}} script instead. The below is an example on how to add properties via a Titanium project's {{./platform/android/build.gradle}} file.\r\n{code:groovy}\r\nproject.ext['android.useAndroidX'] = 'true'\r\nproject.ext['android.enableJetifier'] = 'true'\r\nproject.ext['api.key'] = 'MyKey'\r\n{code}\r\n\r\nNote that I think {{android.useAndroidX}} should be hardcoded to {{true}} once Titanium switches over to AndroidX.\r\n\r\nThe {{local.properties}} file is only for setting paths to the Android SDK, Android NDK, and CMake. The options are limited. What are you after in this file? (Or perhaps you know something I don't?)\r\n", "updateAuthor": { "name": "jquick", "key": "jquick", "displayName": "Joshua Quick", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2020-01-07T03:03:06.000+0000", "updated": "2020-01-07T04:04:25.000+0000" }, { "id": "453463", "author": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "body": "I was checking for parity with our native Android gradle project, but I think you're right and this can be done via the above as well. I will close the PR and you can resolve this ticket! \r\n\r\n*EDIT*: Agree with the local.properties, but the gradle.properties should really be able to be overwritten, since store a few other things there as well, which the above syntax looks a bit odd to. And there shouldn't be any downside of making this fully configurable.", "updateAuthor": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "created": "2020-01-07T12:12:07.000+0000", "updated": "2020-01-07T12:13:48.000+0000" }, { "id": "453485", "author": { "name": "jquick", "key": "jquick", "displayName": "Joshua Quick", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Yeah, I can see setting properties via \"gradle.properties\" being more natural. Especially when Google's official docs tell you to do so. I'll try to be open minding about this.\r\n\r\nFYI: Setting properties via {{project.ext}} is commonly done as well. For example...\r\nhttps://github.com/google/ExoPlayer/blob/release-v2/constants.gradle\r\nhttps://github.com/facebook/facebook-android-sdk/blob/master/constants.gradle\r\n", "updateAuthor": { "name": "jquick", "key": "jquick", "displayName": "Joshua Quick", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2020-01-07T20:01:36.000+0000", "updated": "2020-01-07T20:01:36.000+0000" }, { "id": "453662", "author": { "name": "jquick", "key": "jquick", "displayName": "Joshua Quick", "active": true, "timeZone": "America/Los_Angeles" }, "body": "PR (main): https://github.com/appcelerator/titanium_mobile/pull/11428", "updateAuthor": { "name": "jquick", "key": "jquick", "displayName": "Joshua Quick", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2020-01-11T06:19:25.000+0000", "updated": "2020-01-11T06:19:25.000+0000" }, { "id": "453968", "author": { "name": "smohammed", "key": "smohammed", "displayName": "Samir Mohammed", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Closing ticket, fix verified in SDK version {{9.0.0.v20200130113429}}\r\n\r\nTest and other information can be found at: \r\nhttps://github.com/appcelerator/titanium_mobile/pull/11428", "updateAuthor": { "name": "smohammed", "key": "smohammed", "displayName": "Samir Mohammed", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2020-01-31T11:00:13.000+0000", "updated": "2020-01-31T11:00:13.000+0000" } ], "maxResults": 6, "total": 6, "startAt": 0 } } }