mirror of
https://gitlab.com/fdroid/fdroidserver.git
synced 2024-11-19 21:30:10 +01:00
remove redundant imports and pointless code
This commit is contained in:
parent
95af082082
commit
0fbd04f1c2
@ -957,7 +957,6 @@ def make_v0(apps, apks, repodir, repodict, requestsdict, fdroid_signing_key_fing
|
|||||||
% repo_icon)
|
% repo_icon)
|
||||||
os.makedirs(os.path.dirname(iconfilename), exist_ok=True)
|
os.makedirs(os.path.dirname(iconfilename), exist_ok=True)
|
||||||
try:
|
try:
|
||||||
import qrcode
|
|
||||||
qrcode.make(common.config['repo_url']).save(iconfilename)
|
qrcode.make(common.config['repo_url']).save(iconfilename)
|
||||||
except Exception:
|
except Exception:
|
||||||
exampleicon = os.path.join(common.get_examples_dir(),
|
exampleicon = os.path.join(common.get_examples_dir(),
|
||||||
|
@ -66,7 +66,6 @@ def main():
|
|||||||
help=_("Do not prompt for Android SDK path, just fail"))
|
help=_("Do not prompt for Android SDK path, just fail"))
|
||||||
options = parser.parse_args()
|
options = parser.parse_args()
|
||||||
|
|
||||||
aapt = None
|
|
||||||
fdroiddir = os.getcwd()
|
fdroiddir = os.getcwd()
|
||||||
test_config = dict()
|
test_config = dict()
|
||||||
examplesdir = common.get_examples_dir()
|
examplesdir = common.get_examples_dir()
|
||||||
@ -227,8 +226,6 @@ def main():
|
|||||||
msg = '\n'
|
msg = '\n'
|
||||||
msg += _('Built repo based in "%s" with this config:') % fdroiddir
|
msg += _('Built repo based in "%s" with this config:') % fdroiddir
|
||||||
msg += '\n\n Android SDK:\t\t\t' + config['sdk_path']
|
msg += '\n\n Android SDK:\t\t\t' + config['sdk_path']
|
||||||
if aapt:
|
|
||||||
msg += '\n Android SDK Build Tools:\t' + os.path.dirname(aapt)
|
|
||||||
msg += '\n Android NDK r12b (optional):\t$ANDROID_NDK'
|
msg += '\n Android NDK r12b (optional):\t$ANDROID_NDK'
|
||||||
msg += '\n ' + _('Keystore for signing key:\t') + keystore
|
msg += '\n ' + _('Keystore for signing key:\t') + keystore
|
||||||
if repo_keyalias is not None:
|
if repo_keyalias is not None:
|
||||||
|
@ -890,10 +890,6 @@ def write_yaml(mf, app):
|
|||||||
_yaml_bools_plus_lists.extend(_yaml_bools_false)
|
_yaml_bools_plus_lists.extend(_yaml_bools_false)
|
||||||
_yaml_bools_plus_lists.extend([[x] for x in _yaml_bools_false])
|
_yaml_bools_plus_lists.extend([[x] for x in _yaml_bools_false])
|
||||||
|
|
||||||
def _class_as_dict_representer(dumper, data):
|
|
||||||
'''Creates a YAML representation of a App/Build instance'''
|
|
||||||
return dumper.represent_dict(data)
|
|
||||||
|
|
||||||
def _field_to_yaml(typ, value):
|
def _field_to_yaml(typ, value):
|
||||||
if typ is TYPE_STRING:
|
if typ is TYPE_STRING:
|
||||||
if value in _yaml_bools_plus_lists:
|
if value in _yaml_bools_plus_lists:
|
||||||
|
@ -2067,7 +2067,6 @@ def create_metadata_from_template(apk):
|
|||||||
template: field sort order, empty field value, formatting, etc.
|
template: field sort order, empty field value, formatting, etc.
|
||||||
'''
|
'''
|
||||||
|
|
||||||
import yaml
|
|
||||||
if os.path.exists('template.yml'):
|
if os.path.exists('template.yml'):
|
||||||
with open('template.yml') as f:
|
with open('template.yml') as f:
|
||||||
metatxt = f.read()
|
metatxt = f.read()
|
||||||
|
@ -7,7 +7,6 @@ import os
|
|||||||
import re
|
import re
|
||||||
import requests
|
import requests
|
||||||
import subprocess
|
import subprocess
|
||||||
import sys
|
|
||||||
|
|
||||||
|
|
||||||
projectbasedir = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
|
projectbasedir = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
|
||||||
|
Loading…
Reference in New Issue
Block a user