Bash script that generates the directory with the files inside for input and parts one and two.

This commit is contained in:
kplaczek
2021-12-18 11:48:56 +01:00
parent 06ca3641aa
commit 9301293df9

14
aoc.sh Normal file
View File

@@ -0,0 +1,14 @@
#!/bin/bash
day=$(date +'%d')
mkdir -p $day
touch "${day}/input"
touch "${day}/input.sample"
touch "${day}/part1.php"
echo "<?php
\$input = file('input', FILE_IGNORE_NEW_LINES | FILE_SKIP_EMPTY_LINES);
" >> "${day}/part1.php"
touch "${day}/part2.php"
echo "<?php
\$input = file('input', FILE_IGNORE_NEW_LINES | FILE_SKIP_EMPTY_LINES);
" >> "${day}/part2.php"