view en/examples/hook.ws.better.out @ 146:65f6f9d18fa1

Oops! I forgot that I need the undoctored output files in the book! Now they're named "*.lxo", instead of "*.out". Ugh.
author Bryan O'Sullivan <bos@serpentine.com>
date Tue, 06 Mar 2007 21:55:48 -0800
parents 006bbad1f190
children 8cf40d4d9377
line wrap: on
line source

$ \textbf{cat .hg/hgrc}
[hooks]
pretxncommit.whitespace = check_whitespace.py
$ \textbf{echo 'a ' >> a}
$ \textbf{hg commit -A -m 'add new line with trailing whitespace'}
adding check_whitespace.py
a, line 2: trailing whitespace added
check_whitespace.py, line 1: trailing whitespace added
check_whitespace.py, line 2: trailing whitespace added
check_whitespace.py, line 3: trailing whitespace added
check_whitespace.py, line 4: trailing whitespace added
check_whitespace.py, line 5: trailing whitespace added
check_whitespace.py, line 6: trailing whitespace added
check_whitespace.py, line 7: trailing whitespace added
check_whitespace.py, line 8: trailing whitespace added
check_whitespace.py, line 9: trailing whitespace added
check_whitespace.py, line 10: trailing whitespace added
check_whitespace.py, line 11: trailing whitespace added
check_whitespace.py, line 12: trailing whitespace added
check_whitespace.py, line 13: trailing whitespace added
check_whitespace.py, line 14: trailing whitespace added
check_whitespace.py, line 15: trailing whitespace added
check_whitespace.py, line 16: trailing whitespace added
check_whitespace.py, line 17: trailing whitespace added
check_whitespace.py, line 18: trailing whitespace added
check_whitespace.py, line 19: trailing whitespace added
check_whitespace.py, line 20: trailing whitespace added
check_whitespace.py, line 21: trailing whitespace added
check_whitespace.py, line 22: trailing whitespace added
check_whitespace.py, line 23: trailing whitespace added
check_whitespace.py, line 24: trailing whitespace added
check_whitespace.py, line 25: trailing whitespace added
check_whitespace.py, line 26: trailing whitespace added
check_whitespace.py, line 27: trailing whitespace added
check_whitespace.py, line 28: trailing whitespace added
check_whitespace.py, line 29: trailing whitespace added
check_whitespace.py, line 30: trailing whitespace added
check_whitespace.py, line 31: trailing whitespace added
check_whitespace.py, line 32: trailing whitespace added
check_whitespace.py, line 33: trailing whitespace added
check_whitespace.py, line 34: trailing whitespace added
check_whitespace.py, line 35: trailing whitespace added
check_whitespace.py, line 36: trailing whitespace added
check_whitespace.py, line 37: trailing whitespace added
check_whitespace.py, line 38: trailing whitespace added
check_whitespace.py, line 39: trailing whitespace added
check_whitespace.py, line 40: trailing whitespace added
check_whitespace.py, line 41: trailing whitespace added
check_whitespace.py, line 42: trailing whitespace added
check_whitespace.py, line 43: trailing whitespace added
check_whitespace.py, line 44: trailing whitespace added
commit message saved to .hg/commit.save
abort: pretxncommit.whitespace hook exited with status 1
transaction abort!
rollback completed
$ \textbf{perl -pi -e 's,\textbackslash{}s+$,,' a}
$ \textbf{hg commit -A -m 'trimmed trailing whitespace'}
a, line 1: trailing whitespace added
check_whitespace.py, line 1: trailing whitespace added
check_whitespace.py, line 2: trailing whitespace added
check_whitespace.py, line 3: trailing whitespace added
check_whitespace.py, line 4: trailing whitespace added
check_whitespace.py, line 5: trailing whitespace added
check_whitespace.py, line 6: trailing whitespace added
check_whitespace.py, line 7: trailing whitespace added
check_whitespace.py, line 8: trailing whitespace added
check_whitespace.py, line 9: trailing whitespace added
check_whitespace.py, line 10: trailing whitespace added
check_whitespace.py, line 11: trailing whitespace added
check_whitespace.py, line 12: trailing whitespace added
check_whitespace.py, line 13: trailing whitespace added
check_whitespace.py, line 14: trailing whitespace added
check_whitespace.py, line 15: trailing whitespace added
check_whitespace.py, line 16: trailing whitespace added
check_whitespace.py, line 17: trailing whitespace added
check_whitespace.py, line 18: trailing whitespace added
check_whitespace.py, line 19: trailing whitespace added
check_whitespace.py, line 20: trailing whitespace added
check_whitespace.py, line 21: trailing whitespace added
check_whitespace.py, line 22: trailing whitespace added
check_whitespace.py, line 23: trailing whitespace added
check_whitespace.py, line 24: trailing whitespace added
check_whitespace.py, line 25: trailing whitespace added
check_whitespace.py, line 26: trailing whitespace added
check_whitespace.py, line 27: trailing whitespace added
check_whitespace.py, line 28: trailing whitespace added
check_whitespace.py, line 29: trailing whitespace added
check_whitespace.py, line 30: trailing whitespace added
check_whitespace.py, line 31: trailing whitespace added
check_whitespace.py, line 32: trailing whitespace added
check_whitespace.py, line 33: trailing whitespace added
check_whitespace.py, line 34: trailing whitespace added
check_whitespace.py, line 35: trailing whitespace added
check_whitespace.py, line 36: trailing whitespace added
check_whitespace.py, line 37: trailing whitespace added
check_whitespace.py, line 38: trailing whitespace added
check_whitespace.py, line 39: trailing whitespace added
check_whitespace.py, line 40: trailing whitespace added
check_whitespace.py, line 41: trailing whitespace added
check_whitespace.py, line 42: trailing whitespace added
check_whitespace.py, line 43: trailing whitespace added
check_whitespace.py, line 44: trailing whitespace added
commit message saved to .hg/commit.save
abort: pretxncommit.whitespace hook exited with status 1
transaction abort!
rollback completed