Speedup codegen by caching tools/codegen compilation (#554)

This commit is contained in:
Jiahao XU
2024-06-22 13:43:03 +10:00
committed by GitHub
parent 315e996a95
commit 4558bb807b
3 changed files with 38 additions and 24 deletions

View File

@@ -10,11 +10,11 @@ cd "$(dirname "$0")"/..
# ./tools/manifest.sh [PACKAGE [VERSION_REQ]]
if [[ $# -gt 0 ]]; then
cargo +nightly run --manifest-path tools/codegen/Cargo.toml --release -- "$@"
cargo run --manifest-path tools/codegen/Cargo.toml --release -- "$@"
exit 0
fi
for manifest in tools/codegen/base/*.json; do
package=$(basename "${manifest%.*}")
cargo +nightly run --manifest-path tools/codegen/Cargo.toml --release -- "${package}" latest
cargo run --manifest-path tools/codegen/Cargo.toml --release -- "${package}" latest
done