This repository contains the source for my Calamity tutorial over at https://www.morrowm.com/posts/2021-04-29-calamity.html
This project requires the GHC 8.10 compiler and the Cabal build tool. See the Haskell downloads page for up-to-date information on how to aquire those.
Make sure to replace the
"<your token here>" string in
Main.hs with your bot's secret token! You can obtain one through the Discord Developer Portal. Also a reminder: the token is secret, treat it like you'd treat a password!
Run the following command to build the project. Note that the first build will take a while, Calamity has a pretty heavy dependency footprint. Subsequent builds should be significantly faster.
$ cabal build
And to run:
$ cabal run
cabal run will build and run, so you don't need to run
cabal build every time.
To open a GHCi session in the context of the project:
$ cabal repl