packages feed

include-env 0.2.0.0 → 0.3.0.0

raw patch · 2 files changed

+3/−4 lines, 2 files

Files

include-env.cabal view
@@ -1,5 +1,5 @@ name:                include-env-version:             0.2.0.0+version:             0.3.0.0 synopsis:            Include the value of an environment variable at compile time description:         Embed secrets (e.g. API keys) inside production artifacts at compile time. homepage:            https://github.com/unfoldml/include-env
src/IncludeEnv/TH.hs view
@@ -25,7 +25,7 @@  -- template-haskell import Language.Haskell.TH (runIO, runQ)-import Language.Haskell.TH.Syntax (Q, Exp(..), Dec(..), Pat(..), Name, mkName, Body(..), Lit(..))+import Language.Haskell.TH.Syntax (Q, Exp(..), Dec(..), Pat(..), Name, mkName, Body(..), Lit(..), reportWarning) import Language.Haskell.TH.Lib (valD)  @@ -60,7 +60,7 @@   case mstr of     Just str -> decl varname str     Nothing -> do-      runIO $ putStrLn $ unwords ["*** WARNING : Cannot find variable", e, "in the environment."]+      reportWarning $ unwords ["*** WARNING : Cannot find variable", e, "in the environment."]       decl varname ""     where       decl :: String -> String -> Q [Dec]@@ -68,5 +68,4 @@         dq = ValD qpat qbody []         qpat = VarP (mkName n)         qbody = NormalB (LitE (StringL x))-