diff options
author | Antoine Musso <hashar@free.fr> | 2014-11-16 20:56:53 +0100 |
---|---|---|
committer | Antoine Musso <hashar@free.fr> | 2014-11-16 21:05:53 +0100 |
commit | 614907b7445e2ed8584c1c37df7e466e3b56170f (patch) | |
tree | 4b6e09110cd356799e9fa0f188fae55e5fa81fca /git/repo/fun.py | |
parent | be34ec23c48d6d5d8fd2ef4491981f6fb4bab8e6 (diff) | |
download | gitpython-614907b7445e2ed8584c1c37df7e466e3b56170f.tar.gz |
pep8 linting (whitespace before/after)
E201 whitespace after '('
E202 whitespace before ')'
E203 whitespace before ':'
E225 missing whitespace around operator
E226 missing whitespace around arithmetic operator
E227 missing whitespace around bitwise or shift operator
E228 missing whitespace around modulo operator
E231 missing whitespace after ','
E241 multiple spaces after ','
E251 unexpected spaces around keyword / parameter equals
Diffstat (limited to 'git/repo/fun.py')
-rw-r--r-- | git/repo/fun.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/git/repo/fun.py b/git/repo/fun.py index 15c5762b..4cdaf3f4 100644 --- a/git/repo/fun.py +++ b/git/repo/fun.py @@ -182,7 +182,7 @@ def rev_parse(repo, rev): end = rev.find('}', start) if end == -1: raise ValueError("Missing closing brace to define type in %s" % rev) - output_type = rev[start+1:end] # exclude brace + output_type = rev[start + 1:end] # exclude brace # handle type if output_type == 'commit': @@ -206,7 +206,7 @@ def rev_parse(repo, rev): revlog_index = None try: # transform reversed index into the format of our revlog - revlog_index = -(int(output_type)+1) + revlog_index = -(int(output_type) + 1) except ValueError: # TODO: Try to parse the other date options, using parse_date # maybe @@ -232,7 +232,7 @@ def rev_parse(repo, rev): raise ValueError("Could not accomodate requested object type %r, got %s" % (output_type, obj.type)) # END verify ouput type - start = end+1 # skip brace + start = end + 1 # skip brace parsed_to = start continue # END parse type @@ -270,7 +270,7 @@ def rev_parse(repo, rev): obj = to_commit(obj) # must be n'th parent if num: - obj = obj.parents[num-1] + obj = obj.parents[num - 1] elif token == ":": if obj.type != "tree": obj = obj.tree |