diff --git a/Data/Git/Monad.hs b/Data/Git/Monad.hs index 480af9f33b35795f9ca50b66d59ad446fab9ceeb..b3369d291f1193e0eb44e855743932a4ca272b4d 100644 --- a/Data/Git/Monad.hs +++ b/Data/Git/Monad.hs @@ -127,7 +127,7 @@ instance Resolvable Git.RefName where -- | Basic operations common between the different Monads defined in this -- package. -class (Functor m, Applicative m, Monad m) => GitMonad m where +class (Functor m, Applicative m, Monad m, MonadFail m) => GitMonad m where -- | the current Monad must allow access to the current Git getGit :: m (Git.Git SHA1) liftGit :: IO a -> m a @@ -240,6 +240,8 @@ instance Applicative GitM where instance Monad GitM where return = returnGitM (>>=) = bindGitM + +instance MonadFail GitM where fail = failGitM instance GitMonad GitM where @@ -313,6 +315,8 @@ instance Applicative CommitAccessM where instance Monad CommitAccessM where return = returnCommitAccessM (>>=) = bindCommitAccessM + +instance MonadFail CommitAccessM where fail = failCommitAccessM instance GitMonad CommitAccessM where @@ -474,6 +478,8 @@ instance Applicative CommitM where instance Monad CommitM where return = returnCommitM (>>=) = bindCommitM + +instance MonadFail CommitM where fail = failCommitM instance GitMonad CommitM where diff --git a/git.cabal b/git.cabal index 1d5748efce2d5245be5890758a99fc1b182f04d3..72e69359cbc4e35d1ccf773dec6097bc65116215 100644 --- a/git.cabal +++ b/git.cabal @@ -26,7 +26,7 @@ data-files: README.md extra-source-files: tests/*.hs Library - Build-Depends: base >= 4 && < 5 + Build-Depends: base >= 4.13 && < 5 , basement , bytestring >= 0.9 , containers diff --git a/stack.yaml b/stack.yaml index 34c4074597ac429d90a555f8e02678ddce036988..bed42e7433c17f1d9758c7f33e4e03159d8b05fb 100644 --- a/stack.yaml +++ b/stack.yaml @@ -1,3 +1,8 @@ -# ~*~ auto-generated by haskell-ci with config : 0a4c6a0fd68c5b852764201c037cae7f29b1cb3f3856f78d1a20fe2e44845097 ~*~ -{ resolver: lts-13.5, packages: [ '.' ], extra-deps: [], flags: {} } +resolver: nightly-2020-12-12 +packages: + - '.' + +extra-deps: [] + +flags: {} diff --git a/stack.yaml.lock b/stack.yaml.lock new file mode 100644 index 0000000000000000000000000000000000000000..aa36300665c9411e6631bf540375dfae0d9b8047 --- /dev/null +++ b/stack.yaml.lock @@ -0,0 +1,12 @@ +# This file was autogenerated by Stack. +# You should not edit this file by hand. +# For more information, please see the documentation at: +# https://docs.haskellstack.org/en/stable/lock_files + +packages: [] +snapshots: +- completed: + size: 556770 + url: https://raw.githubusercontent.com/commercialhaskell/stackage-snapshots/master/nightly/2020/12/12.yaml + sha256: 168062744e171ba6949149ee702483d2186ddfbb6038508576d6c5093245f534 + original: nightly-2020-12-12