diff options
| author | Sankar Tanguturi <stanguturi@stanguturi-rhel> | 2016-03-11 11:29:15 -0800 | 
|---|---|---|
| committer | Sankar Tanguturi <stanguturi@stanguturi-rhel> | 2016-03-11 11:29:15 -0800 | 
| commit | a3fd7441f8ea4d25e96b9bc0eca7cbb6164a4691 (patch) | |
| tree | 74a6ebbe7c91c30467577eb231fab8c5f188b93c /tools/hacking.py | |
| parent | a6e0922a4d34ede6df000dd8fc4bb3531218d69f (diff) | |
| parent | 41470d29f5888baf7ec78e170cc0d6d981dcf63e (diff) | |
| download | vyos-cloud-init-a3fd7441f8ea4d25e96b9bc0eca7cbb6164a4691.tar.gz vyos-cloud-init-a3fd7441f8ea4d25e96b9bc0eca7cbb6164a4691.zip | |
- Executed 'bzr merge' and resolved all the conflicts.
- Now my branch is identical to trunk.dist
Diffstat (limited to 'tools/hacking.py')
| -rwxr-xr-x | tools/hacking.py | 16 | 
1 files changed, 8 insertions, 8 deletions
| diff --git a/tools/hacking.py b/tools/hacking.py index 3175df38..716c1154 100755 --- a/tools/hacking.py +++ b/tools/hacking.py @@ -47,10 +47,10 @@ def import_normalize(line):      # handle "from x import y as z" to "import x.y as z"      split_line = line.split()      if (line.startswith("from ") and "," not in line and -           split_line[2] == "import" and split_line[3] != "*" and -           split_line[1] != "__future__" and -           (len(split_line) == 4 or -           (len(split_line) == 6 and split_line[4] == "as"))): +       split_line[2] == "import" and split_line[3] != "*" and +       split_line[1] != "__future__" and +       (len(split_line) == 4 or (len(split_line) == 6 and +                                 split_line[4] == "as"))):          return "import %s.%s" % (split_line[1], split_line[3])      else:          return line @@ -74,7 +74,7 @@ def cloud_import_alphabetical(physical_line, line_number, lines):              split_line[0] == "import" and split_previous[0] == "import"):          if split_line[1] < split_previous[1]:              return (0, "N306: imports not in alphabetical order (%s, %s)" -                % (split_previous[1], split_line[1])) +                    % (split_previous[1], split_line[1]))  def cloud_docstring_start_space(physical_line): @@ -87,8 +87,8 @@ def cloud_docstring_start_space(physical_line):      pos = max([physical_line.find(i) for i in DOCSTRING_TRIPLE])  # start      if (pos != -1 and len(physical_line) > pos + 1):          if (physical_line[pos + 3] == ' '): -            return (pos, "N401: one line docstring should not start with" -                " a space") +            return (pos, +                    "N401: one line docstring should not start with a space")  def cloud_todo_format(physical_line): @@ -167,4 +167,4 @@ if __name__ == "__main__":      finally:          if len(_missingImport) > 0:              print >> sys.stderr, ("%i imports missing in this test environment" -                    % len(_missingImport)) +                                  % len(_missingImport)) | 
