Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/bungogood/haoc
A Haskell-based Advent of Code template and CLI tool for managing, running, and downloading puzzle solutions. Inspired by Rust AOC.
https://github.com/bungogood/haoc
advent-of-code haskell stack
Last synced: about 1 month ago
JSON representation
A Haskell-based Advent of Code template and CLI tool for managing, running, and downloading puzzle solutions. Inspired by Rust AOC.
- Host: GitHub
- URL: https://github.com/bungogood/haoc
- Owner: bungogood
- License: mit
- Created: 2024-12-02T15:36:03.000Z (about 2 months ago)
- Default Branch: main
- Last Pushed: 2024-12-02T17:26:09.000Z (about 2 months ago)
- Last Synced: 2024-12-03T10:08:20.367Z (about 1 month ago)
- Topics: advent-of-code, haskell, stack
- Language: Haskell
- Homepage:
- Size: 17.6 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Haoc
Haskell Advent of Code Template and CLI tool, inspired by [Rust AOC](https://github.com/fspoettel/advent-of-code-rust).
## Installation
requires:
- [stack](https://docs.haskellstack.org/en/stable/README/)
- [aoc-cli](https://github.com/scarvalhojr/aoc-cli) (optional for downloading input files)## Usage
```
haoc - a tool for solving Advent of Code challengesUsage: haoc COMMAND
Advent of Code CLI tool
Available options:
-h,--help Show this help textAvailable commands:
setup Setup environment for a specific year and day
download Download input for a specific year and day
run Run a solution for a specific year and day
cookie Set the session cookie
```### Setup day
Create a new day module and add it to the `app/Solver.hs` file. If no year or day is provided, it will use the current year and day.
```bash
stack run -- setup 2020 1
```Geneates a blank module with `part1` and `part2` functions of type `Solution -> String -> String`.
### Download input
Download the input file for a specific year and day. If no year or day is provided, it will use the current year and day.
```bash
stack run -- download 2020 1
```### Run solution
Run the solution for a specific year and day. If no year or day is provided, it will use the current year and day.
```bash
stack run -- run 2020 1
```## TODO
- [ ] Add tests
- [ ] Allow for submitions thoguh `aoc-cli`