From eb1273f5ea00af7712fe03b5042f9c845b34fcf3 Mon Sep 17 00:00:00 2001 From: Mathew Odden Date: Fri, 2 May 2014 00:43:17 -0500 Subject: [PATCH] Fix PEP8 violations Fixes a couple pep8 issues in the bash8.py script and some files from the cookiecutter template. Change-Id: Iaa67e513b6f02cfdb97d0b87ca0f29db1ef51b29 --- bash8/__init__.py | 2 +- bash8/bash8.py | 2 ++ bash8/tests/__init__.py | 2 +- bash8/tests/base.py | 2 +- bash8/tests/test_bash8.py | 2 +- setup.py | 2 +- 6 files changed, 7 insertions(+), 5 deletions(-) diff --git a/bash8/__init__.py b/bash8/__init__.py index 989980b..d2fd383 100644 --- a/bash8/__init__.py +++ b/bash8/__init__.py @@ -16,4 +16,4 @@ import pbr.version __version__ = pbr.version.VersionInfo( - 'bash8').version_string() \ No newline at end of file + 'bash8').version_string() diff --git a/bash8/bash8.py b/bash8/bash8.py index 3abf87b..fbaf78e 100755 --- a/bash8/bash8.py +++ b/bash8/bash8.py @@ -102,6 +102,7 @@ def check_indents(line): if (len(m.group('indent')) % 4) != 0: print_error('E003: Indent not multiple of 4', line) + def check_function_decl(line): failed = False if line.startswith("function"): @@ -189,6 +190,7 @@ def check_files(files, verbose): prev_line = logical_line prev_lineno = fileinput.filelineno() + def get_options(): parser = argparse.ArgumentParser( description='A bash script style checker') diff --git a/bash8/tests/__init__.py b/bash8/tests/__init__.py index f88664e..19f5e72 100644 --- a/bash8/tests/__init__.py +++ b/bash8/tests/__init__.py @@ -10,4 +10,4 @@ # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the # License for the specific language governing permissions and limitations -# under the License. \ No newline at end of file +# under the License. diff --git a/bash8/tests/base.py b/bash8/tests/base.py index 3bf12a8..6e93268 100644 --- a/bash8/tests/base.py +++ b/bash8/tests/base.py @@ -50,4 +50,4 @@ class TestCase(testtools.TestCase): stderr = self.useFixture(fixtures.StringStream('stderr')).stream self.useFixture(fixtures.MonkeyPatch('sys.stderr', stderr)) - self.log_fixture = self.useFixture(fixtures.FakeLogger()) \ No newline at end of file + self.log_fixture = self.useFixture(fixtures.FakeLogger()) diff --git a/bash8/tests/test_bash8.py b/bash8/tests/test_bash8.py index 515c5af..349a6dc 100644 --- a/bash8/tests/test_bash8.py +++ b/bash8/tests/test_bash8.py @@ -25,4 +25,4 @@ from bash8.tests import base class TestBash8(base.TestCase): def test_something(self): - pass \ No newline at end of file + pass diff --git a/setup.py b/setup.py index 7eeb36b..70c2b3f 100755 --- a/setup.py +++ b/setup.py @@ -19,4 +19,4 @@ import setuptools setuptools.setup( setup_requires=['pbr'], - pbr=True) \ No newline at end of file + pbr=True)