share: introduce config option to store requires in .hg/store
This introduces a config option which enabled stores the requirements on a repository in store instead. When enabled, `.hg/requires` will contain the `share-safe` requirement which marks that the requirements are present in the store. This is done so that repository requirements can be shared with shares made using `hg share` command. After this patch, `hg share` checks whether the source repository has share-safe requirement, if yes, it does not copy the requirements. Test for the new functionality is added and a test case in exitsing share tests is also added. Differential Revision: https://phab.mercurial-scm.org/D8633
Showing
- mercurial/configitems.py 3 additions, 0 deletionsmercurial/configitems.py
- mercurial/localrepo.py 48 additions, 6 deletionsmercurial/localrepo.py
- mercurial/requirements.py 8 additions, 0 deletionsmercurial/requirements.py
- mercurial/scmutil.py 1 addition, 1 deletionmercurial/scmutil.py
- mercurial/store.py 3 additions, 1 deletionmercurial/store.py
- tests/test-journal-share.t 7 additions, 0 deletionstests/test-journal-share.t
- tests/test-narrow-share.t 6 additions, 0 deletionstests/test-narrow-share.t
- tests/test-remotefilelog-share.t 7 additions, 0 deletionstests/test-remotefilelog-share.t
- tests/test-share-bookmarks.t 7 additions, 0 deletionstests/test-share-bookmarks.t
- tests/test-share-safe.t 69 additions, 0 deletionstests/test-share-safe.t
- tests/test-share.t 8 additions, 0 deletionstests/test-share.t
Loading
Please register or sign in to comment