aoc2018-0.1.0.0: Advent of Code 2018 solutions and auto-runner

Copyright(c) Justin Le 2018
LicenseBSD3
Maintainerjustin@jle.im
Stabilityexperimental
Portabilitynon-portable
Safe HaskellNone
LanguageHaskell2010

AOC.Run

Contents

Description

Run actions regarding challenges, solutions, tests, submissions, viewing prompts, etc.

Essentially implements the functionality of the main app.

Synopsis

Options

data TestSpec Source #

Specification of parts to test and run

Constructors

TSAll 
TSDayAll 

Fields

TSDayPart 
Instances
Show TestSpec Source # 
Instance details

Defined in AOC.Run

Runners

Run solutions, tests, benchmarks

data MainRunOpts Source #

Options for mainRun.

Constructors

MRO 

Fields

mainRun :: (MonadIO m, MonadError [String] m) => Config -> MainRunOpts -> m (Map (Finite 25) (Map Part (Maybe Bool, Either [String] String))) Source #

Run, test, bench.

defaultMRO :: TestSpec -> MainRunOpts Source #

Default options for mainRun.

View prompts

mainView :: (MonadIO m, MonadError [String] m) => Config -> MainViewOpts -> m (Map (Finite 25) (Map Part Text)) Source #

View prompt

defaultMVO :: TestSpec -> MainViewOpts Source #

Default options for mainView.

Submit answers

data MainSubmitOpts Source #

Options for mainSubmit

Constructors

MSO 

Fields

mainSubmit :: (MonadIO m, MonadError [String] m) => Config -> MainSubmitOpts -> m (Text, SubmitRes) Source #

Submit and analyze result

Util

withColor :: ColorIntensity -> Color -> IO () -> IO () Source #

Do the action with a given ANSI foreground color and intensity.