Skip to content

Instantly share code, notes, and snippets.

@tkovs
Forked from haskellcamargo/Mortivacional.hs
Last active August 29, 2015 14:27
Show Gist options
  • Save tkovs/932c83f518b5187035b2 to your computer and use it in GitHub Desktop.
Save tkovs/932c83f518b5187035b2 to your computer and use it in GitHub Desktop.
Mortivacional.hs
module Mortivacional where
import System.Console.ANSI
drawLine :: IO ()
drawLine = putStrLn $ replicate 23 '-'
turnRed :: IO ()
turnRed = setSGR [ SetConsoleIntensity BoldIntensity
, SetColor Foreground Vivid Red
]
turnGreen :: IO ()
turnGreen = setSGR [ SetConsoleIntensity BoldIntensity
, SetColor Foreground Dull Green
]
turnCyan :: IO ()
turnCyan = setSGR [ SetConsoleIntensity BoldIntensity
, SetColor Foreground Vivid Cyan
]
main :: IO ()
main =
turnGreen
>> drawLine
>> turnCyan
>> putStrLn "Conte me suas angústias"
>> turnGreen
>> drawLine
>> turnCyan
>> getLine
>>= \cry -> do
turnRed
putStrLn $ "> " ++ case cry of
"amigos" -> "Você não tem"
"crush" -> "Ela não tem quer"
"dinheiro" -> "Você não tem"
"emprego" -> "Só com Java"
"esperanca" -> "Já morreu"
"fe" -> "Desista"
otherwise -> "Foda-se"
main
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment