Mercurial > hg
annotate mercurial/utils/hashutil.py @ 45997:7c539f0febbe
upgrade: add an explicite --filelogs arguments
This make it possible to select no revlog for upgrade, which is useful for some
upgrade target or in some specific cases (eg: persistent-nodemap or share-safe
update).
Differential Revision: https://phab.mercurial-scm.org/D9468
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Mon, 30 Nov 2020 14:06:45 +0100 |
parents | 7126d8b8e0e6 |
children | 521ac0d7047f |
rev | line source |
---|---|
44059
7126d8b8e0e6
hashutil: new package for hashing-related features
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
1 from __future__ import absolute_import |
7126d8b8e0e6
hashutil: new package for hashing-related features
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
2 |
7126d8b8e0e6
hashutil: new package for hashing-related features
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
3 import hashlib |
7126d8b8e0e6
hashutil: new package for hashing-related features
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
4 |
7126d8b8e0e6
hashutil: new package for hashing-related features
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
5 try: |
7126d8b8e0e6
hashutil: new package for hashing-related features
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
6 from ..thirdparty import sha1dc |
7126d8b8e0e6
hashutil: new package for hashing-related features
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
7 |
7126d8b8e0e6
hashutil: new package for hashing-related features
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
8 sha1 = sha1dc.sha1 |
7126d8b8e0e6
hashutil: new package for hashing-related features
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
9 except (ImportError, AttributeError): |
7126d8b8e0e6
hashutil: new package for hashing-related features
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
10 sha1 = hashlib.sha1 |