aboutsummaryrefslogtreecommitdiff
path: root/Types/Remote.hs
diff options
context:
space:
mode:
authorGravatar Joey Hess <joeyh@joeyh.name>2015-10-09 13:07:03 -0400
committerGravatar Joey Hess <joeyh@joeyh.name>2015-10-09 13:12:58 -0400
commit8817fe6331ffc3d99bbf44af559f773af1a2ddd2 (patch)
tree21da807bf1ae9dda9714990b5d6c0dd961bd4ff6 /Types/Remote.hs
parent7788d302397096c85fe70c35f2661d76a8d2f511 (diff)
content locking during drop working for local git remotes
Only ssh remotes lack locking now
Diffstat (limited to 'Types/Remote.hs')
-rw-r--r--Types/Remote.hs7
1 files changed, 4 insertions, 3 deletions
diff --git a/Types/Remote.hs b/Types/Remote.hs
index 511a85afa..a39324163 100644
--- a/Types/Remote.hs
+++ b/Types/Remote.hs
@@ -78,10 +78,11 @@ data RemoteA a = Remote {
-- Removes a key's contents (succeeds if the contents are not present)
removeKey :: Key -> a Bool,
-- Uses locking to prevent removal of a key's contents,
- -- thus producing a VerifiedCopy.
- -- The action must be run whether or not the locking succeeds.
+ -- thus producing a VerifiedCopy, which is passed to the callback.
+ -- If unable to lock, does not run the callback, and throws an
+ -- error.
-- This is optional; remotes do not have to support locking.
- lockContent :: forall r. Maybe (Key -> (Maybe VerifiedCopy -> a r) -> a r),
+ lockContent :: forall r. Maybe (Key -> (VerifiedCopy -> a r) -> a r),
-- Checks if a key is present in the remote.
-- Throws an exception if the remote cannot be accessed.
checkPresent :: Key -> a Bool,