view en/examples/hook.ws.simple.out @ 219:15a6fd2ba582

Start talking about the advantages of distributed tools.
author Bryan O'Sullivan <bos@serpentine.com>
date Mon, 14 May 2007 11:20:34 -0700
parents e67251ac336f
children 00f69e8825c5
line wrap: on
line source

$ \textbf{cat .hg/hgrc}
[hooks]
pretxncommit.whitespace = hg export tip | (! egrep -q '^\textbackslash{}+.*[ \textbackslash{}t]$')
$ \textbf{echo 'a ' > a}
$ \textbf{hg commit -A -m 'test with trailing whitespace'}
adding a
abort: pretxncommit.whitespace hook exited with status 1
transaction abort!
rollback completed
$ \textbf{echo 'a' > a}
$ \textbf{hg commit -A -m 'drop trailing whitespace and try again'}