Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/main' into day_15
Browse files Browse the repository at this point in the history
* origin/main:
  Update dependencies (#41)
  Remove hspec skip rules from hlint (#39)
  Add hlint rule (#37)
  Solve Day 21 (#35)
  Refactor: Use LANGUAGE TypeApplications (#36)
  Solve Day 12 (#21)
  Solve Day 20 (#34)
  Solve Day 10 (#18)
  Harvest parseInts util (#33)
  Solve Day 18 (#31)
  Solve Day 17 (#30)
  Create Advent.Parser for shared parsers (#29)
  Solve Day 16 (#26)
  Add hspec-discover to PATH (#28)
  • Loading branch information
manuphatak committed Jan 10, 2021
2 parents 17bf73d + 66a2af0 commit 6ec6bf7
Show file tree
Hide file tree
Showing 92 changed files with 6,972 additions and 74 deletions.
9 changes: 5 additions & 4 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,21 +12,22 @@ jobs:
- restore_cache:
name: Restore cache
keys:
- v1-{{ checksum "stack.yaml" }}-{{ checksum "package.yaml" }}-success
- v1-{{ checksum "stack.yaml" }}-{{ checksum "package.yaml" }}-{{ checksum "AdventOfCode2020.cabal" }}-success
- v1-{{ checksum "stack.yaml" }}-{{ checksum "package.yaml" }}-{{ checksum "AdventOfCode2020.cabal" }}
- v1-{{ checksum "stack.yaml" }}-{{ checksum "package.yaml" }}
- v1-{{ checksum "stack.yaml" }}
- run:
name: Resolve dependencies
command: stack --no-terminal setup
- run:
name: Install executable
command: stack --no-terminal install
command: stack --no-terminal install --jobs 1
- run:
name: Clean any cached coverage data
command: rm -rfv $(stack --no-terminal path --local-hpc-root)
- save_cache:
name: Save Cache
key: v1-{{ checksum "stack.yaml" }}-{{ checksum "package.yaml" }}
key: v1-{{ checksum "stack.yaml" }}-{{ checksum "package.yaml" }}-{{ checksum "AdventOfCode2020.cabal" }}
paths:
- "/root/.stack"
- ".stack-work"
Expand All @@ -47,7 +48,7 @@ jobs:
path: hlint.html
- save_cache:
name: Save Cache
key: v1-{{ checksum "stack.yaml" }}-{{ checksum "package.yaml" }}-success
key: v1-{{ checksum "stack.yaml" }}-{{ checksum "package.yaml" }}-{{ checksum "AdventOfCode2020.cabal" }}-success
paths:
- "/root/.stack"
- ".stack-work"
1 change: 1 addition & 0 deletions .envrc.sample
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#!/usr/bin/env bash
PATH_add bin
PATH_add bin/stack

export SESSION_ID=0000000000
export GITHUB_USER=manuphatak
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
BinaryOp
( Number 1
, Plus
, Number 2
)
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
BinaryOp
( Number 1
, Plus
, Number 2
)
21 changes: 21 additions & 0 deletions .golden/Day18.Solution.parseExpression_example_advanced_1/actual
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
BinaryOp
( BinaryOp
( BinaryOp
( Number 1
, Plus
, Number 2
)
, Times
, BinaryOp
( Number 3
, Plus
, Number 4
)
)
, Times
, BinaryOp
( Number 5
, Plus
, Number 6
)
)
21 changes: 21 additions & 0 deletions .golden/Day18.Solution.parseExpression_example_advanced_1/golden
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
BinaryOp
( BinaryOp
( BinaryOp
( Number 1
, Plus
, Number 2
)
, Times
, BinaryOp
( Number 3
, Plus
, Number 4
)
)
, Times
, BinaryOp
( Number 5
, Plus
, Number 6
)
)
21 changes: 21 additions & 0 deletions .golden/Day18.Solution.parseExpression_example_advanced_2/actual
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
BinaryOp
( BinaryOp
( Number 1
, Plus
, BinaryOp
( Number 2
, Times
, Number 3
)
)
, Plus
, BinaryOp
( Number 4
, Times
, BinaryOp
( Number 5
, Plus
, Number 6
)
)
)
21 changes: 21 additions & 0 deletions .golden/Day18.Solution.parseExpression_example_advanced_2/golden
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
BinaryOp
( BinaryOp
( Number 1
, Plus
, BinaryOp
( Number 2
, Times
, Number 3
)
)
, Plus
, BinaryOp
( Number 4
, Times
, BinaryOp
( Number 5
, Plus
, Number 6
)
)
)
13 changes: 13 additions & 0 deletions .golden/Day18.Solution.parseExpression_example_advanced_3/actual
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
BinaryOp
( Number 2
, Times
, BinaryOp
( Number 3
, Plus
, BinaryOp
( Number 4
, Times
, Number 5
)
)
)
13 changes: 13 additions & 0 deletions .golden/Day18.Solution.parseExpression_example_advanced_3/golden
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
BinaryOp
( Number 2
, Times
, BinaryOp
( Number 3
, Plus
, BinaryOp
( Number 4
, Times
, Number 5
)
)
)
25 changes: 25 additions & 0 deletions .golden/Day18.Solution.parseExpression_example_advanced_4/actual
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
BinaryOp
( Number 5
, Plus
, BinaryOp
( BinaryOp
( BinaryOp
( Number 8
, Times
, BinaryOp
( BinaryOp
( Number 3
, Plus
, Number 9
)
, Plus
, Number 3
)
)
, Times
, Number 4
)
, Times
, Number 3
)
)
25 changes: 25 additions & 0 deletions .golden/Day18.Solution.parseExpression_example_advanced_4/golden
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
BinaryOp
( Number 5
, Plus
, BinaryOp
( BinaryOp
( BinaryOp
( Number 8
, Times
, BinaryOp
( BinaryOp
( Number 3
, Plus
, Number 9
)
, Plus
, Number 3
)
)
, Times
, Number 4
)
, Times
, Number 3
)
)
37 changes: 37 additions & 0 deletions .golden/Day18.Solution.parseExpression_example_advanced_5/actual
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
BinaryOp
( BinaryOp
( Number 5
, Times
, Number 9
)
, Times
, BinaryOp
( BinaryOp
( BinaryOp
( Number 7
, Times
, Number 3
)
, Times
, BinaryOp
( Number 3
, Plus
, Number 9
)
)
, Times
, BinaryOp
( Number 3
, Plus
, BinaryOp
( BinaryOp
( Number 8
, Plus
, Number 6
)
, Times
, Number 4
)
)
)
)
37 changes: 37 additions & 0 deletions .golden/Day18.Solution.parseExpression_example_advanced_5/golden
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
BinaryOp
( BinaryOp
( Number 5
, Times
, Number 9
)
, Times
, BinaryOp
( BinaryOp
( BinaryOp
( Number 7
, Times
, Number 3
)
, Times
, BinaryOp
( Number 3
, Plus
, Number 9
)
)
, Times
, BinaryOp
( Number 3
, Plus
, BinaryOp
( BinaryOp
( Number 8
, Plus
, Number 6
)
, Times
, Number 4
)
)
)
)
41 changes: 41 additions & 0 deletions .golden/Day18.Solution.parseExpression_example_advanced_6/actual
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
BinaryOp
( BinaryOp
( BinaryOp
( BinaryOp
( BinaryOp
( BinaryOp
( Number 2
, Plus
, Number 4
)
, Times
, Number 9
)
, Times
, BinaryOp
( BinaryOp
( BinaryOp
( Number 6
, Plus
, Number 9
)
, Times
, BinaryOp
( Number 8
, Plus
, Number 6
)
)
, Plus
, Number 6
)
)
, Plus
, Number 2
)
, Plus
, Number 4
)
, Times
, Number 2
)
41 changes: 41 additions & 0 deletions .golden/Day18.Solution.parseExpression_example_advanced_6/golden
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
BinaryOp
( BinaryOp
( BinaryOp
( BinaryOp
( BinaryOp
( BinaryOp
( Number 2
, Plus
, Number 4
)
, Times
, Number 9
)
, Times
, BinaryOp
( BinaryOp
( BinaryOp
( Number 6
, Plus
, Number 9
)
, Times
, BinaryOp
( Number 8
, Plus
, Number 6
)
)
, Plus
, Number 6
)
)
, Plus
, Number 2
)
, Plus
, Number 4
)
, Times
, Number 2
)
5 changes: 5 additions & 0 deletions .golden/Day18.Solution.parseExpression_example_basic_0/actual
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
BinaryOp
( Number 1
, Plus
, Number 2
)
5 changes: 5 additions & 0 deletions .golden/Day18.Solution.parseExpression_example_basic_0/golden
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
BinaryOp
( Number 1
, Plus
, Number 2
)
Loading

0 comments on commit 6ec6bf7

Please sign in to comment.