2021-08-09 12:56:48 -04:00
|
|
|
#!/usr/bin/env bash
|
|
|
|
|
2021-08-10 03:35:14 -04:00
|
|
|
set -Eeo pipefail
|
2021-08-09 12:56:48 -04:00
|
|
|
|
|
|
|
pushd "$(dirname "$0")" >/dev/null
|
|
|
|
|
|
|
|
cargo build --manifest-path c14n/Cargo.toml --release
|
2021-08-10 03:35:14 -04:00
|
|
|
cargo build --manifest-path charlines/Cargo.toml --release
|
2021-08-09 12:56:48 -04:00
|
|
|
|
|
|
|
for f in outputs/*/*; do
|
2021-08-10 03:35:14 -04:00
|
|
|
out=$(c14n/target/release/c14n < "$f")
|
|
|
|
if [[ "$CHARLINES" == "1" ]]; then
|
|
|
|
out=$(charlines/target/release/charlines <<< "$out")
|
|
|
|
fi
|
|
|
|
cat <<< "$out" > "$f"
|
2021-08-09 12:56:48 -04:00
|
|
|
done
|
|
|
|
|
|
|
|
popd >/dev/null
|