Guest User

Untitled

a guest
Jul 12th, 2018
402
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.80 KB | None | 0 0
  1. from git import Repo, Commit
  2.  
  3. repo = Repo.clone_from('git@github.com:smappi/smappi.git', '/tmp/xxx')
  4. # repo = Repo('/tmp/xxx')
  5. commits = list(repo.iter_commits('master', max_count=5))
  6. [{'name': str(c.author), 'email': c.author.email, 'msg': c.message} for c in commits]
  7.  
  8. >>>
  9. [{'name': 'Mikhail Andreev (adw0rd)',
  10. 'email': 'x11org@gmail.com',
  11. 'msg': '0.5.2\n'},
  12. {'name': 'Mikhail Andreev (adw0rd)',
  13. 'email': 'x11org@gmail.com',
  14. 'msg': 'Support undefined in doctetst (cause undefined is object)\n'},
  15. {'name': 'Mikhail Andreev (adw0rd)',
  16. 'email': 'x11org@gmail.com',
  17. 'msg': '0.5.1\n'},
  18. {'name': 'Mikhail Andreev (adw0rd)',
  19. 'email': 'x11org@gmail.com',
  20. 'msg': 'Bugfixed adaptResultByMask when object is undefined\n'},
  21. {'name': 'Mikhail Andreev (adw0rd)',
  22. 'email': 'x11org@gmail.com',
  23. 'msg': '0.5.0\n'}]
Add Comment
Please, Sign In to add comment