···11-set dotenv-load
22-set quiet
33-set shell := ["fish", "-c"]
44-55-year := env_var("YEAR")
66-session := env_var("SESSION")
77-88-[no-cd]
99-default: p1 p2
1010-1111-all:
1212- #!/usr/bin/env fish
1313- for file in (ls)
1414- if test -d $file
1515- echo "Day $file"
1616- just run $file
1717- end
1818- end
1919-2020-[no-cd]
2121-p1 input="input": (do "p1" input)
2222-2323-[no-cd]
2424-p2 input="input": (do "p2" input)
2525-2626-[no-cd]
2727-do part input:
2828- #!/usr/bin/env fish
2929- if test -f {{part}}.hs
3030- ghc {{part}} -O -outputdir.{{part}} > /dev/null
3131- and time ./{{part}} < {{input}}
3232- else if ls | rg "\.cabal\$" -q
3333- cabal build {{part}} > /dev/null
3434- and time cabal run {{part}} < {{input}}
3535- else if test -f {{part}}.fish
3636- time ./{{part}}.fish < {{input}}
3737- else
3838- echo "Current directory does not contain known solution configuration"
3939- exit 1
4040- end
4141-4242-run day:
4343- cd {{day}} && just
4444-4545-get day:
4646- mkdir -p {{day}}
4747- curl https://adventofcode.com/{{year}}/day/{{day}}/input \
4848- -X GET \
4949- -H "Cookie: session={{session}}" \
5050- -o {{day}}/input
-2
2022/README.md
···2233I return with a new language per day again. Maybe this year I'll remember to keep doing them.
4455-1212704-0a296724
66-75## Reflection
869725 languages is... a lot of languages. Started with ones I was familiar with but
···11-set dotenv-load
22-set quiet
33-set shell := ["fish", "-c"]
44-55-year := env_var("YEAR")
66-session := env_var("SESSION")
77-88-[no-cd]
99-default: p1 p2
1010-1111-all:
1212- #!/usr/bin/env fish
1313- for file in (ls)
1414- if test -d $file
1515- echo "Day $file"
1616- just run $file
1717- end
1818- end
1919-2020-[no-cd]
2121-p1 input="input": (do "p1" input)
2222-2323-[no-cd]
2424-p2 input="input": (do "p2" input)
2525-2626-[no-cd]
2727-do part input:
2828- #!/usr/bin/env fish
2929- if test -f {{part}}.hs
3030- ghc {{part}} -O -outputdir.{{part}} > /dev/null
3131- and time ./{{part}} < {{input}}
3232- else if ls | rg "\.cabal\$" -q
3333- cabal build {{part}} > /dev/null
3434- and time cabal run {{part}} < {{input}}
3535- else if test -f {{part}}.fish
3636- time ./{{part}}.fish < {{input}}
3737- else if test -f {{part}}.tri
3838- time trilogy run ./{{part}}.tri < {{input}}
3939- else
4040- echo "Current directory does not contain known solution configuration"
4141- exit 1
4242- end
4343-4444-run day:
4545- cd {{day}} && just
4646-4747-get day:
4848- mkdir -p {{day}}
4949- curl https://adventofcode.com/{{year}}/day/{{day}}/input \
5050- -X GET \
5151- -H "Cookie: session={{session}}" \
5252- -o {{day}}/input
+1-4
2023/README.md
···11# Advent of Code 2023
2233-It's all [Trilogy](https://github.com/foxfriends/trilogy) this year, assuming
44-the language continues to function for the duration.
55-66-1212704-0a296724
33+It's all [Trilogy](https://github.com/foxfriends/trilogy) this year.