]> Git — Sourcephile - gargantext.git/blob - src/Gargantext/Core/Mail.hs
[FLOW] clean var
[gargantext.git] / src / Gargantext / Core / Mail.hs
1 {-|
2 Module : Gargantext.Core.Mail
3 Description :
4 Copyright : (c) CNRS, 2017-Present
5 License : AGPL + CECILL v3
6 Maintainer : team@gargantext.org
7 Stability : experimental
8 Portability : POSIX
9
10 -}
11
12 {-# LANGUAGE OverloadedStrings #-}
13
14 module Gargantext.Core.Mail
15 (gargMail)
16 where
17
18 import Data.Maybe
19 import Network.Mail.SMTP hiding (htmlPart)
20 import Gargantext.Prelude
21 import Network.Mail.Mime (plainPart)
22
23
24 -- | TODO add parameters
25 gargMail :: IO ()
26 gargMail = sendMail "localhost" mail
27 where
28 mail = simpleMail from to cc bcc subject [body]
29
30 from = Address (Just "François Rabelais") "francois.rabelais@gargantext.org"
31 to = [Address (Just "Anoe") "alexandre@localhost"]
32 cc = []
33 bcc = []
34 subject = "email subject"
35 body = plainPart "email body"
36
37