Apache DataFusion SQL Query Engine
unify the prettier versions (#20167)
Sergey Zhukovc9e7137dce27
diff --git a/ci/scripts/check_examples_docs.sh b/ci/scripts/check_examples_docs.shindex 01cd6b930f..4b5699380d 100755--- a/ci/scripts/check_examples_docs.sh+++ b/ci/scripts/check_examples_docs.sh@@ -36,6 +36,7 @@ ROOT_DIR="$(git rev-parse --show-toplevel)"EXAMPLES_DIR="$ROOT_DIR/datafusion-examples"README="$EXAMPLES_DIR/README.md"README_NEW="$EXAMPLES_DIR/README-NEW.md"+PRETTIER_VERSION="2.7.1"echo "▶ Generating examples README (Rust generator)…"cargo run --quiet \@@ -43,8 +44,8 @@ cargo run --quiet \--bin examples-docs \> "$README_NEW"-echo "▶ Formatting generated README with Prettier…"-npx [email protected] \+echo "▶ Formatting generated README with prettier ${PRETTIER_VERSION}…"+npx "prettier@${PRETTIER_VERSION}" \--parser markdown \--write "$README_NEW"@@ -60,7 +61,7 @@ if ! diff -u "$README" "$README_NEW" > /tmp/examples-readme.diff; thenecho "To update the README locally, run:"echo ""echo " cargo run --bin examples-docs \\"- echo " | npx [email protected] --parser markdown --write \\"+ echo " | npx prettier@${PRETTIER_VERSION} --parser markdown --write \\"echo " > datafusion-examples/README.md"echo ""echo "Diff:"diff --git a/dev/update_config_docs.sh b/dev/update_config_docs.shindex 90bbc5d3ba..fafe6df2f5 100755--- a/dev/update_config_docs.sh+++ b/dev/update_config_docs.sh@@ -26,7 +26,7 @@ cd "${SOURCE_DIR}/../" && pwdTARGET_FILE="docs/source/user-guide/configs.md"PRINT_CONFIG_DOCS_COMMAND="cargo run --manifest-path datafusion/core/Cargo.toml --bin print_config_docs"PRINT_RUNTIME_CONFIG_DOCS_COMMAND="cargo run --manifest-path datafusion/core/Cargo.toml --bin print_runtime_config_docs"-+PRETTIER_VERSION="2.7.1"echo "Inserting header"cat <<'EOF' > "$TARGET_FILE"@@ -238,7 +238,7 @@ Enables the experimental Piecewise Merge Join algorithm.EOF-echo "Running prettier"-npx [email protected] --write "$TARGET_FILE"+echo "Running prettier ${PRETTIER_VERSION}"+npx "prettier@${PRETTIER_VERSION}" --write "$TARGET_FILE"echo "'$TARGET_FILE' successfully updated!"diff --git a/dev/update_function_docs.sh b/dev/update_function_docs.shindex 63f4f2475c..7233bb1344 100755--- a/dev/update_function_docs.sh+++ b/dev/update_function_docs.sh@@ -26,6 +26,7 @@ cd "${SOURCE_DIR}/../" && pwdTARGET_FILE="docs/source/user-guide/sql/aggregate_functions.md"PRINT_AGGREGATE_FUNCTION_DOCS_COMMAND="cargo run --manifest-path datafusion/core/Cargo.toml --bin print_functions_docs -- aggregate"+PRETTIER_VERSION="2.7.1"echo "Inserting header"cat <<'EOF' > "$TARGET_FILE"@@ -113,8 +114,8 @@ EOFecho "Running CLI and inserting aggregate function docs table"$PRINT_AGGREGATE_FUNCTION_DOCS_COMMAND >> "$TARGET_FILE"-echo "Running prettier"-npx [email protected] --write "$TARGET_FILE"+echo "Running prettier ${PRETTIER_VERSION}"+npx "prettier@${PRETTIER_VERSION}" --write "$TARGET_FILE"echo "'$TARGET_FILE' successfully updated!"@@ -157,8 +158,8 @@ EOFecho "Running CLI and inserting scalar function docs table"$PRINT_SCALAR_FUNCTION_DOCS_COMMAND >> "$TARGET_FILE"-echo "Running prettier"-npx [email protected] --write "$TARGET_FILE"+echo "Running prettier ${PRETTIER_VERSION}"+npx "prettier@${PRETTIER_VERSION}" --write "$TARGET_FILE"echo "'$TARGET_FILE' successfully updated!"@@ -335,7 +336,7 @@ EOFecho "Running CLI and inserting window function docs table"$PRINT_WINDOW_FUNCTION_DOCS_COMMAND >> "$TARGET_FILE"-echo "Running prettier"-npx [email protected] --write "$TARGET_FILE"+echo "Running prettier ${PRETTIER_VERSION}"+npx "prettier@${PRETTIER_VERSION}" --write "$TARGET_FILE"echo "'$TARGET_FILE' successfully updated!"