-
Notifications
You must be signed in to change notification settings - Fork 658
Use termux-shared for getting constants like TERMUX_PREFIX #470
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
@agnostic-apollo could you briefly list what other improvements that should/could be done with termux-shared? I suppose all logging should be moved over to termux-shared's logger functions for example |
|
Ah, so you finally got around to this ;)
This should hopefully be enough for now, I'll let you know if I think of other stuff. Good luck. Do let me know if any further help or clarification is required. |
942260d to
9fb33d7
Compare
This allows us to remove all hardcoded /data/data/com.termux paths, and makes future maintenance easier.
Instead of hardcoding the prefix path.
Instead of hardcoding them.
As part of adaption for the termux-shared library.
But still keep shrinkResources and obfuscation disabled for testing reproducible builds and maintaining stacktraces of crashes.
To have them easily accessible in only one place.
The versionName will now follow semantic version "2.0.0" spec in the format major.minor.patch(-prerelease)(+buildmetadata). This will make versioning the prerelease and github debug builds versions easier and follow as spec. The @termux devs should make sure that when bumping versionName in build.gradle file and when creating a tag for new releases on github that they include the patch number as well, like v0.1.0 instead of just v0.1. The build.gradle file and attach_debug_apks_to_release workflow will now validate the version as well and the build/attachment will fail if versionName does not follow the spec. https://semver.org/spec/v2.0.0.html APKs released on github for debug build workflows and releases are now referred as Github releases as per termux/termux-app@7b10a35f and termux/termux-app@94e01d68, so APK filenames have been modified to include github in the filename. The APKs are still debuggable, so that tag remains too. For github workflows the apk filename format will be termux-api_<current_version>+<last_commit_hash>-github-debug_<arch>.apk, like termux-api_v0.1.0+xxxxxxxx-github-debug_arm64-v8a.apk and for github releases it will be termux-api_<release_version>-github-debug_<arch>.apk, like termux-api_v0.1-github-debug_arm64-v8a.apk. The last_commit_hash will be the first 8 characters of the commit hash. The <last_commit_hash>-github-debug will act as buildmetadata and will not affect versioning precedence. For github workflows triggered by push and pull_request triggers, <current_version>+<last_commit_hash> will be used as new versionName, like v0.1.0+xxxxxxxx. This will make tracking which build a user is using easier and help in resolving issues as well. The app/build.gradle now also supports following TERMUX_API_ scoped environmental variables and RELEASE_TAG variable will not be used anymore since it may conflict with possibly other variables used by users. - TERMUX_API_APP_VERSION_NAME will be used as versionName if its set. - TERMUX_API_APK_VERSION_TAG will be used as termux-api_<TERMUX_API_APK_VERSION_TAG>.apk if its set.
androidx.biometric:biometric:1.2.0-alpha04 is available as well, but it requires compileSdkVersion 31, which we cannot use.
9fb33d7 to
5ca50e0
Compare
|
Merging this now to make testing of the other PRs easier, will come back and look at the rest of the points later |
This removes all hardcoded /data/data/com.termux/files paths.