Add utility script to quickly set up part two
This commit is contained in:
parent
68fa7fa6f5
commit
c737e0ed67
13
2022/copy.sh
Executable file
13
2022/copy.sh
Executable file
@ -0,0 +1,13 @@
|
||||
#!/bin/bash
|
||||
set -euo pipefail
|
||||
|
||||
if [[ "$#" != "1" ]]; then
|
||||
echo " Usage: ./copy.sh <day>"
|
||||
echo "Example: ./copy.sh 13"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
from="day${1}-part1"
|
||||
to="day${1}-part2"
|
||||
cp -r "$from" "$to"
|
||||
sed -i -e "s/$from/$to/g" "$to/Cargo.toml"
|
||||
Loading…
Reference in New Issue
Block a user