2021-11-09 23:55:03 +01:00
|
|
|
#!/usr/bin/env bash
|
2019-10-10 23:57:21 +02:00
|
|
|
|
2022-10-30 20:49:50 +01:00
|
|
|
set -eu
|
|
|
|
|
|
|
|
count=$(echo $(( $(grep -E "\[Exercise\]|</summary>" -c README.md topics/*/README.md | awk -F: '{ s+=$2 } END { print s }' ))))
|
|
|
|
|
|
|
|
echo "There are $count questions and exercises"
|
|
|
|
|
|
|
|
sed -i "s/currently \*\*[0-9]*\*\*/currently \*\*$count\\**/" README.md
|