summaryrefslogtreecommitdiffhomepage
path: root/src/Xmobar/Run/Types.hs
blob: deec8ba605b433483e089e488c2ed068fd0456bd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
{-# LANGUAGE TypeOperators, CPP #-}
------------------------------------------------------------------------------
-- |
-- Module: Xmobar.Run.Types
-- Copyright: (c) 2018 Jose Antonio Ortega Ruiz
-- License: BSD3-style (see LICENSE)
--
-- Maintainer: jao@gnu.org
-- Stability: unstable
-- Portability: portable
-- Created: Sun Nov 25, 2018 07:17
--
--
-- An enumeration of all runnable types
--
------------------------------------------------------------------------------


module Xmobar.Run.Types(runnableTypes) where

import {-# SOURCE #-} Xmobar.Run.Runnable()
import Xmobar.Plugins.Monitors
import Xmobar.Plugins.Date
import Xmobar.Plugins.PipeReader
import Xmobar.Plugins.BufferedPipeReader
import Xmobar.Plugins.MarqueePipeReader
import Xmobar.Plugins.CommandReader
import Xmobar.Plugins.StdinReader
import Xmobar.Plugins.XMonadLog
import Xmobar.Plugins.EWMH
import Xmobar.Plugins.Kbd
import Xmobar.Plugins.Locks
import Xmobar.Plugins.NotmuchMail

#ifdef INOTIFY
import Xmobar.Plugins.Mail
import Xmobar.Plugins.MBox
#endif

#ifdef DATEZONE
import Xmobar.Plugins.DateZone
#endif

import Xmobar.Run.Command

-- | An alias for tuple types that is more convenient for long lists.
type a :*: b = (a, b)
infixr :*:

-- | This is the list of types that can be hidden inside
-- 'Runnable.Runnable', the existential type that stores all commands
-- to be executed by Xmobar. It is used by 'Runnable.readRunnable' in
-- the 'Runnable.Runnable' Read instance. To install a plugin just add
-- the plugin's type to the list of types (separated by ':*:') appearing in
-- this function's type signature.
runnableTypes :: Command :*: Monitors :*: Date :*: PipeReader :*:
                 BufferedPipeReader :*: CommandReader :*: StdinReader :*:
                 XMonadLog :*: EWMH :*: Kbd :*: Locks :*: NotmuchMail :*:
#ifdef INOTIFY
                 Mail :*: MBox :*:
#endif
#ifdef DATEZONE
                 DateZone :*:
#endif
                 MarqueePipeReader :*: ()
runnableTypes = undefined