Mercurial > hg
annotate tests/svnurlof.py @ 43618:c5f6f58f6c71
remotefilelog: handle **kwargs correctly when overriding changelog.add()
Differential Revision: https://phab.mercurial-scm.org/D7372
author | Daniel Ploch <dploch@google.com> |
---|---|
date | Tue, 12 Nov 2019 15:53:58 -0800 |
parents | 2372284d9457 |
children | 6000f5b25c9b |
rev | line source |
---|---|
41480
eb6700e6c5ea
tests: make and use a new `svnurlof.py` helper for constructing svn urls
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
1 from __future__ import absolute_import, print_function |
eb6700e6c5ea
tests: make and use a new `svnurlof.py` helper for constructing svn urls
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
2 import sys |
eb6700e6c5ea
tests: make and use a new `svnurlof.py` helper for constructing svn urls
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
3 |
eb6700e6c5ea
tests: make and use a new `svnurlof.py` helper for constructing svn urls
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
4 from mercurial import ( |
eb6700e6c5ea
tests: make and use a new `svnurlof.py` helper for constructing svn urls
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
5 pycompat, |
eb6700e6c5ea
tests: make and use a new `svnurlof.py` helper for constructing svn urls
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
6 util, |
eb6700e6c5ea
tests: make and use a new `svnurlof.py` helper for constructing svn urls
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
7 ) |
eb6700e6c5ea
tests: make and use a new `svnurlof.py` helper for constructing svn urls
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
8 |
43076
2372284d9457
formatting: blacken the codebase
Augie Fackler <augie@google.com>
parents:
41480
diff
changeset
|
9 |
41480
eb6700e6c5ea
tests: make and use a new `svnurlof.py` helper for constructing svn urls
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
10 def main(argv): |
eb6700e6c5ea
tests: make and use a new `svnurlof.py` helper for constructing svn urls
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
11 enc = util.urlreq.quote(pycompat.sysbytes(argv[1])) |
eb6700e6c5ea
tests: make and use a new `svnurlof.py` helper for constructing svn urls
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
12 if pycompat.iswindows: |
eb6700e6c5ea
tests: make and use a new `svnurlof.py` helper for constructing svn urls
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
13 fmt = 'file:///%s' |
eb6700e6c5ea
tests: make and use a new `svnurlof.py` helper for constructing svn urls
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
14 else: |
eb6700e6c5ea
tests: make and use a new `svnurlof.py` helper for constructing svn urls
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
15 fmt = 'file://%s' |
eb6700e6c5ea
tests: make and use a new `svnurlof.py` helper for constructing svn urls
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
16 print(fmt % pycompat.sysstr(enc)) |
eb6700e6c5ea
tests: make and use a new `svnurlof.py` helper for constructing svn urls
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
17 |
43076
2372284d9457
formatting: blacken the codebase
Augie Fackler <augie@google.com>
parents:
41480
diff
changeset
|
18 |
41480
eb6700e6c5ea
tests: make and use a new `svnurlof.py` helper for constructing svn urls
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
19 if __name__ == '__main__': |
eb6700e6c5ea
tests: make and use a new `svnurlof.py` helper for constructing svn urls
Augie Fackler <augie@google.com>
parents:
diff
changeset
|
20 main(sys.argv) |