diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/git/commit.py | 3 | ||||
-rw-r--r-- | lib/git/tree.py | 2 |
2 files changed, 3 insertions, 2 deletions
diff --git a/lib/git/commit.py b/lib/git/commit.py index 2bd78b75..ba7a7102 100644 --- a/lib/git/commit.py +++ b/lib/git/commit.py @@ -114,6 +114,7 @@ class Commit(LazyMixin): def find_all(cls, repo, ref, path='', **kwargs): """ Find all commits matching the given criteria. + ``repo`` is the Repo @@ -151,7 +152,7 @@ class Commit(LazyMixin): Returns git.Commit[] """ - lines = [l for l in text.splitlines() if l.strip()] + lines = [l for l in text.splitlines() if l.strip('\r\n')] commits = [] diff --git a/lib/git/tree.py b/lib/git/tree.py index dea10908..cfb0881c 100644 --- a/lib/git/tree.py +++ b/lib/git/tree.py @@ -45,7 +45,7 @@ class Tree(LazyMixin): ``git.Blob`` or ``git.Tree`` """ try: - mode, typ, id, name = text.expandtabs(1).split(" ", 4) + mode, typ, id, name = text.expandtabs(1).split(" ", 3) except: return None |