With this change, you can set
[web]
stripes=3
to get stripes every three lines (a-la fanfold paper), instead of every
line on source and directory listings. The default behaviour is stripes=1
which generates output similar to current, and you can also turn stripes
off by setting it to 0.
new hgrc entries allow_push, deny_push, push_ssl control push over http.
allow_push list controls push. if empty or not set, no user can push.
if "*", any user (incl. unauthenticated user) can push. if list of user
names, only authenticated users in list can push.
deny_push list examined before allow_push. if "*", no user can push.
if list of user names, no unauthenticated user can push, and no users
in list can push.
push_ssl requires https connection for push. default is true, so password
sniffing can not be done.
to write hook in python, create module with hook function inside.
make sure mercurial can import module (put it in $PYTHONPATH or load it
as extension). hook function should look like this:
def myhook(ui, repo, hooktype, **kwargs):
if hook_passes:
return True
elif hook_explicitly_fails:
return False
elif some_other_failure:
import util
raise util.Abort('helpful failure message')
else:
return
# implicit return of None makes hook fail!
then in .hgrc, add hook with "python:" prefix:
[hooks]
commit = python:mymodule.myhook
Reference: http://www.selenic.com/mercurial/bts/issue166
If the [ui] section of .hgrc contains keys like "ignore" or
"ignore.something", the values corresponding to these keys are
treated as per-user hgignore files. These hgignore files apply to all
repositories used by that user.
Searched in this order: $HGUSER, [ui] section of hgrcs, $EMAIL
and stop searching if one of these is set.
Abort if found username is an empty string to force specifying
the commit user elsewhere, e.g. with line option or repo hgrc.
If not found, use $LOGNAME or $USERNAME +"@full.hostname".
if set, override default hgrc search path.
if empty, only .hg/hgrc of current repo read.
for each element, if directory, all entries in directory with end in
".rc" are added to path. else, element is added to path.
big thing about this change is that user "~/.hgrc" and system hgrc not
longer breaks tests. run-tests makes HGRCPATH empty now.
change name of key in map file from changelog to changeset.
rename command map files to start with map-cmdline.
rename ui.logmap to ui.style in hgrc.
now --style=foo does this:
tries to open foo as file.
tries as map-cmdline.foo in template path.
tries as foo in template path.
rename --map-file to --style.
no more -t alias for --template.
update docs.
rename template entry in map files to changelog.
if --verbose, use changelog_verbose if there, else changelog.
gendoc.py is a script generating a part of the manpage (the commands
help and options) from the docstring in commands.py.
It avoids duplicating the doc between the doc/ directory and the docstrings.
To generate the manpage, 'make doc' will create all the necessary intermediate
files.
mechanism is same as hgweb templates.
old show_changeset code is still used for now if no template given,
because it is faster than template code when verbose or debug.
simple template can be given on command line using -t, --template.
example:
hg log -t '{author|person}\n'
complex template can be put in template map file, given on command line
using --map-file.
we give two example map files:
map-log.compact prints 3 lines of output for every change.
map-log.verbose prints exact same output as default "hg log -v".
map files are searched where user says, then in template path as backup.
example:
hg log --map-file map-log.compact
defaults can be set in hgrc with ui.logtemplate and ui.logmap.
- change the wait keyword from lock.lock to timeout,
a negative timeout of means "wait forever"
- refactor the two lock functions from localrepo.py
- make them use the timeout (default 1024, can be changed
with ui.timeout in the config file
- update the doc
prechangegroup lets you stop push, pull or unbundle before it begins.
pretxnchangegroup lets you inspect changegroup before transaction is
committed, and roll back if you not like it.
hook allows check of changeset after create, but before transaction
is committed. hook failure rolls transaction back.
makes place for local policies like commit message must contain bug id
or reviewer signoff.
change also adds parent changeset ids to commit hook environment,
because is cheap and useful.
now it searches <install dir>/etc/mercurial, /etc/mercurial, and user
hgrc.
this allows site-wide configuration to be shared over automounted nfs
partition, instead of chenging on every system. option of having local
configuration on every system remains.
old code for searching /etc/mercurial/hgrc.d never worked, this code
is tested and works.
The latest asciidoc doesn't have an 'html' backend. 'html' was last valid
with version 6 ( 2005-1-28). Current options are xhtml11, or
html4, with xhtml11 by default.
--- hg.orig/doc/hg.1.txt 2005-09-22 09:40:47.000000000 -0700
+++ hg/doc/hg.1.txt 2005-09-23 18:31:58.000000000 -0700
@@ -802,6 +802,6 @@ http://selenic.com/mailman/listinfo/merc
COPYING
-------
-Copyright (C) 2005 Matt Mackall.
+Copyright \(C) 2005 Matt Mackall.
Free use of this software is granted under the terms of the GNU General
Public License (GPL).
Index: hg/doc/hgmerge.1.txt
===================================================================
--- hg.orig/doc/hgmerge.1.txt 2005-06-30 10:19:51.000000000 -0700
+++ hg/doc/hgmerge.1.txt 2005-09-23 18:31:59.000000000 -0700
@@ -30,6 +30,6 @@ hg(1) - the command line interface to Me
COPYING
-------
-Copyright (C) 2005 Matt Mackall.
+Copyright \(C) 2005 Matt Mackall.
Free use of this software is granted under the terms of the GNU General
Public License (GPL).
We want to reserve -e for future use and grep compatibility.
I've changed every-match to all out of a general preference for
shorter long option names where short options don't exist.
I inadvertantly used "hg import" on a message I saved, expecting it to do
the right thing, but instead it made the commit look like I authored it,
and filled the description with the email header.
Changeset 238f05c9201ffe16c81e32a55d4d6b563cc9f605 contains a guard
against "hg import" doing this again.
walkchangerevs now returns a two-tuple. Its behaviour is also
extensively commented.
The annotate command's getname function has been factored out to a new
function, trimname, so it can be shared between annotate and grep.
The behaviour of grep has been beefed up, so that it now performs a
number of useful functions.
Based on a patch by Fuming Wang
- add util.binary which decides whether a file is binary if it has any NUL
characters in the first 1K.
- teach mdiff.unidiff to print "binary file <x> has changed" for binary files
- add text flag to cause unidiff and dodiff to treat all files as text
- add -a and --text flags (like diff(1)) to hg diff and export
- update docs
Added options -m, -a, -r and u to select files corresponding
to status M, A, R and ? respectively. If none of these
options are specified, files of all status will be shown.
The code is slightly complicated by the need to commit all outstanding
changes in the repository if no file names are given (other commands
operate on the current directory and its subdirectories in this case).
localrepository.changes has acquired an optional match parameter, to let
it filter out include/exclude options.
These options apply to all names, not just to directories. In other
words, you can do something like this:
hg add -X 'f*' '*.c'
and it will have the effect of "add all files matching *.c, except those
starting with f".
With no names, it now recursively forgets everything, as is the default
behaviour of other commands. And prints the names of all files it
hasn't specifically been told to forget.
It is now more verbose than it used to be. If given file names, it
prints nothing, as before. But if given patterns or nothing, it prints
the names of the files it is operating on, to remove that air of mystery.
It also now operates at or below the current directory.
# HG changeset patch
# User Bryan O'Sullivan <bos@serpentine.com>
# Node ID 5076cf1fd6a1b8eb410e5e03cb004ca6a52a30f9
# Parent d5198e5dd8087ca487031662f0908a6296512e5d
Move hgrc documentation out to its own man page, hgrc(5).
The new man page expands on the existing documentation by describing
the file format and the purpose of each section and field.
# HG changeset patch
# User Radoslaw Szkodzinski <astralstorm@gorzow.mm.pl>
# Node ID 8fc9bfabae06cba91b05c265545bcce2654dab2f
# Parent d5198e5dd8087ca487031662f0908a6296512e5d
Update documentation of hg tag
This updates the FAQ, manpage and adds hg tag to the list of commands
in README.
Index: hg/README
===================================================================
# HG changeset patch
# User Bryan O'Sullivan <bos@serpentine.com>
# Node ID 13b74665cbdf735a91f231956d0fe73e446340ea
# Parent fb74eaa2b5b763ad5591b2e51dbb377bf8342064
Clarify man page entry for locate a little.
# HG changeset patch
# User Bryan O'Sullivan <bos@serpentine.com>
# Node ID ebf5eba347a17a5c09000b3342caf350cd060a1b
# Parent 4309b0a5a6010dd2e5811b77d2bc29a51acf290f
Add locate command.
Used for finding files with names that match specific patterns,
such as "*.c".
This patch also introduces localrepository.getcwd, which returns the
current directory relative to the repository root.
# HG changeset patch
# User Alecs King <alecsk@gmail.com>
On Sat, Jul 02, 2005 at 02:11:34PM -0700, Matt Mackall wrote:
> On Sun, Jul 03, 2005 at 12:49:27AM +0800, Alecs King wrote:
> > Hg is really very nice. The only feature i miss from git is the
> > whatchanged -p, which shows a diff along with a changeset.
> > python before, i just dig into the mercurial/commands.py a while and
> > see what diff(), dodiff(), export(), show_changeset(), log() would
> > normally do. There might be one thing or two missed or wrong. But here
> > it is: a '-d' option to 'hg log' showing the diff info. You can use 'hg
> > log -d' to show the whole history with the diff or 'hg log -d <file>' to
> > show that info of a particular file. And also works with the '-r'
> > option.
>
> Let's use -p. We're going to be combining the global and per command
> switch namespace shortly and the global -p will disappear.
Okay. '-d' changed to '-p'. Just like 'whatchanged -p', now we have
'hg log -p'.
> Also, the argument list for show_changeset is getting a bit unwieldy.
This time i remain show_changeset untouched at all. Only changed some
bits of log().
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Add username/merge/editor to .hgrc
These take priority over the equivalent environment vars
Deprecate HGMERGE, HGUSER, and HGEDITOR in docs
Add ui section to docs
Remove undocumented HG_OPTS
Raise username code out of changelog class
Make tests ignore ~/.hgrc
manifest hash: d127ef02bc5266036b4c77a55319519e91bd475b
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)
iD8DBQFCyM5NywK+sNU5EO8RAuU7AJ9zKk1TFrJXHM04jOOJJeBSp8jlTgCeP+tr
qwGFd+WaNqTepZ0wun5g9Uc=
=QEBu
-----END PGP SIGNATURE-----
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
[PATCH] New export patch
From: Bryan O'Sullivan <bos@serpentine.com>
Modify export command to accept rev ranges and output file spec.
It can now export a range of revisions, and print exported patches
to files whose names are generated using format strings.
manifest hash: e0085c205cdc31a168bcd25c85772ef00d53031d
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)
iD8DBQFCx02iywK+sNU5EO8RAtCKAJ0V2K9+i1OGa27KyC5/nq3m+OdvtgCgpnav
3vfEODMzJVOZoJt9wzI1UCg=
=YAdI
-----END PGP SIGNATURE-----
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
[PATCH] Force "hg clone" to always create a new directory
From: Bryan O'Sullivan <bos@serpentine.com>
I just screwed myself by typing "hg clone foo" without specifying a
destination directory, and after I was done mopping up the mess,
concluded that this is a dangerous mode of operation that has no
practical value.
I've thus modified the clone command so that it always creates a
destination directory. If none is specified, the destination is taken
as the basename of the source.
hg clone foo
-> error, because foo already exists
hg clone http://www.selenic.com/hg
-> new repo, named hg
hg clone ../bar
-> new repo, named bar
manifest hash: f21ed8f805a60c1326d99220772e1574b0870d6c
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)
iD8DBQFCwxsIywK+sNU5EO8RAgooAKC3IL6vKyADb9s2qqqi4GMw2Z7asACbBtE/
TvPgwGtIiB2GC+N+V7r1VpI=
=uTcK
-----END PGP SIGNATURE-----
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
[PATCH] replace history with log
From: Radoslaw Szkodzinski <astralstorm@gorzow.mm.pl>
Merge hg history into hg log leaving the first as an alias
(tweaked by mpm: update docs, tests, use existing alias mechanism)
manifest hash: f85001a4373b8b823a6221ba5c506628059d6779
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)
iD8DBQFCwSr1ywK+sNU5EO8RAmbAAJ9HlFkf8/qLOAQUtj8CWxGRPEyzVgCgtXwP
SdnAg1a2q4693+TBiOjrimY=
=w9rf
-----END PGP SIGNATURE-----
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Add initial hook support
This adds the basic hook code as well as pre and post-commit hooks.
Argument passing is by environment variable key/value pairs so that
extra data can be passed over time. File lists will generally not be
passed to hooks as these can be extremely long (>1M).
manifest hash: 45cf9bab432782c391bc9c1c048c84cc75d52740
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)
iD8DBQFCwOukywK+sNU5EO8RAsVsAJ9QipR2aKRSSvoRNo+3If6JddUDkwCgkZrM
KEmZpUOxhNHqezFVrHDRTjE=
=aedm
-----END PGP SIGNATURE-----
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Update of doc/hg.1.txt
- - set date to release date of Mercurial 0.6
- - remove trailing spaces and other trivial changes
- - add 'hg root' and $HGEDITOR.
- - add another repository in the [paths] example
manifest hash: 873f058d10bf58c1e54381715c82c1d1aeeee1e9
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (GNU/Linux)
iD8DBQFCvqRXW7P1GVgWeRoRAv/NAKCeiaHsrnUFDdlMMRj1QhL4gKvi6gCgkAL4
QhH/bw/Gjs7R+9LHJW/chxs=
=G3kF
-----END PGP SIGNATURE-----