mirror of
https://git.yoctoproject.org/poky
synced 2026-06-02 13:29:49 +00:00
meta/classes: Various python whitespace fixes
It was pointed out we have a number of weird indentations in the python functions. This patch cleans up 3, 7 and other weird indentations for the core bbclass files. It also fixes some wierd (odd) shell function indentation which my searches picked up. (From OE-Core rev: 8385d6d74624000d68814f4e3266d47bc8885942) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
+13
-13
@@ -174,7 +174,7 @@ def sstate_installpkg(ss, d):
|
||||
sstatepkg = d.getVar('SSTATE_PKG', True) + '_' + ss['name'] + ".tgz"
|
||||
|
||||
if not os.path.exists(sstatepkg):
|
||||
pstaging_fetch(sstatefetch, sstatepkg, d)
|
||||
pstaging_fetch(sstatefetch, sstatepkg, d)
|
||||
|
||||
if not os.path.isfile(sstatepkg):
|
||||
bb.note("Staging package %s does not exist" % sstatepkg)
|
||||
@@ -259,10 +259,10 @@ def sstate_clean_manifest(manifest, d):
|
||||
# so we ignore errors here.
|
||||
try:
|
||||
if entry.endswith("/"):
|
||||
if os.path.islink(entry[:-1]):
|
||||
os.remove(entry[:-1])
|
||||
elif os.path.exists(entry) and len(os.listdir(entry)) == 0:
|
||||
os.rmdir(entry[:-1])
|
||||
if os.path.islink(entry[:-1]):
|
||||
os.remove(entry[:-1])
|
||||
elif os.path.exists(entry) and len(os.listdir(entry)) == 0:
|
||||
os.rmdir(entry[:-1])
|
||||
else:
|
||||
oe.path.remove(entry)
|
||||
except OSError:
|
||||
@@ -314,14 +314,14 @@ python sstate_cleanall() {
|
||||
|
||||
for manifest in (os.listdir(manifest_dir)):
|
||||
if fnmatch.fnmatch(manifest, manifest_pattern):
|
||||
name = manifest.replace(manifest_pattern[:-1], "")
|
||||
namemap = d.getVar('SSTATETASKNAMES', True).split()
|
||||
tasks = d.getVar('SSTATETASKS', True).split()
|
||||
if name not in namemap:
|
||||
continue
|
||||
taskname = tasks[namemap.index(name)]
|
||||
shared_state = sstate_state_fromvars(d, taskname[3:])
|
||||
sstate_clean(shared_state, d)
|
||||
name = manifest.replace(manifest_pattern[:-1], "")
|
||||
namemap = d.getVar('SSTATETASKNAMES', True).split()
|
||||
tasks = d.getVar('SSTATETASKS', True).split()
|
||||
if name not in namemap:
|
||||
continue
|
||||
taskname = tasks[namemap.index(name)]
|
||||
shared_state = sstate_state_fromvars(d, taskname[3:])
|
||||
sstate_clean(shared_state, d)
|
||||
}
|
||||
|
||||
def sstate_hardcode_path(d):
|
||||
|
||||
Reference in New Issue
Block a user