Load all fixture grammars dynamically
This way the build doesn't take forever any time a single grammar has been regenerated.
This commit is contained in:
parent
5c3c1dd0bd
commit
a8292f4fe9
10 changed files with 119 additions and 143 deletions
|
|
@ -2,6 +2,8 @@
|
|||
|
||||
set -e
|
||||
|
||||
cargo build --release
|
||||
|
||||
root_dir=$PWD
|
||||
tree_sitter=${root_dir}/target/release/tree-sitter
|
||||
grammars_dir=${root_dir}/test/fixtures/grammars
|
||||
|
|
@ -19,6 +21,10 @@ grammar_names=(
|
|||
rust
|
||||
)
|
||||
|
||||
if [[ "$#" > 0 ]]; then
|
||||
grammar_names=($1)
|
||||
fi
|
||||
|
||||
for grammar_name in "${grammar_names[@]}"; do
|
||||
echo "Regenerating ${grammar_name} parser"
|
||||
cd ${grammars_dir}/${grammar_name}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue