Skip to content
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
6 changes: 6 additions & 0 deletions src/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -456,6 +456,9 @@ def make_package(args):
ap.add_argument('--meta-data', dest='meta_data', action='append',
help='Custom key=value to add in application metadata')

ap.add_argument('--resource', dest='resource', action='append',
help='Custom key=value to add in strings.xml resource file')

args = ap.parse_args()

if not args.dir and not args.private and not args.launcher:
Expand All @@ -470,6 +473,9 @@ def make_package(args):
if args.meta_data is None:
args.meta_data = []

if args.resource is None:
args.resource = []

if args.compile_pyo:
if PYTHON is None:
ap.error('To use --compile-pyo, you need Python 2.7.1 installed '
Expand Down
4 changes: 4 additions & 0 deletions src/templates/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,8 @@
<string name="public_version">{{ public_version }}</string>
{% endif %}
<string name="urlScheme">{{ url_scheme }}</string>
{% for m in args.resource %}
<string name="{{ m.split('=', 1)[0] }}">{{ m.split('=', 1)[-1] }}</string>
{% endfor %}

</resources>