Mercurial > evolve
diff hgext3rd/topic/stack.py @ 4655:bb0a5beb0ad8
stack: remove unnecessary prefix from stack output with non-default --template
"index" template keyword already exists (the current iteration of the loop), so
"stack_index" it is. It follows the same convention as other template keywords,
such as "files_added", "line_number", etc.
author | Anton Shestakov <av6@dwimlabs.net> |
---|---|
date | Fri, 17 May 2019 17:42:06 +0800 |
parents | 0d05dcb8dd37 |
children | dbf676c86244 |
line wrap: on
line diff
--- a/hgext3rd/topic/stack.py Fri May 17 17:59:58 2019 +0800 +++ b/hgext3rd/topic/stack.py Fri May 17 17:42:06 2019 +0800 @@ -362,17 +362,17 @@ if ui.verbose: fm.plain(' ') else: - fm.write('topic.stack.index', '%s%%d' % prefix, idx, + fm.write('stack_index', '%s%%d' % prefix, idx, label=labelsgen('topic.stack.index', states)) if ui.verbose: - fm.write('topic.stack.shortnode', '(%s)', short(ctx.node()), + fm.write('node', '(%s)', short(ctx.node()), label=labelsgen('topic.stack.shortnode', states)) - fm.write('topic.stack.state.symbol', '%s', symbol, + fm.write('symbol', '%s', symbol, label=labelsgen('topic.stack.state', states)) fm.plain(' ') - fm.write('topic.stack.desc', '%s', ctx.description().splitlines()[0], + fm.write('desc', '%s', ctx.description().splitlines()[0], label=labelsgen('topic.stack.desc', states)) - fm.condwrite(states != ['clean'] and idx is not None, 'topic.stack.state', + fm.condwrite(states != ['clean'] and idx is not None, 'state', ' (%s)', fm.formatlist(states, 'topic.stack.state'), label=labelsgen('topic.stack.state', states)) fm.plain('\n')