Safe Haskell | None |
---|---|
Language | GHC2021 |
Provides type for notifications.
Synopsis
- data NotifySystemP (p :: ConfigPhase)
- = DBus (DBusF p)
- | NotifySend
- | AppleScript
- type NotifySystemArgs = NotifySystemP 'ConfigPhaseArgs
- type NotifySystemToml = NotifySystemP 'ConfigPhaseToml
- type NotifySystemMerged = NotifySystemP 'ConfigPhaseMerged
- type NotifySystemEnv = NotifySystemP 'ConfigPhaseEnv
- parseNotifySystem :: forall (p :: ConfigPhase) m. (DBusF p ~ (), MonadFail m) => m Text -> m (NotifySystemP p)
- notifySystemStr :: IsString a => a
- showNotifySystem :: forall a (p :: ConfigPhase). IsString a => NotifySystemP p -> a
- displayNotifySystem :: forall a (p :: ConfigPhase). IsString a => NotifySystemP p -> a
- type family DBusF (p :: ConfigPhase) where ...
- mergeNotifySystem :: WithDisabled NotifySystemArgs -> Maybe NotifySystemToml -> NotifySystemMerged
- data NotifyAction
- parseNotifyAction :: MonadFail m => m Text -> m NotifyAction
- notifyActionStr :: IsString a => a
- data NotifyTimeout
- parseNotifyTimeout :: MonadFail m => m Text -> m NotifyTimeout
- notifyTimeoutStr :: IsString a => a
- data OsxNotifySystemMismatch
- data LinuxNotifySystemMismatch = LinuxNotifySystemMismatchAppleScript
Notify system
data NotifySystemP (p :: ConfigPhase) Source #
Notification systems.
DBus (DBusF p) | Uses DBus. |
NotifySend | Uses notify-send. |
AppleScript | Uses apple-script. |
Instances
parseNotifySystem :: forall (p :: ConfigPhase) m. (DBusF p ~ (), MonadFail m) => m Text -> m (NotifySystemP p) Source #
Parses NotifySystem
.
notifySystemStr :: IsString a => a Source #
Available NotifySystem
strings.
showNotifySystem :: forall a (p :: ConfigPhase). IsString a => NotifySystemP p -> a Source #
displayNotifySystem :: forall a (p :: ConfigPhase). IsString a => NotifySystemP p -> a Source #
type family DBusF (p :: ConfigPhase) where ... Source #
Maps DBus to its phased param.
DBusF 'ConfigPhaseArgs = () | |
DBusF 'ConfigPhaseToml = () | |
DBusF 'ConfigPhaseMerged = () | |
DBusF 'ConfigPhaseEnv = Client |
mergeNotifySystem :: WithDisabled NotifySystemArgs -> Maybe NotifySystemToml -> NotifySystemMerged Source #
Merges notify systems.
Notify actions
data NotifyAction Source #
Determines for which actions we should send notifications.
NotifyFinal | Send a notification after all commands are completed. |
NotifyCommand | Send notifications when each command completes. |
NotifyAll | NotifyFinal and NotifyCommand. |
Instances
Show NotifyAction Source # | |
Defined in Shrun.Notify.Types showsPrec :: Int -> NotifyAction -> ShowS # show :: NotifyAction -> String # showList :: [NotifyAction] -> ShowS # | |
Eq NotifyAction Source # | |
Defined in Shrun.Notify.Types (==) :: NotifyAction -> NotifyAction -> Bool # (/=) :: NotifyAction -> NotifyAction -> Bool # | |
DecodeTOML NotifyAction Source # | |
Defined in Shrun.Notify.Types |
parseNotifyAction :: MonadFail m => m Text -> m NotifyAction Source #
Parses NotifyAction
.
notifyActionStr :: IsString a => a Source #
Available NotifyAction
strings.
Notify timeout
data NotifyTimeout Source #
Determines notification timeout.
NotifyTimeoutSeconds Word16 | Times out after the given seconds. |
NotifyTimeoutNever | Never times out. |
Instances
FromInteger NotifyTimeout Source # | |
Defined in Shrun.Notify.Types afromInteger :: Integer -> NotifyTimeout Source # | |
Show NotifyTimeout Source # | |
Defined in Shrun.Notify.Types showsPrec :: Int -> NotifyTimeout -> ShowS # show :: NotifyTimeout -> String # showList :: [NotifyTimeout] -> ShowS # | |
Eq NotifyTimeout Source # | |
Defined in Shrun.Notify.Types (==) :: NotifyTimeout -> NotifyTimeout -> Bool # (/=) :: NotifyTimeout -> NotifyTimeout -> Bool # | |
Default NotifyTimeout Source # | |
Defined in Shrun.Notify.Types def :: NotifyTimeout Source # | |
DecodeTOML NotifyTimeout Source # | |
Defined in Shrun.Notify.Types |
parseNotifyTimeout :: MonadFail m => m Text -> m NotifyTimeout Source #
Parses NotifyTimeout
.
notifyTimeoutStr :: IsString a => a Source #
Available NotifyTimeout
strings.
Exceptions
data OsxNotifySystemMismatch Source #
Instances
Exception OsxNotifySystemMismatch Source # | |
Show OsxNotifySystemMismatch Source # | |
Defined in Shrun.Notify.Types showsPrec :: Int -> OsxNotifySystemMismatch -> ShowS # show :: OsxNotifySystemMismatch -> String # showList :: [OsxNotifySystemMismatch] -> ShowS # | |
Eq OsxNotifySystemMismatch Source # | |
Defined in Shrun.Notify.Types |
data LinuxNotifySystemMismatch Source #
Instances
Exception LinuxNotifySystemMismatch Source # | |
Show LinuxNotifySystemMismatch Source # | |
Defined in Shrun.Notify.Types showsPrec :: Int -> LinuxNotifySystemMismatch -> ShowS # show :: LinuxNotifySystemMismatch -> String # showList :: [LinuxNotifySystemMismatch] -> ShowS # | |
Eq LinuxNotifySystemMismatch Source # | |
Defined in Shrun.Notify.Types |