Python-style: pep8 fixes
This commit is contained in:
parent
22c0ee5dbb
commit
c694792e4f
@ -39,9 +39,11 @@ _ = gettext.translation("python",
|
|||||||
libcalamares.globalstorage.gettext_languages(),
|
libcalamares.globalstorage.gettext_languages(),
|
||||||
fallback=True).gettext
|
fallback=True).gettext
|
||||||
|
|
||||||
|
|
||||||
def pretty_name():
|
def pretty_name():
|
||||||
return _("Dummy python job.")
|
return _("Dummy python job.")
|
||||||
|
|
||||||
|
|
||||||
def run():
|
def run():
|
||||||
"""Dummy python job."""
|
"""Dummy python job."""
|
||||||
os.system("/bin/sh -c \"touch ~/calamares-dummypython\"")
|
os.system("/bin/sh -c \"touch ~/calamares-dummypython\"")
|
||||||
@ -81,15 +83,15 @@ def run():
|
|||||||
sleep(1)
|
sleep(1)
|
||||||
|
|
||||||
try:
|
try:
|
||||||
l = list(libcalamares.job.configuration["a_list"])
|
configlist = list(libcalamares.job.configuration["a_list"])
|
||||||
except KeyError:
|
except KeyError:
|
||||||
l = ["no list"]
|
configlist = ["no list"]
|
||||||
|
|
||||||
c = 1
|
c = 1
|
||||||
for k in l:
|
for k in configlist:
|
||||||
libcalamares.utils.debug(_("Dummy python step {}").format(str(k)))
|
libcalamares.utils.debug(_("Dummy python step {}").format(str(k)))
|
||||||
sleep(1)
|
sleep(1)
|
||||||
libcalamares.job.setprogress( c * 1.0 / len(l) )
|
libcalamares.job.setprogress(c * 1.0 / len(configlist))
|
||||||
c += 1
|
c += 1
|
||||||
|
|
||||||
sleep(3)
|
sleep(3)
|
||||||
|
@ -30,9 +30,11 @@ _ = gettext.translation("python",
|
|||||||
libcalamares.globalstorage.gettext_languages(),
|
libcalamares.globalstorage.gettext_languages(),
|
||||||
fallback=True).gettext
|
fallback=True).gettext
|
||||||
|
|
||||||
|
|
||||||
def pretty_name():
|
def pretty_name():
|
||||||
return _("Generate machine-id.")
|
return _("Generate machine-id.")
|
||||||
|
|
||||||
|
|
||||||
def run():
|
def run():
|
||||||
"""
|
"""
|
||||||
Generate machine-id using dbus and systemd.
|
Generate machine-id using dbus and systemd.
|
||||||
|
Loading…
Reference in New Issue
Block a user