Copyright | (c) 2024 Illia Shkroba |
---|---|
License | BSD3 |
Maintainer | Illia Shkroba <is@pjwstk.edu.pl> |
Stability | unstable |
Portability | non-portable (Non-Unix systems are not supported) |
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
PFile.Profile.Internal.Lifetime
Description
Types and functions for managing profiles lifetime.
Synopsis
- create :: forall m. (MonadReader Env m, MonadError CreateError m, MonadIO m) => CreateOptions -> Name -> [Absolute] -> m Profile
- showCreateError :: CreateError -> Text
- data CreateError
- showCreateRollbackCause :: CreateRollbackCause -> Text
- data CreateRollbackCause
- newtype CreateOptions = CreateOptions {}
Documentation
Arguments
:: forall m. (MonadReader Env m, MonadError CreateError m, MonadIO m) | |
=> CreateOptions | Options that control |
-> Name |
|
-> [Absolute] | List of |
-> m Profile |
Create a new profile called Name
with
a list of Absolute
filesystem's objects to be
push
ed inside of
a profilesHomeDirPath
directory. When an error is encountered
during pushAll
, create
attempts to
rollback. If the rollback fails, the profile is considered
Dangling
. Only
Valid
profiles are returned.
Since: 0.1.0.0
showCreateError :: CreateError -> Text Source #
data CreateError Source #
Error thrown by create
.
Since: 0.1.0.0
Constructors
ProfileAlreadyExistsError !Name | 'PFile.Profile.Internal.Profile.Profile with
|
PushRollbackError |
|
PushCreateError !CreateRollbackCause |
|
data CreateRollbackCause Source #
create
rollback cause.
Since: 0.1.0.0