summaryrefslogtreecommitdiff
path: root/run.sh
blob: 958254869d34abee74c0c91b72b85bcb88c4e04c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#!/bin/sh
day=$1
token=$2
inputdir="input/$day"
mkdir -p $inputdir
if ! [ -f "$inputdir/in.txt" ]; then
    curl \
        -s \
        -o input/$day/in.txt \
        --cookie "session=$token" \
        -- \
        https://adventofcode.com/2023/day/$day/input
else
    echo "already got input!"
fi
cargo run --bin main