Skip to content
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

✨ Adds p4a --numeric-version support #1126

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions buildozer/default.spec
Original file line number Diff line number Diff line change
Expand Up @@ -221,6 +221,10 @@ fullscreen = 0
# (str) The Android arch to build for, choices: armeabi-v7a, arm64-v8a, x86, x86_64
android.arch = armeabi-v7a

# (int) overrides automatic versionCode computation (used in build.gradle)
# this is not the same as app version and should only be edited if you know what you're doing
# android.numeric_version = 1
AndreMiras marked this conversation as resolved.
Show resolved Hide resolved

#
# Python for android (p4a) specific
#
Expand Down
5 changes: 5 additions & 0 deletions buildozer/targets/android.py
Original file line number Diff line number Diff line change
Expand Up @@ -1143,6 +1143,11 @@ def build_package(self):
if launch_mode:
build_cmd += [("--activity-launch-mode", launch_mode)]

# numeric version
numeric_version = config.getdefault('app', 'android.numeric_version')
if numeric_version:
build_cmd += [("--numeric-version", numeric_version)]

# build only in debug right now.
if self.build_mode == 'debug':
build_cmd += [("debug", )]
Expand Down