From 3e8166ab86d79015d39fdc60dd01bfaf2acfcd78 Mon Sep 17 00:00:00 2001 From: burgholzer Date: Mon, 9 Sep 2024 23:40:54 +0200 Subject: [PATCH] =?UTF-8?q?=F0=9F=9A=B8=20use=20GitHub=20token=20by=20defa?= =?UTF-8?q?ult?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/test-windows.yml | 2 -- .github/workflows/test.yml | 12 ------------ README.md | 13 ------------- action.yml | 1 + 4 files changed, 1 insertion(+), 27 deletions(-) diff --git a/.github/workflows/test-windows.yml b/.github/workflows/test-windows.yml index d7fc746..06be023 100644 --- a/.github/workflows/test-windows.yml +++ b/.github/workflows/test-windows.yml @@ -23,7 +23,5 @@ jobs: } - name: Setup uv uses: ./ - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - run: uv sync working-directory: __tests__\fixtures\uv-project diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 3eda544..bbf2658 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -30,8 +30,6 @@ jobs: - uses: actions/checkout@v4 - name: Install default version uses: ./ - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - run: uv sync working-directory: __tests__/fixtures/uv-project test-specific-version: @@ -46,7 +44,6 @@ jobs: uses: ./ with: version: ${{ matrix.uv-version }} - github-token: ${{ secrets.GITHUB_TOKEN }} - run: uv sync working-directory: __tests__/fixtures/uv-project test-checksum: @@ -69,15 +66,6 @@ jobs: with: version: "0.3.2" checksum: ${{ matrix.checksum }} - github-token: ${{ secrets.GITHUB_TOKEN }} - test-without-github-token: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - name: Install default version - uses: ./ - - run: uv sync - working-directory: __tests__/fixtures/uv-project test-uvx: runs-on: ubuntu-latest steps: diff --git a/README.md b/README.md index 322a5ad..156407e 100644 --- a/README.md +++ b/README.md @@ -17,7 +17,6 @@ Set up your GitHub Actions workflow with a specific version of [uv](https://docs - [Enable Caching](#enable-caching) - [Local cache path](#local-cache-path) - [Cache dependency glob](#cache-dependency-glob) - - [API rate limit](#api-rate-limit) - [How it works](#how-it-works) - [FAQ](#faq) @@ -135,18 +134,6 @@ changes. The glob matches files relative to the repository root. '**pyproject.toml' ``` -### API rate limit - -To avoid hitting the `API rate limit exceeded` error, supply a GitHub token via the `github-token` -input. - -```yaml -- name: Install uv and supply a GitHub token - uses: astral-sh/setup-uv@v2 - with: - github-token: ${{ secrets.GITHUB_TOKEN }} -``` - ## How it works This action downloads uv from the uv repo's official diff --git a/action.yml b/action.yml index b29d5ea..2a383f3 100644 --- a/action.yml +++ b/action.yml @@ -13,6 +13,7 @@ inputs: "Used to increase the rate limit when retrieving versions and downloading uv." required: false + default: ${{ github.token }} enable-cache: description: "Enable caching of the uv cache" default: "false"