mirror of
https://github.com/ytdl-org/youtube-dl
synced 2025-06-07 13:32:40 +09:00
Merge 3462456666144a08ef16ae02390c4a5b6512a8f2 into da7223d4aa42ff9fc680b0951d043dd03cec2d30
This commit is contained in:
commit
4a67f570dd
@ -19,7 +19,7 @@ from youtube_dl import compat_str
|
|||||||
year = compat_str(datetime.datetime.now().year)
|
year = compat_str(datetime.datetime.now().year)
|
||||||
for fn in glob.glob('*.html*'):
|
for fn in glob.glob('*.html*'):
|
||||||
content = read_file(fn)
|
content = read_file(fn)
|
||||||
newc = re.sub(r'(?P<copyright>Copyright © 2011-)(?P<year>[0-9]{4})', 'Copyright © 2011-' + year, content)
|
newc = re.sub(r'(?P<copyright>Copyright © 2011-)(?P<year>\d{4})', 'Copyright © 2011-' + year, content)
|
||||||
if content != newc:
|
if content != newc:
|
||||||
tmpFn = fn + '.part'
|
tmpFn = fn + '.part'
|
||||||
write_file(tmpFn, newc)
|
write_file(tmpFn, newc)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user