diff options
| author | David Pursehouse <dpursehouse@collab.net> | 2020-02-12 15:20:19 +0900 |
|---|---|---|
| committer | David Pursehouse <dpursehouse@collab.net> | 2020-02-12 06:36:40 +0000 |
| commit | 819827a42ddb364f98c3a1a7eae2536dc54bc4cc (patch) | |
| tree | fe6bdca5ff7e44d53595a6da76d2b56ea659eee1 /subcmds/stage.py | |
| parent | abdf7500612f1d115863ba8f026ddbea1e5a1f28 (diff) | |
| download | git-repo-819827a42ddb364f98c3a1a7eae2536dc54bc4cc.tar.gz | |
Fix blank line issues reported by flake8
- E301 expected 1 blank line
- E302 expected 2 blank lines
- E303 too many blank lines
- E305 expected 2 blank lines after class or function definition
- E306 expected 1 blank line before a nested definition
Fixed automatically with autopep8:
git ls-files | grep py$ | xargs autopep8 --in-place \
--select E301,E302,E303,E305,E306
Manually fix issues in project.py caused by misuse of block comments.
Change-Id: Iee840fcaff48aae504ddac9c3e76d2acd484f6a9
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/254599
Reviewed-by: Mike Frysinger <vapier@google.com>
Tested-by: David Pursehouse <dpursehouse@collab.net>
Diffstat (limited to 'subcmds/stage.py')
| -rw-r--r-- | subcmds/stage.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/subcmds/stage.py b/subcmds/stage.py index aeb49513..4dce5ce5 100644 --- a/subcmds/stage.py +++ b/subcmds/stage.py | |||
| @@ -21,6 +21,7 @@ from color import Coloring | |||
| 21 | from command import InteractiveCommand | 21 | from command import InteractiveCommand |
| 22 | from git_command import GitCommand | 22 | from git_command import GitCommand |
| 23 | 23 | ||
| 24 | |||
| 24 | class _ProjectList(Coloring): | 25 | class _ProjectList(Coloring): |
| 25 | def __init__(self, gc): | 26 | def __init__(self, gc): |
| 26 | Coloring.__init__(self, gc, 'interactive') | 27 | Coloring.__init__(self, gc, 'interactive') |
| @@ -28,6 +29,7 @@ class _ProjectList(Coloring): | |||
| 28 | self.header = self.printer('header', attr='bold') | 29 | self.header = self.printer('header', attr='bold') |
| 29 | self.help = self.printer('help', fg='red', attr='bold') | 30 | self.help = self.printer('help', fg='red', attr='bold') |
| 30 | 31 | ||
| 32 | |||
| 31 | class Stage(InteractiveCommand): | 33 | class Stage(InteractiveCommand): |
| 32 | common = True | 34 | common = True |
| 33 | helpSummary = "Stage file(s) for commit" | 35 | helpSummary = "Stage file(s) for commit" |
| @@ -105,6 +107,7 @@ The '%prog' command stages files to prepare the next commit. | |||
| 105 | continue | 107 | continue |
| 106 | print('Bye.') | 108 | print('Bye.') |
| 107 | 109 | ||
| 110 | |||
| 108 | def _AddI(project): | 111 | def _AddI(project): |
| 109 | p = GitCommand(project, ['add', '--interactive'], bare=False) | 112 | p = GitCommand(project, ['add', '--interactive'], bare=False) |
| 110 | p.Wait() | 113 | p.Wait() |
