From de9d3b42ef1a20bf5f26bf4e1aeb0d9692ac5abe Mon Sep 17 00:00:00 2001 From: iphydf Date: Tue, 31 Dec 2024 12:18:26 +0000 Subject: [PATCH] chore: Add hub-restyled link to restyled errors. Also, curl doesn't actually work without GH token, so tell the user to download the zip, instead. --- .github/workflows/common-ci.yml | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/.github/workflows/common-ci.yml b/.github/workflows/common-ci.yml index 6d63c21..38377ee 100644 --- a/.github/workflows/common-ci.yml +++ b/.github/workflows/common-ci.yml @@ -13,7 +13,7 @@ jobs: wget --retry-connrefused --waitretry=1 --read-timeout=20 --timeout=15 -t 3 -O buildifier "$BUILDIFIER_URL" chmod +x buildifier - name: Check - run: ./buildifier --lint=warn --warnings=all -mode diff $(find . -type f -name "WORKSPACE" -or -name "BUILD.*") + run: ./buildifier --lint=warn --warnings=all -mode diff $(find . -type f -name "WORKSPACE" -or -name "BUILD.*" -or -name "*.BUILD" -or -name "*.bazel") restyled: runs-on: ubuntu-22.04 @@ -43,9 +43,14 @@ jobs: cat >>"$GITHUB_STEP_SUMMARY" <<'EOM' ## Restyled - To apply these fixes locally, run: + To apply these fixes locally, either: - curl '${{ steps.upload.outputs.artifact-url }}' | unzip -p - restyled.diff | git am + Download '${{ steps.upload.outputs.artifact-url }}' with the web browser + $ cat restyled.diff.zip | unzip -p - restyled.diff | git am + + Or use the [hub-restyled](https://github.com/TokTok/hs-github-tools/blob/master/tools/hub-restyled) tool: + + $ hub-restyled EOM exit 1