# HG changeset patch # User Michal Kvasnica # Date 1130198371 25200 # Node ID 65cbe22b03fadb8c19e45a5a4ebb3853fa623b09 # Parent c22da894e4cc5f4181d57cabe88bdc6312c3bfe3 allow 'hg out' / 'hg in' to show newest commit first diff -r c22da894e4cc -r 65cbe22b03fa mercurial/commands.py --- a/mercurial/commands.py Mon Oct 24 16:54:07 2005 -0700 +++ b/mercurial/commands.py Mon Oct 24 16:59:31 2005 -0700 @@ -1388,6 +1388,8 @@ if not o: return o = other.newer(o) + if opts['newest_first']: + o.reverse() for n in o: parents = [p for p in other.changelog.parents(n) if p != nullid] if opts['no_merges'] and len(parents) == 2: @@ -1551,6 +1553,8 @@ other = hg.repository(ui, dest) o = repo.findoutgoing(other) o = repo.newer(o) + if opts['newest_first']: + o.reverse() for n in o: parents = [p for p in repo.changelog.parents(n) if p != nullid] if opts['no_merges'] and len(parents) == 2: @@ -2254,8 +2258,9 @@ "hg import [-f] [-p NUM] [-b BASE] PATCH..."), "incoming|in": (incoming, [('M', 'no-merges', None, _("do not show merges")), - ('p', 'patch', None, _('show patch'))], - _('hg incoming [-p] [SOURCE]')), + ('p', 'patch', None, _('show patch')), + ('n', 'newest-first', None, _('show newest record first'))], + _('hg incoming [-p] [-n] [-M] [SOURCE]')), "^init": (init, [], _('hg init [DEST]')), "locate": (locate, @@ -2279,8 +2284,9 @@ "manifest": (manifest, [], _('hg manifest [REV]')), "outgoing|out": (outgoing, [('M', 'no-merges', None, _("do not show merges")), - ('p', 'patch', None, _('show patch'))], - _('hg outgoing [-p] [DEST]')), + ('p', 'patch', None, _('show patch')), + ('n', 'newest-first', None, _('show newest record first'))], + _('hg outgoing [-p] [-n] [-M] [DEST]')), "parents": (parents, [], _('hg parents [REV]')), "paths": (paths, [], _('hg paths [NAME]')), "^pull":