From e7c62d0e7f89df0bbb8ab8bff019671aa2933b86 Mon Sep 17 00:00:00 2001 From: Thomas Voss Date: Tue, 9 Dec 2025 10:49:51 +0100 Subject: Make fetch-inputs MacOS-friendly --- fetch-inputs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'fetch-inputs') diff --git a/fetch-inputs b/fetch-inputs index 4c3b00e..3509e89 100755 --- a/fetch-inputs +++ b/fetch-inputs @@ -2,12 +2,13 @@ cd "$(dirname "$0")" + find . \ - -regextype egrep \ -mindepth 2 \ -maxdepth 2 \ -type d \ - -regex '\./[0-9]{4}/[0-9]{2}' \ + -regex '\./[0-9]\{4\}/[0-9]\{2\}' \ + | sort \ | while IFS=/ read _ y d do file=$y/$d/input @@ -16,4 +17,4 @@ do wget -q --load-cookies=.cookies -O "$file" \ "https://adventofcode.com/$y/day/${d#0}/input" >&2 printf 'DONE\n' >&2 -done \ No newline at end of file +done -- cgit v1.2.3