Show More
@@ -13,24 +13,24 b' from mercurial import (' | |||
|
13 | 13 | configtable = {} |
|
14 | 14 | configitem = registrar.configitem(configtable) |
|
15 | 15 | |
|
16 | configitem('fakepatchtime', 'fakenow', | |
|
16 | configitem(b'fakepatchtime', b'fakenow', | |
|
17 | 17 | default=None, |
|
18 | 18 | ) |
|
19 | 19 | |
|
20 | 20 | def internalpatch(orig, ui, repo, patchobj, strip, |
|
21 | prefix='', files=None, | |
|
22 | eolmode='strict', similarity=0): | |
|
21 | prefix=b'', files=None, | |
|
22 | eolmode=b'strict', similarity=0): | |
|
23 | 23 | if files is None: |
|
24 | 24 | files = set() |
|
25 | 25 | r = orig(ui, repo, patchobj, strip, |
|
26 | 26 | prefix=prefix, files=files, |
|
27 | 27 | eolmode=eolmode, similarity=similarity) |
|
28 | 28 | |
|
29 | fakenow = ui.config('fakepatchtime', 'fakenow') | |
|
29 | fakenow = ui.config(b'fakepatchtime', b'fakenow') | |
|
30 | 30 | if fakenow: |
|
31 | 31 | # parsing 'fakenow' in YYYYmmddHHMM format makes comparison between |
|
32 | 32 | # 'fakenow' value and 'touch -t YYYYmmddHHMM' argument easy |
|
33 | fakenow = util.parsedate(fakenow, ['%Y%m%d%H%M'])[0] | |
|
33 | fakenow = util.parsedate(fakenow, [b'%Y%m%d%H%M'])[0] | |
|
34 | 34 | for f in files: |
|
35 | 35 | repo.wvfs.utime(f, (fakenow, fakenow)) |
|
36 | 36 |
General Comments 0
You need to be logged in to leave comments.
Login now