From eeff97950f7ccfd5b2f73b48f7267bd0df5e4bfb Mon Sep 17 00:00:00 2001 From: Bennet Bo Fenner Date: Mon, 6 Jul 2026 18:10:48 +0200 Subject: [PATCH] Add license to tooling/lints crate (#60468) Seeing `script/check-license` fail because we forgot to add a license in #58496 > Error: tooling/lints does not contain a LICENSE-GPL or LICENSE-APACHE symlink Release Notes: - N/A --- .github/workflows/run_tests.yml | 2 +- tooling/lints/LICENSE-APACHE | 1 + tooling/xtask/src/tasks/workflows/run_tests.rs | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) create mode 120000 tooling/lints/LICENSE-APACHE diff --git a/.github/workflows/run_tests.yml b/.github/workflows/run_tests.yml index 055279340ce..1b8f416baab 100644 --- a/.github/workflows/run_tests.yml +++ b/.github/workflows/run_tests.yml @@ -75,7 +75,7 @@ jobs: # Map directory names to package names FILE_CHANGED_PKGS="" for dir in $CHANGED_DIRS; do - pkg=$(echo "$DIR_TO_PKG" | grep "^${dir}=" | cut -d= -f2 | head -1) + pkg=$(echo "$DIR_TO_PKG" | grep "^${dir}=" | cut -d= -f2 | head -1 || true) if [ -n "$pkg" ]; then FILE_CHANGED_PKGS=$(printf '%s\n%s' "$FILE_CHANGED_PKGS" "$pkg") else diff --git a/tooling/lints/LICENSE-APACHE b/tooling/lints/LICENSE-APACHE new file mode 120000 index 00000000000..1cd601d0a3a --- /dev/null +++ b/tooling/lints/LICENSE-APACHE @@ -0,0 +1 @@ +../../LICENSE-APACHE \ No newline at end of file diff --git a/tooling/xtask/src/tasks/workflows/run_tests.rs b/tooling/xtask/src/tasks/workflows/run_tests.rs index c745d0e3852..84dc6692392 100644 --- a/tooling/xtask/src/tasks/workflows/run_tests.rs +++ b/tooling/xtask/src/tasks/workflows/run_tests.rs @@ -221,7 +221,7 @@ fn orchestrate_impl(rules: &[&PathCondition], target: OrchestrateTarget) -> Name # Map directory names to package names FILE_CHANGED_PKGS="" for dir in $CHANGED_DIRS; do - pkg=$(echo "$DIR_TO_PKG" | grep "^${dir}=" | cut -d= -f2 | head -1) + pkg=$(echo "$DIR_TO_PKG" | grep "^${dir}=" | cut -d= -f2 | head -1 || true) if [ -n "$pkg" ]; then FILE_CHANGED_PKGS=$(printf '%s\n%s' "$FILE_CHANGED_PKGS" "$pkg") else