Commit 7b1b1ba4 authored by Mike Frysinger's avatar Mike Frysinger Committed by Commit Bot

grit: strip trailing blank lines

Newer pylint warns when files have trailing blank lines.  Trim them.

Bug: 866772
Change-Id: Iacfd1dcb0eb16d33aa5cf382aecb5b1dd4e7efa7
Reviewed-on: https://chromium-review.googlesource.com/1147717
Commit-Queue: Nico Weber <thakis@chromium.org>
Reviewed-by: default avatarNico Weber <thakis@chromium.org>
Cr-Commit-Position: refs/heads/master@{#577512}
parent 897fb666
......@@ -13,4 +13,3 @@ import grit.grit_runner
if __name__ == '__main__':
grit.grit_runner.Main(sys.argv[1:])
......@@ -483,4 +483,3 @@ class MessageClique(object):
language, transl_msg.GetId())
self.clique[language] = transl_msg
......@@ -500,4 +500,3 @@ class Translation(BaseMessage):
Returns a copy of this Translation.
"""
return Translation(None, clone_from=self)
......@@ -82,4 +82,3 @@ class RegexpGatherer(skeleton_gatherer.SkeletonGatherer):
if self.single_message_:
self.skeleton_.append(self.uberclique.MakeClique(self.single_message_))
......@@ -742,4 +742,3 @@ class TrHtml(interface.GathererBase):
continue
new_skel.append(chunk)
self.skeleton_ = new_skel
......@@ -31,4 +31,3 @@ class TxtUnittest(unittest.TestCase):
if __name__ == '__main__':
unittest.main()
......@@ -621,4 +621,3 @@ class ContentNode(Node):
'''Convenience baseclass for nodes that can have content.'''
def _ContentType(self):
return self._CONTENT_TYPE_MIXED
......@@ -255,4 +255,3 @@ class NodeUnittest(unittest.TestCase):
if __name__ == '__main__':
unittest.main()
......@@ -31,4 +31,3 @@ class WindowsFilenameUnittest(unittest.TestCase):
if __name__ == '__main__':
unittest.main()
......@@ -116,4 +116,3 @@ class EmitNode(base.ContentNode):
def GetEmitType(self):
'''Returns the emit_type for this node. Default is 'append'.'''
return self.attrs['emit_type']
......@@ -58,4 +58,3 @@ def ElementToClass(name, typeattr):
if name not in _ELEMENT_TO_CLASS:
raise exception.UnknownElement()
return _ELEMENT_TO_CLASS[name]
......@@ -356,4 +356,3 @@ class StructureNode(base.Node):
assert hasattr(self, 'gatherer')
if self.ExpandVariables():
self.gatherer.SubstituteMessages(substituter)
......@@ -39,4 +39,3 @@ class SkeletonNode(base.Node):
def GetInputPath(self):
return self.attrs['file']
......@@ -125,4 +125,3 @@ def PseudoMessage(message):
transl.AppendText(PseudoString(part))
return transl
......@@ -90,4 +90,3 @@ def GenerateDuplicateShortcutsWarnings(uberclique, tc_project):
for group in groups.values():
warnings += group.GenerateWarnings(tc_project)
return warnings
......@@ -77,4 +77,3 @@ END'''), 'IDD_SIDEBAR_RSS_PANEL_PROPPAGE')
if __name__ == '__main__':
unittest.main()
......@@ -476,4 +476,3 @@ OPTIONS may be any of the following:
return value == 'true'
else:
return True
......@@ -32,4 +32,3 @@ class CountMessage(interface.Tool):
count += 1
print "There are %d occurrences of message %s." % (count, id)
......@@ -76,4 +76,3 @@ to being one message for the whole menu.'''
with util.WrapOutputStream(open(output_file, 'w')) as f:
transl2tc.TranslationToTc.WriteTranslations(f, translations)
......@@ -27,6 +27,3 @@ class PostProcessor(object):
The root node of the processed GRD tree.
'''
raise NotImplementedError()
......@@ -60,4 +60,3 @@ class DummyPostProcessor(grit.tool.postprocess_interface.PostProcessor):
if __name__ == '__main__':
unittest.main()
......@@ -23,6 +23,3 @@ class PreProcessor(object):
The processed text.
'''
raise NotImplementedError()
......@@ -46,4 +46,3 @@ END
if __name__ == '__main__':
unittest.main()
......@@ -406,4 +406,3 @@ C preprocessor on the .rc file or manually edit it before using this tool.
except:
print 'Exception processing message with text "%s"' % text
raise
......@@ -134,4 +134,3 @@ The installation will not proceed if you choose to cancel.
if __name__ == '__main__':
unittest.main()
......@@ -21,4 +21,3 @@ hence the name :)
print 'Options: %s' % repr(global_options)
print 'Arguments: %s' % repr(my_arguments)
return 0
......@@ -249,4 +249,3 @@ Bulk Translation Upload tool.
output_file.write(' ')
output_file.write(text)
output_file.write('\n')
......@@ -116,4 +116,3 @@ class TestClassNoBase(object):
if __name__ == '__main__':
unittest.main()
......@@ -138,4 +138,3 @@ def Parse(xtb_file, callback_function, defs=None, debug=False,
xml.sax.parse(xtb_file, handler)
assert handler.language != ''
return handler.language
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment