Matt Mackall
59bf512648
changelog: micro-optimizations to changelog.read()
2012-03-18 18:19:16 -05:00
Matt Mackall
e6d872a339
changelog: handle decoding of NULs in extra more carefully (issue3156)
...
Escaped NULs adjacent to [0-7] could be decoded as octal. This hits
about 0.24% of changesets with transplant, which stores binary nodes.
2011-12-16 18:23:15 -06:00
Pierre-Yves David
7049209b6a
hidden: Add a hiddenrevs attributes to changelog.
...
This attributes hold the set of all revisions that should be ommited by command
and tools displaying changesets.
This set is given as a hit. Command and tools are responsible to check it in
order to filter they outpur.
Code adding revisions to the set are responsible to the consistency of it's
data.
2011-06-16 01:57:53 +02:00
Martin Geisler
0eaeed4412
merge with stable
2011-05-19 18:10:03 +02:00
Martin Geisler
ff9aae8a76
changelog: convert user and desc from local encoding early
...
Failing to do so makes it impossible to use the memctx API to create a
changeset with a commit message or username outside of the current
encoding.encoding setting.
2011-05-19 18:09:25 +02:00
Sune Foldager
c222fc4662
changelog: don't use generaldelta
2011-05-16 13:06:48 +02:00
Zachary Gramana
6cc7816532
changelog: fixes leaked file handle
2011-05-05 11:33:02 -04:00
Idan Kamara
762d333ae9
eliminate various naked except clauses
2011-04-23 00:51:25 +03:00
Matt Mackall
dd8f91e931
Merge with stable
2010-02-11 17:44:01 -06:00
Wagner Bruna
a4d5546600
branch: avoid using reserved tag names
...
Reported as Debian bug #552423 .
2010-02-11 12:02:48 -02:00
Matt Mackall
595d66f424
Update license to GPLv2+
2010-01-19 22:20:08 -06:00
Benoit Boissinot
ce970b2d3e
changelog: do not use a mutable default value
2009-10-31 16:49:27 +01:00
Matt Mackall
d8c1b12a59
changelog: move delayopener outside of class to eliminate reference cycle
2009-07-18 12:34:38 -05:00
Matt Mackall
58b70ccd45
changelog: swap opener to switch delay modes
2009-07-18 11:26:35 -05:00
Matt Mackall
853050477c
changelog: factor out _delayname
2009-07-18 11:25:55 -05:00
Matt Mackall
bda87e75ac
changelog: _delaycount -> _divert
2009-07-18 11:25:54 -05:00
Benoit Boissinot
125a85ec87
use new style classes
2009-06-10 15:10:21 +02:00
Matt Mackall
23a569538b
changelog: make delayopener less intrusive
2009-05-27 14:44:55 -05:00
Matt Mackall
98aa07c578
commit: move description trimming into changelog
2009-05-18 17:36:24 -05:00
Martin Geisler
b43ec973e1
changelog: turn {de,en}code_extra methods into functions
...
The methods were not really methods -- they didn't use 'self'. Having
them as functions in the module it useful for other modules (like the
commitsigs extension) that want to recompute the changeset hash and
thus want to encode dicts the same way as changelog does it.
Removed the underbars from their names at the same time.
2009-05-15 01:21:24 +02:00
Martin Geisler
f138e91851
merge with crew-stable
2009-05-16 11:16:23 +02:00
Martin Geisler
fc8a97dac3
changelog: refuse to add revisions with empty usernames
...
An empty username or a username with a "\n" will make the revision
text contain two "\n\n" sequences -> corrupt repository.
The problem is that changelog.read expects to find exactly one "\n\n"
separator and thus cannot unpack the revision.
2009-05-16 11:12:49 +02:00
Martin Geisler
49d93faf0c
changelog: removed bad default arguments in add method
...
The arguments defaulted to None, but
- user cannot be None since it is immediately stripped.
- p1 and p2 cannot be None since they are passed directly to
revlog.addrevision, where they are mandatory.
2009-05-15 00:55:14 +02:00
Martin Geisler
750183bdad
updated license to be explicit about GPL version 2
2009-04-26 01:08:54 +02:00
Matt Mackall
2f9b02c62d
replace util.sort with sorted built-in
...
This is marginally faster for small and moderately-sized lists
2009-04-26 16:50:44 -05:00
timeless
26d95caa99
help: miscellaneous language fixes
2009-02-28 12:38:45 +01:00
Matt Mackall
cb4d50ff04
Introduce HG_PREPEND to solve pretxn races
...
- add writepending to flush delayed writes to separate file
- add support in hooks for lazy evaluation of callable parameters
- add HG_PENDING to pretxn hooks
- call writepending if hook is used
- pass repo root to hook environment
- if HG_PENDING = repo root, we're in pretxn hook
- read pending data to make pending changesets visible
- filter HG_PENDING in tests/printenv.py
2009-02-16 19:35:07 -06:00
Matt Mackall
642f4d7151
move encoding bits from util to encoding
...
In addition to cleaning up util, this gets rid of some circular dependencies.
2009-04-03 14:51:48 -05:00
Matt Mackall
b28ccc9a94
revlog: kill from-style imports
...
They're slow.
2009-01-11 22:55:36 -06:00
Matt Mackall
d15d559b7c
errors: move revlog errors
...
- create error.py for exception classes to reduce demandloading
- move revlog exceptions to it
- change users to import error and drop revlog import if possible
2009-01-11 22:48:28 -06:00
Matt Mackall
8d99be19f0
many, many trivial check-code fixups
2010-01-25 00:05:27 -06:00
Benoit Boissinot
d954d76b97
use repr() instead of backticks
2008-12-06 14:27:31 +01:00
Dirkjan Ochtman
0aa08a7ed8
merge with crew-stable
2008-09-17 11:34:37 +02:00
Benoit Boissinot
d6add1b5a8
forbid username with '\n' at the changelog level
...
It was already forbidden for ui.username() but no verification were
made for username passed through the commandline.
2008-09-13 17:46:09 +02:00
Matt Mackall
a65ef7bc5d
util: add sort helper
2008-06-27 18:28:45 -05:00
Matt Mackall
bc715be859
add __len__ and __iter__ methods to repo and revlog
2008-06-26 14:35:50 -05:00
Benoit Boissinot
7043af3e09
make sure not to reuse an existing append-file from a previous failed pull
2008-03-14 21:35:49 +01:00
Joel Rosdahl
4f8012378a
Remove unused imports
2008-03-06 22:23:41 +01:00
Joel Rosdahl
5dae3059a0
Expand import * to allow Pyflakes to find problems
2008-03-06 22:23:26 +01:00
Matt Mackall
40a16e2ab7
changelog: fix decoding of extra
...
(spotted by pmezard)
2008-01-03 13:46:39 -06:00
Matt Mackall
c29af0c762
changelog: inline trivial call for extra data unescaping
2007-12-27 23:55:40 -06:00
Matt Mackall
295be4678d
changelog: remove extract function
2007-12-27 23:55:40 -06:00
Matt Mackall
0804290ab7
revlog: fix caching of buffer objects
2007-10-11 00:46:53 -05:00
Thomas Arendsen Hein
a974129de3
merge with crew-stable
2007-07-21 17:37:39 +02:00
Benoit Boissinot
8c722d66b2
fix bogus close spotted by pychecker (no close() in global scope)
2007-07-20 09:44:50 +02:00
Benoit Boissinot
84d45c7794
fix unused variables reported by pychecker
2007-07-20 09:31:32 +02:00
Brendan Cully
864d59c393
python 2.3 does not have sorted
2007-07-06 10:29:09 -07:00
Brendan Cully
ee78cfbb39
Sort changelog extra dict to avoid possible nondeterminism
2007-07-06 10:22:22 -07:00
Thomas Arendsen Hein
4d29c6dc8e
Updated copyright notices and add "and others" to "hg version"
2007-06-19 08:51:34 +02:00
Matt Mackall
4ae8d87bd3
changelog: optimize delayed updates for clone vs pull
...
pull index updates get redirected to memory, then appended on finalize
clone index updates get sent to 00changelog.i.a, then renamed on finalize
2007-03-24 02:47:33 -05:00