Skip to content

Commit 723d721

Browse files
committed
REMOVE THIS COMMIT
1 parent d9c920b commit 723d721

File tree

1 file changed

+50
-48
lines changed

1 file changed

+50
-48
lines changed

check-grammars-crates.sh

Lines changed: 50 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -3,54 +3,56 @@
33
# Stop at the first error
44
set -e
55

6-
# Get all tree-sitter crates from the analyzed branch Cargo.toml
7-
TS_CRATES=`grep "tree-sitter-*" Cargo.toml | tr -d ' '`
8-
9-
# Disable/Enable CI flag
10-
RUN_CI="no"
11-
12-
# Temporary master branch Cargo.toml filename
13-
MASTER_CARGO_TOML="master-cargo.toml"
14-
15-
# Download master branch Cargo.toml and save it in a temporary file
16-
wget -LqO - https://raw.githubusercontent.com/mozilla/rust-code-analysis/master/Cargo.toml | tr -d ' ' > $MASTER_CARGO_TOML
17-
18-
# For each tree-sitter crate from the analyzed branch Cargo.toml
19-
for TS_CRATE in $TS_CRATES
20-
do
21-
# Get the name of the current crate
22-
TS_CRATE_NAME=`echo $TS_CRATE | cut -f1 -d "="`
23-
24-
# Get the crate name from the master branch Cargo.toml
25-
MASTER_TS_CRATE_NAME=`grep $TS_CRATE_NAME $MASTER_CARGO_TOML | head -n 1 | cut -f1 -d "="`
26-
27-
# If the current crate name is not present in master branch, skip to the next crate
28-
if [ -z "$MASTER_TS_CRATE_NAME" ]
29-
then
30-
continue
31-
fi
32-
33-
# Get the same crate from the master branch Cargo.toml
34-
MASTER_TS_CRATE=`grep $TS_CRATE $MASTER_CARGO_TOML | head -n 1`
35-
36-
# If the current crate has been updated, save the crate name and break the loop
37-
if [ -z "$MASTER_TS_CRATE" ]
38-
then
39-
# Enable CI flag
40-
RUN_CI="yes"
41-
# Name of tree-sitter crate
42-
TREE_SITTER_CRATE=$TS_CRATE_NAME
43-
break
44-
fi
45-
done
46-
47-
# Remove temporary master branch Cargo.toml file
48-
rm -rf $MASTER_CARGO_TOML
49-
50-
# If any crates have been updated, exit the script
51-
if [ "$RUN_CI" = "no" ]; then
52-
exit 0
53-
fi
6+
## Get all tree-sitter crates from the analyzed branch Cargo.toml
7+
#TS_CRATES=`grep "tree-sitter-*" Cargo.toml | tr -d ' '`
8+
#
9+
## Disable/Enable CI flag
10+
#RUN_CI="no"
11+
#
12+
## Temporary master branch Cargo.toml filename
13+
#MASTER_CARGO_TOML="master-cargo.toml"
14+
#
15+
## Download master branch Cargo.toml and save it in a temporary file
16+
#wget -LqO - https://raw.githubusercontent.com/mozilla/rust-code-analysis/master/Cargo.toml | tr -d ' ' > $MASTER_CARGO_TOML
17+
#
18+
## For each tree-sitter crate from the analyzed branch Cargo.toml
19+
#for TS_CRATE in $TS_CRATES
20+
#do
21+
# # Get the name of the current crate
22+
# TS_CRATE_NAME=`echo $TS_CRATE | cut -f1 -d "="`
23+
#
24+
# # Get the crate name from the master branch Cargo.toml
25+
# MASTER_TS_CRATE_NAME=`grep $TS_CRATE_NAME $MASTER_CARGO_TOML | head -n 1 | cut -f1 -d "="`
26+
#
27+
# # If the current crate name is not present in master branch, skip to the next crate
28+
# if [ -z "$MASTER_TS_CRATE_NAME" ]
29+
# then
30+
# continue
31+
# fi
32+
#
33+
# # Get the same crate from the master branch Cargo.toml
34+
# MASTER_TS_CRATE=`grep $TS_CRATE $MASTER_CARGO_TOML | head -n 1`
35+
#
36+
# # If the current crate has been updated, save the crate name and break the loop
37+
# if [ -z "$MASTER_TS_CRATE" ]
38+
# then
39+
# # Enable CI flag
40+
# RUN_CI="yes"
41+
# # Name of tree-sitter crate
42+
# TREE_SITTER_CRATE=$TS_CRATE_NAME
43+
# break
44+
# fi
45+
#done
46+
#
47+
## Remove temporary master branch Cargo.toml file
48+
#rm -rf $MASTER_CARGO_TOML
49+
#
50+
## If any crates have been updated, exit the script
51+
#if [ "$RUN_CI" = "no" ]; then
52+
# exit 0
53+
#fi
54+
55+
TREE_SITTER_CRATE="tree-sitter-javascript"
5456

5557
# Install json minimal tests
5658
JMT_LINK="https://github.com/Luni-4/json-minimal-tests/releases/download"

0 commit comments

Comments
 (0)