Joined July 2012
·

benjaoming

Copenhagen, Denmark
·
·

Posted to A better git log over 1 year ago

Thanks man! For copy-pasting change-logs, here's an ascii friendly version:

git log --graph --pretty=format:'%h -%d %s (%cr) <%an>' --abbrev-commit

...and the alias:

git config --global alias.lg-ascii "log --graph --pretty=format:'%h -%d %s (%cr) <%an>' --abbrev-commit"
Posted to Better Way To Initialize Django Forms over 1 year ago

That's not exactly DRY, since there is a boolean test twice on request.POST.
Python is about being explicit and easy to read, not about being short and obscure - that sort of stuff is what Perl handles :) Therefore, I would prefer the first code block.
For more, please refer to the Zen of Python - type "import this" in your python shell.

Achievements
82 Karma
0 Total ProTip Views