From 50b7dc08c4385b07dbafc0c39cd16f22c152397e Mon Sep 17 00:00:00 2001 From: Jonas Thiem Date: Thu, 7 Feb 2019 05:59:57 +0100 Subject: [PATCH] Rename misguided shadowing --blacklist to --blacklist-requirements --- doc/source/buildoptions.rst | 8 ++++---- pythonforandroid/toolchain.py | 6 +++--- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/doc/source/buildoptions.rst b/doc/source/buildoptions.rst index 2cfc33a42c..4a078e6846 100644 --- a/doc/source/buildoptions.rst +++ b/doc/source/buildoptions.rst @@ -245,8 +245,8 @@ options (this list may not be exhaustive): - ``--resource``: A key=value pair to add in the string.xml resource file. -Blacklist (APK size optimization) ---------------------------------- +Requirements blacklist (APK size optimization) +---------------------------------------------- To optimize the size of the `.apk` file that p4a builds for you, you can **blacklist** certain core components. Per default, p4a @@ -254,9 +254,9 @@ will add python *with batteries included* as would be expected on desktop, including openssl, sqlite3 and other components you may not use. -To blacklist an item, specify the ``--blacklist`` option:: +To blacklist an item, specify the ``--blacklist-requirements`` option:: - p4a apk ... --blacklist=sqlite3 + p4a apk ... --blacklist-requirements=sqlite3 At the moment, the following core components can be blacklisted (if you don't want to use them) to decrease APK size: diff --git a/pythonforandroid/toolchain.py b/pythonforandroid/toolchain.py index cffe3e5afd..153bba1523 100644 --- a/pythonforandroid/toolchain.py +++ b/pythonforandroid/toolchain.py @@ -171,7 +171,7 @@ def build_dist_from_args(ctx, dist, args): """Parses out any bootstrap related arguments, and uses them to build a dist.""" bs = Bootstrap.get_bootstrap(args.bootstrap, ctx) - blacklist = getattr(args, "blacklist", "").split(",") + blacklist = getattr(args, "blacklist_requirements", "").split(",") if len(blacklist) == 1 and blacklist[0] == "": blacklist = [] build_order, python_modules, bs = ( @@ -310,10 +310,10 @@ def __init__(self): default='') generic_parser.add_argument( - '--blacklist', + '--blacklist-requirements', help=('Blacklist an internal recipe from use. Allows ' 'disabling Python 3 core modules to save size'), - dest="blacklist", + dest="blacklist_requirements", default='') generic_parser.add_argument(