diff options
Diffstat (limited to 'Assistant/BranchChange.hs')
-rw-r--r-- | Assistant/BranchChange.hs | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/Assistant/BranchChange.hs b/Assistant/BranchChange.hs new file mode 100644 index 000000000..b166c8777 --- /dev/null +++ b/Assistant/BranchChange.hs @@ -0,0 +1,21 @@ +{- git-annex assistant git-annex branch change tracking + - + - Copyright 2012 Joey Hess <joey@kitenet.net> + - + - Licensed under the GNU GPL version 3 or higher. + -} + +module Assistant.BranchChange where + +import Control.Concurrent.MSampleVar + +type BranchChangeHandle = MSampleVar () + +newBranchChangeHandle :: IO BranchChangeHandle +newBranchChangeHandle = newEmptySV + +branchChanged :: BranchChangeHandle -> IO () +branchChanged = flip writeSV () + +waitBranchChange :: BranchChangeHandle -> IO () +waitBranchChange = readSV |