Commits

Roger Haase  committed 96742f6

improve coding_std.py by replacing tabs with 4 spaces

  • Participants
  • Parent commits 2d20593

Comments (0)

Files changed (1)

File contrib/pep8/coding_std.py

 
     with open(filename, "wb") as f:
         for line in lines:
+            length_line = len(line)
+            line = line.replace('\t', '    ')
+            if len(line) != length_line:
+                logger.log(u"%s was changed to replace tab characters with 4 spaces" % filename)
             pep8_line = line.rstrip() + line_end
             f.write(pep8_line)
             # if line was changed, issue warning once for each type of change