summaryrefslogtreecommitdiff
path: root/run.sh
diff options
context:
space:
mode:
authorMike Vink <ivi@vinkies.net>2023-12-02 22:10:34 +0100
committerMike Vink <ivi@vinkies.net>2023-12-10 20:35:22 +0100
commit9dbbbc4fe5d85e917e8efa977501b4ebacb349be (patch)
tree06339fa764a7dacd9b1f6e2093e0e9cdba4c2f8b /run.sh
use tree for day1, why not 🐒
Diffstat (limited to 'run.sh')
-rw-r--r--run.sh16
1 files changed, 16 insertions, 0 deletions
diff --git a/run.sh b/run.sh
new file mode 100644
index 0000000..9582548
--- /dev/null
+++ b/run.sh
@@ -0,0 +1,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