From 5b79345e68914a0a1e95966ac3e39c680d152e7e Mon Sep 17 00:00:00 2001 From: David Marinho Date: Wed, 11 Jan 2023 14:53:37 +0000 Subject: [PATCH] added github_token in all requests to github api in action.yml --- action.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/action.yml b/action.yml index 40878a3..453009a 100644 --- a/action.yml +++ b/action.yml @@ -119,7 +119,7 @@ runs: cd /tmp curl -sfL https://raw.githubusercontent.com/securego/gosec/master/install.sh | sh -s v2.13.1 chmod +x ./bin/gosec - curl -fsSL https://api.github.com/repos/codacy/codacy-gosec/releases/latest \ + curl -fsSL https://api.github.com/repos/codacy/codacy-gosec/releases/latest -H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" \ | grep "browser_download_url" | grep -v "browser_download_url.*jar" \ | cut -d '"' -f 4 \ | xargs -L 1 curl -fsSL -o /tmp/codacy-gosec @@ -146,13 +146,13 @@ runs: if [ "${{ inputs.run-staticcheck }}" == "true" ]; then cd /tmp - curl -fsSL https://api.github.com/repos/dominikh/go-tools/releases/latest \ + curl -fsSL https://api.github.com/repos/dominikh/go-tools/releases/latest -H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" \ | grep -E "browser_download_url.*staticcheck_linux_amd64.tar.gz\"$" \ | cut -d '"' -f 4 \ | xargs -L 1 curl -fsSL -o /tmp/staticcheck_linux_amd64.tar.gz tar -xvf /tmp/staticcheck_linux_amd64.tar.gz staticcheck/staticcheck chmod +x ./staticcheck/staticcheck - curl -fsSL https://api.github.com/repos/codacy/codacy-staticcheck/releases/latest \ + curl -fsSL https://api.github.com/repos/codacy/codacy-staticcheck/releases/latest -H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" \ | grep "browser_download_url" | grep -v "browser_download_url.*jar" \ | cut -d '"' -f 4 \ | xargs -L 1 curl -fsSL -o /tmp/codacy-staticcheck @@ -179,7 +179,7 @@ runs: if [ -n "${{ inputs.clang-tidy-output }}" ]; then cd /tmp - curl -fsSL https://api.github.com/repos/codacy/codacy-clang-tidy/releases/latest \ + curl -fsSL https://api.github.com/repos/codacy/codacy-clang-tidy/releases/latest -H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" \ | grep "browser_download_url" | grep -v "browser_download_url.*jar" \ | cut -d '"' -f 4 \ | xargs -L 1 curl -fsSL -o /tmp/codacy-clang-tidy @@ -205,7 +205,7 @@ runs: if [ -n "${{ inputs.faux-pas-output }}" ]; then cd /tmp - curl -fsSL https://api.github.com/repos/codacy/codacy-faux-pas/releases/latest \ + curl -fsSL https://api.github.com/repos/codacy/codacy-faux-pas/releases/latest -H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" \ | grep "browser_download_url" | grep -v "browser_download_url.*jar" \ | cut -d '"' -f 4 \ | xargs -L 1 curl -fsSL -o /tmp/codacy-faux-pas