15 lines
250 B
Bash
Executable File
15 lines
250 B
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
year=$1
|
|
day=$2
|
|
|
|
mkdir -p $year/$day
|
|
source_file=$(ls $year/$day/*.rb)
|
|
|
|
if [[ -z $source_file ]] ; then
|
|
echo "No ruby source file found in $year/$day"
|
|
exit 1
|
|
fi
|
|
|
|
time (cat ../data/$year/$day/input.txt | ruby $source_file)
|