Consolidate tools directories, move things to internal/tools (#2534)

This commit is contained in:
Bogdan Drutu 2022-05-18 23:35:57 -07:00 committed by GitHub
parent fde6ac6bbb
commit a7be53d4c8
2 changed files with 5 additions and 5 deletions

View File

@ -85,7 +85,7 @@ table-check:
.PHONY: schema-check .PHONY: schema-check
schema-check: schema-check:
cd tools && ./schema_check.sh $(TOOLS_DIR)/schema_check.sh
# Run all checks in order of speed / likely failure. # Run all checks in order of speed / likely failure.
.PHONY: check .PHONY: check

View File

@ -11,11 +11,11 @@ BUILD_TOOL_SCHEMAS_VERSION=0.11.0
# List of vesions that do not require or have a schema. # List of vesions that do not require or have a schema.
declare -a skip_versions=("1.0.0" "1.0.1" "1.1.0" "1.2.0" "1.3.0" "1.6.0") declare -a skip_versions=("1.0.0" "1.0.1" "1.1.0" "1.2.0" "1.3.0" "1.6.0")
schemas_dir="../schemas" root_dir=$PWD
current_dir=$PWD schemas_dir=$root_dir/schemas
# Find all version sections in CHANGELOG that start with a number in 1..9 range. # Find all version sections in CHANGELOG that start with a number in 1..9 range.
grep -o -e '## v[1-9].*\s' ../CHANGELOG.md | grep -o '[1-9].*' | while read ver; do grep -o -e '## v[1-9].*\s' $root_dir/CHANGELOG.md | grep -o '[1-9].*' | while read ver; do
if [[ " ${skip_versions[*]} " == *" $ver "* ]]; then if [[ " ${skip_versions[*]} " == *" $ver "* ]]; then
# Skip this version, it does not need a schema file. # Skip this version, it does not need a schema file.
continue continue
@ -52,7 +52,7 @@ for file in $schemas_dir/*; do
exit 2 exit 2
fi fi
docker run -v $current_dir/../schemas:/schemas \ docker run -v $schemas_dir:/schemas \
otel/build-tool-schemas:$BUILD_TOOL_SCHEMAS_VERSION --file /schemas/$ver --version=$ver otel/build-tool-schemas:$BUILD_TOOL_SCHEMAS_VERSION --file /schemas/$ver --version=$ver
echo "OK" echo "OK"