releasetools: Make scripts pylint clean.
Clean up the following scripts. blockimgdiff.py common.py edify_generator.py img_from_target_files.py ota_from_target_files.py Seems we don't have a way to force pylint-ing the scripts using per-directory pylintrc files (and we don't have pylint tool in AOSP repo), per https://android.googlesource.com/platform/tools/repohooks/#todo_limitations. Test: `m dist` Test: pylint --rcfile=pylintrc <script.py> Change-Id: Ia6fd1ddc86f4d84c68e500f225d4a89d0fea8ec7
This commit is contained in:
@@ -132,8 +132,8 @@ class EdifyGenerator(object):
|
||||
self.script.append(
|
||||
('(!less_than_int(%s, getprop("ro.build.date.utc"))) || '
|
||||
'abort("E%d: Can\'t install this package (%s) over newer '
|
||||
'build (" + getprop("ro.build.date") + ").");') % (timestamp,
|
||||
common.ErrorCode.OLDER_BUILD, timestamp_text))
|
||||
'build (" + getprop("ro.build.date") + ").");') % (
|
||||
timestamp, common.ErrorCode.OLDER_BUILD, timestamp_text))
|
||||
|
||||
def AssertDevice(self, device):
|
||||
"""Assert that the device identifier is the given string."""
|
||||
@@ -260,8 +260,8 @@ class EdifyGenerator(object):
|
||||
cmd.append(',\0%s,\0package_extract_file("%s")' % patchpairs[i:i+2])
|
||||
cmd.append(') ||\n abort("E%d: Failed to apply patch to %s");' % (
|
||||
common.ErrorCode.APPLY_PATCH_FAILURE, srcfile))
|
||||
cmd = "".join(cmd)
|
||||
self.script.append(self.WordWrap(cmd))
|
||||
cmd_str = "".join(cmd)
|
||||
self.script.append(self.WordWrap(cmd_str))
|
||||
|
||||
def WriteRawImage(self, mount_point, fn, mapfn=None):
|
||||
"""Write the given package file into the partition for the given
|
||||
|
Reference in New Issue
Block a user