Show More
@@ -455,11 +455,12 b' def reposetup(ui, repo):' | |||||
455 | repo.prepushoutgoinghooks.add(b"largefiles", prepushoutgoinghook) |
|
455 | repo.prepushoutgoinghooks.add(b"largefiles", prepushoutgoinghook) | |
456 |
|
456 | |||
457 | def checkrequireslfiles(ui, repo, **kwargs): |
|
457 | def checkrequireslfiles(ui, repo, **kwargs): | |
458 | if b'largefiles' not in repo.requirements and any( |
|
458 | with repo.lock(): | |
459 | lfutil.shortname + b'/' in f[1] for f in repo.store.datafiles() |
|
459 | if b'largefiles' not in repo.requirements and any( | |
460 | ): |
|
460 | lfutil.shortname + b'/' in f[1] for f in repo.store.datafiles() | |
461 | repo.requirements.add(b'largefiles') |
|
461 | ): | |
462 |
|
|
462 | repo.requirements.add(b'largefiles') | |
|
463 | scmutil.writereporequirements(repo) | |||
463 |
|
464 | |||
464 | ui.setconfig( |
|
465 | ui.setconfig( | |
465 | b'hooks', b'changegroup.lfiles', checkrequireslfiles, b'largefiles' |
|
466 | b'hooks', b'changegroup.lfiles', checkrequireslfiles, b'largefiles' |
General Comments 0
You need to be logged in to leave comments.
Login now