Differences between revisions 9 and 13 (spanning 4 versions)
Revision 9 as of 2007-09-27 15:21:05
Size: 641
Comment: alias is not official yet
Revision 13 as of 2009-08-10 08:00:18
Size: 925
Editor: TillPlewe
Comment:
Deletions are marked like this. Additions are marked like this.
Line 3: Line 3:
'''This extension is not distributed with Mercurial yet''', but is already available in development repositories (see DeveloperRepos)

Download site: http://hg.kublai.com/mercurial/extensions/alias
'''This extension is currently being distributed along with Mercurial.'''
Line 17: Line 14:
Configure your .hgrc to enable the extension by adding following lines: Configure your .hgrc to enable the extension by adding the following lines:
Line 28: Line 25:
Starting with version 1.3 it suffices to add:

{{{
[alias]
# short log
llog = log --limit 10
}}}

=== Future Work ===
 * Support for global options like --config in extension definitions
 * Shell aliases
 * Argument substitution
 {{{
mq = hg -R $(hg root)/.hg/patches $*
}}}
 * Pipes
 {{{
hgrep = hg manifest | grep $*
}}}
 * Recursive alias definitions:
 {{{
foo = bar
bar = log
}}}

Alias Extension

This extension is currently being distributed along with Mercurial.

Author: Brendan Cully

Overview

Just enable the extension, then define your own command aliases in your hgrc. For example, the configuration below gives you a new llog command.

Configuration

Configure your .hgrc to enable the extension by adding the following lines:

[extensions]
alias =

[alias]
# short log
llog = log --limit 10

Starting with version 1.3 it suffices to add:

[alias]
# short log
llog = log --limit 10

Future Work

  • Support for global options like --config in extension definitions
  • Shell aliases
  • Argument substitution
    mq = hg -R $(hg root)/.hg/patches $*
  • Pipes
    hgrep = hg manifest | grep $*
  • Recursive alias definitions:
    foo = bar
    bar = log


CategoryExtension

AliasExtension (last edited 2013-08-08 00:05:19 by rcl)