27 lines
799 B
Bash
Executable File
27 lines
799 B
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
function error_handler() {
|
|
>&2 echo "Exited with BAD EXIT CODE '${2}' in ${0} script at line: ${1}."
|
|
exit "$2"
|
|
}
|
|
trap 'error_handler ${LINENO} $?' ERR
|
|
set -o errtrace -o errexit -o nounset -o pipefail
|
|
|
|
# function to update single file
|
|
function update_file() {
|
|
markdown_to_ventilated_prose.py "$1" "$1"
|
|
./bin/edit "$1"
|
|
markdown_to_ventilated_prose.py "$1" "$1"
|
|
}
|
|
|
|
# while IFS= read -r -d '' file; do
|
|
# update_file "$file"
|
|
# done < <(find . -type f -name "*.md" -print0)
|
|
|
|
echo 'fyi, running test files, not all files'
|
|
# these are long, problematic files, good for testing.
|
|
# not sure why documentation.md likes to get lots of extra newlines added.
|
|
for file in Getting_Started/quick_start.md Support/FAQ.md documentation/documentation.md; do
|
|
update_file "$file"
|
|
done
|