setting up some java boilerplate

This commit is contained in:
2025-11-30 15:26:36 -05:00
parent 3d449572c0
commit 3eb6aa5002
6 changed files with 51 additions and 9 deletions

8
run.sh
View File

@@ -1,16 +1,14 @@
#!/bin/bash
__year=2024
__day="${1}"
if [ -z "${__day}" ]; then
__day=$(date '+%d')
fi
padded=$(printf "%02g" ${__day})
if [ -f "${padded}/index.ts" ]; then
cd $padded
npx tsx "index.ts" 2>/dev/null
if [ -f "src/Day${padded}.java" ]; then
cd src
java "Day${padded}.java" 2>/dev/null
cd - >/dev/null
else
echo "day not found"