Remotes can now be made read-only, by setting remote.<name>.annex-readonly
This commit is contained in:
parent
7d5568485f
commit
f7727d2df1
7 changed files with 45 additions and 3 deletions
|
@ -203,7 +203,9 @@ pushRemote :: Remote -> Maybe Git.Ref -> CommandStart
|
|||
pushRemote _remote Nothing = stop
|
||||
pushRemote remote (Just branch) = go =<< needpush
|
||||
where
|
||||
needpush = anyM (newer remote) [syncBranch branch, Annex.Branch.name]
|
||||
needpush
|
||||
| remoteAnnexReadOnly (Types.Remote.gitconfig remote) = return False
|
||||
| otherwise = anyM (newer remote) [syncBranch branch, Annex.Branch.name]
|
||||
go False = stop
|
||||
go True = do
|
||||
showStart "push" (Remote.name remote)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue