From 9bdb224631f0262fde2821869128bc76279b3eb6 Mon Sep 17 00:00:00 2001 From: garronej Date: Wed, 1 Jun 2022 05:51:33 +0200 Subject: [PATCH] Prevent rate limite in CI by authenticating --- .github/workflows/ci.yaml | 2 ++ src/bin/tools/createOctokit.ts | 7 ------- 2 files changed, 2 insertions(+), 7 deletions(-) delete mode 100644 src/bin/tools/createOctokit.ts diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index c50b3ddb..dcd717ed 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -25,6 +25,8 @@ jobs: test: runs-on: macos-10.15 needs: test_formatting + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} strategy: matrix: node: [ '15', '14' ] diff --git a/src/bin/tools/createOctokit.ts b/src/bin/tools/createOctokit.ts deleted file mode 100644 index a3eb5395..00000000 --- a/src/bin/tools/createOctokit.ts +++ /dev/null @@ -1,7 +0,0 @@ -import { Octokit } from "@octokit/rest"; - -export function createOctokit(params: { github_token: string }) { - const { github_token } = params; - - return new Octokit({ ...(github_token !== "" ? { "auth": github_token } : {}) }); -}