5
0
mirror of https://github.com/astral-sh/setup-uv.git synced 2025-12-19 11:04:08 +00:00

Compare commits

..

10 Commits
v5.4.2 ... v6.0

Author SHA1 Message Date
Kevin Stillhammer
6b9c6063ab Bump dependencies (#389) 2025-04-29 22:50:17 +02:00
Kevin Stillhammer
ef6bcdff59 Fix default cache dependency glob (#388)
The new default in v6 used illegal patterns and therefore didn't match
requirements files

Fixes: #385
2025-04-29 22:42:06 +02:00
github-actions[bot]
9a311713f4 chore: update known checksums for 0.6.17 (#384)
chore: update known checksums for 0.6.17

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2025-04-25 19:04:33 +00:00
Kevin Stillhammer
c7f87aa956 bump to v6 in README (#382) 2025-04-24 15:29:56 +02:00
Kevin Stillhammer
aadfaf08d6 Change default cache-dependency-glob (#352)
To support more users by default we should support popular dependency
file formats. A quick GitHub search shows ~40k uses of `constraint.txt`
and ~16k uses of `requirements.in`.

Closes: #261
2025-04-24 15:18:27 +02:00
Kevin Stillhammer
a0f9da6273 No default UV_CACHE_DIR on selfhosted runners (#380)
Closes: #371
2025-04-24 15:17:56 +02:00
Kevin Stillhammer
ec4c691628 new inputs activate-environment and working-directory (#381)
venv activation was implicit when python-version was supplied. This now
only happens when activate-environment is true. working-directory
controls where we work and thus also where the .venv will be created

Closes: #351
Closes: #271
Closes: #251
Closes: #211
2025-04-24 15:17:35 +02:00
github-actions[bot]
aa1290542e chore: update known checksums for 0.6.16 (#378)
chore: update known checksums for 0.6.16

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2025-04-22 07:39:59 +00:00
github-actions[bot]
fcaddda076 chore: update known checksums for 0.6.15 (#377)
chore: update known checksums for 0.6.15

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2025-04-22 06:20:07 +00:00
Kevin Stillhammer
fb3a0a97fa log info on venv activation (#375)
Make sure we get more info by default instead of just exiting with 1
Contributes to: #374
2025-04-17 21:02:21 +02:00
13 changed files with 811 additions and 375 deletions

View File

@@ -115,7 +115,7 @@ jobs:
id: setup-uv id: setup-uv
uses: ./ uses: ./
with: with:
pyproject-file: "__tests__/fixtures/pyproject-toml-project/pyproject.toml" working-directory: "__tests__/fixtures/pyproject-toml-project"
- name: Correct version gets installed - name: Correct version gets installed
run: | run: |
if [ "$(uv --version)" != "uv 0.5.14" ]; then if [ "$(uv --version)" != "uv 0.5.14" ]; then
@@ -131,9 +131,8 @@ jobs:
id: setup-uv id: setup-uv
uses: ./ uses: ./
with: with:
pyproject-file: "__tests__/fixtures/malformed-pyproject-toml-project/pyproject.toml" working-directory: "__tests__/fixtures/malformed-pyproject-toml-project"
- run: uv sync - run: uv --help
working-directory: __tests__/fixtures/uv-project
test-uv-file-version: test-uv-file-version:
runs-on: ubuntu-latest runs-on: ubuntu-latest
@@ -143,8 +142,7 @@ jobs:
id: setup-uv id: setup-uv
uses: ./ uses: ./
with: with:
pyproject-file: "__tests__/fixtures/uv-toml-project/pyproject.toml" working-directory: "__tests__/fixtures/uv-toml-project"
uv-file: "__tests__/fixtures/uv-toml-project/uv.toml"
- name: Correct version gets installed - name: Correct version gets installed
run: | run: |
if [ "$(uv --version)" != "uv 0.5.15" ]; then if [ "$(uv --version)" != "uv 0.5.15" ]; then
@@ -229,7 +227,7 @@ jobs:
fi fi
test-python-version: test-python-version:
runs-on: ubuntu-latest runs-on: ${{ matrix.os }}
strategy: strategy:
matrix: matrix:
os: [ubuntu-latest, macos-latest, windows-latest] os: [ubuntu-latest, macos-latest, windows-latest]
@@ -246,8 +244,23 @@ jobs:
exit 1 exit 1
fi fi
shell: bash shell: bash
- run: uv sync
working-directory: __tests__/fixtures/uv-project
test-activate-environment:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ ubuntu-latest, macos-latest, windows-latest ]
steps:
- uses: actions/checkout@v4
- name: Install latest version
uses: ./
with:
python-version: 3.13.1t
activate-environment: true
- name: Verify packages can be installed - name: Verify packages can be installed
run: uv pip install --python=3.13.1t pip run: uv pip install pip
shell: bash shell: bash
- name: Verify python version is correct - name: Verify python version is correct
run: | run: |
@@ -397,6 +410,30 @@ jobs:
env: env:
CACHE_HIT: ${{ steps.restore.outputs.cache-hit }} CACHE_HIT: ${{ steps.restore.outputs.cache-hit }}
test-cache-local:
strategy:
matrix:
inputs:
- os: ubuntu-latest
expected-cache-dir: "/home/runner/work/_temp/setup-uv-cache"
- os: windows-latest
expected-cache-dir: "D:\\a\\_temp\\setup-uv-cache"
- os: selfhosted-ubuntu-arm64
expected-cache-dir: "/home/ubuntu/.cache/uv"
runs-on: ${{ matrix.inputs.os }}
steps:
- uses: actions/checkout@v4
- name: Setup with cache
uses: ./
with:
cache-suffix: ${{ github.run_id }}-${{ github.run_attempt }}-test-cache-local
- run: |
if [ "$UV_CACHE_DIR" != "${{ matrix.inputs.expected-cache-dir }}" ]; then
echo "UV_CACHE_DIR is not set to the expected value: $UV_CACHE_DIR"
exit 1
fi
shell: bash
test-setup-cache-local: test-setup-cache-local:
runs-on: selfhosted-ubuntu-arm64 runs-on: selfhosted-ubuntu-arm64
steps: steps:
@@ -508,7 +545,9 @@ jobs:
- test-tool-install - test-tool-install
- test-tilde-expansion-tool-dirs - test-tilde-expansion-tool-dirs
- test-python-version - test-python-version
- test-activate-environment
- test-musl - test-musl
- test-cache-local
- test-restore-cache - test-restore-cache
- test-restore-cache-requirements-txt - test-restore-cache-requirements-txt
- test-restore-cache-dependency-glob - test-restore-cache-dependency-glob

114
README.md
View File

@@ -15,8 +15,9 @@ Set up your GitHub Actions workflow with a specific version of [uv](https://docs
- [Install the latest version](#install-the-latest-version) - [Install the latest version](#install-the-latest-version)
- [Install a specific version](#install-a-specific-version) - [Install a specific version](#install-a-specific-version)
- [Install a version by supplying a semver range or pep440 specifier](#install-a-version-by-supplying-a-semver-range-or-pep440-specifier) - [Install a version by supplying a semver range or pep440 specifier](#install-a-version-by-supplying-a-semver-range-or-pep440-specifier)
- [Install a required-version](#install-a-required-version)
- [Python version](#python-version) - [Python version](#python-version)
- [Activate environment](#activate-environment)
- [Working directory](#working-directory)
- [Validate checksum](#validate-checksum) - [Validate checksum](#validate-checksum)
- [Enable Caching](#enable-caching) - [Enable Caching](#enable-caching)
- [Cache dependency glob](#cache-dependency-glob) - [Cache dependency glob](#cache-dependency-glob)
@@ -36,7 +37,7 @@ Set up your GitHub Actions workflow with a specific version of [uv](https://docs
```yaml ```yaml
- name: Install the latest version of uv - name: Install the latest version of uv
uses: astral-sh/setup-uv@v5 uses: astral-sh/setup-uv@v6
``` ```
If you do not specify a version, this action will look for a [required-version](https://docs.astral.sh/uv/reference/settings/#required-version) If you do not specify a version, this action will look for a [required-version](https://docs.astral.sh/uv/reference/settings/#required-version)
@@ -49,7 +50,7 @@ For an example workflow, see
```yaml ```yaml
- name: Install the latest version of uv - name: Install the latest version of uv
uses: astral-sh/setup-uv@v5 uses: astral-sh/setup-uv@v6
with: with:
version: "latest" version: "latest"
``` ```
@@ -58,7 +59,7 @@ For an example workflow, see
```yaml ```yaml
- name: Install a specific version of uv - name: Install a specific version of uv
uses: astral-sh/setup-uv@v5 uses: astral-sh/setup-uv@v6
with: with:
version: "0.4.4" version: "0.4.4"
``` ```
@@ -71,57 +72,34 @@ to install the latest version that satisfies the range.
```yaml ```yaml
- name: Install a semver range of uv - name: Install a semver range of uv
uses: astral-sh/setup-uv@v5 uses: astral-sh/setup-uv@v6
with: with:
version: ">=0.4.0" version: ">=0.4.0"
``` ```
```yaml ```yaml
- name: Pinning a minor version of uv - name: Pinning a minor version of uv
uses: astral-sh/setup-uv@v5 uses: astral-sh/setup-uv@v6
with: with:
version: "0.4.x" version: "0.4.x"
``` ```
```yaml ```yaml
- name: Install a pep440-specifier-satisfying version of uv - name: Install a pep440-specifier-satisfying version of uv
uses: astral-sh/setup-uv@v5 uses: astral-sh/setup-uv@v6
with: with:
version: ">=0.4.25,<0.5" version: ">=0.4.25,<0.5"
``` ```
### Install a required-version
You can specify a [required-version](https://docs.astral.sh/uv/reference/settings/#required-version)
in either a `uv.toml` or `pyproject.toml` file:
```yaml
- name: Install required-version defined in uv.toml
uses: astral-sh/setup-uv@v5
with:
uv-file: "path/to/uv.toml"
```
```yaml
- name: Install required-version defined in pyproject.toml
uses: astral-sh/setup-uv@v5
with:
pyproject-file: "path/to/pyproject.toml"
```
### Python version ### Python version
You can use the input `python-version` to You can use the input `python-version` to set the environment variable `UV_PYTHON` for the rest of your workflow
- set the environment variable `UV_PYTHON` for the rest of your workflow
- create a new virtual environment with the specified python version
- activate the virtual environment for the rest of your workflow
This will override any python version specifications in `pyproject.toml` and `.python-version` This will override any python version specifications in `pyproject.toml` and `.python-version`
```yaml ```yaml
- name: Install the latest version of uv and set the python version to 3.13t - name: Install the latest version of uv and set the python version to 3.13t
uses: astral-sh/setup-uv@v5 uses: astral-sh/setup-uv@v6
with: with:
python-version: 3.13t python-version: 3.13t
- run: uv pip install --python=3.13t pip - run: uv pip install --python=3.13t pip
@@ -139,13 +117,41 @@ jobs:
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
- name: Install the latest version of uv and set the python version - name: Install the latest version of uv and set the python version
uses: astral-sh/setup-uv@v5 uses: astral-sh/setup-uv@v6
with: with:
python-version: ${{ matrix.python-version }} python-version: ${{ matrix.python-version }}
- name: Test with python ${{ matrix.python-version }} - name: Test with python ${{ matrix.python-version }}
run: uv run --frozen pytest run: uv run --frozen pytest
``` ```
### Activate environment
You can set `activate-environment` to `true` to automatically activate a venv.
This allows directly using it in later steps:
```yaml
- name: Install the latest version of uv and activate the environment
uses: astral-sh/setup-uv@v6
with:
activate-environment: true
- run: uv pip install pip
```
### Working directory
You can set the working directory with the `working-directory` input.
This controls where we look for `pyproject.toml`, `uv.toml` and `.python-version` files
which are used to determine the version of uv and python to install.
It also controls where [the venv gets created](#activate-environment).
```yaml
- name: Install uv based on the config files in the working-directory
uses: astral-sh/setup-uv@v6
with:
working-directory: my/subproject/dir
```
### Validate checksum ### Validate checksum
You can specify a checksum to validate the downloaded executable. Checksums up to the default version You can specify a checksum to validate the downloaded executable. Checksums up to the default version
@@ -154,7 +160,7 @@ are automatically verified by this action. The sha256 hashes can be found on the
```yaml ```yaml
- name: Install a specific version and validate the checksum - name: Install a specific version and validate the checksum
uses: astral-sh/setup-uv@v5 uses: astral-sh/setup-uv@v6
with: with:
version: "0.3.1" version: "0.3.1"
checksum: "e11b01402ab645392c7ad6044db63d37e4fd1e745e015306993b07695ea5f9f8" checksum: "e11b01402ab645392c7ad6044db63d37e4fd1e745e015306993b07695ea5f9f8"
@@ -176,7 +182,7 @@ You can optionally define a custom cache key suffix.
```yaml ```yaml
- name: Enable caching and define a custom cache key suffix - name: Enable caching and define a custom cache key suffix
id: setup-uv id: setup-uv
uses: astral-sh/setup-uv@v5 uses: astral-sh/setup-uv@v6
with: with:
enable-cache: true enable-cache: true
cache-suffix: "optional-suffix" cache-suffix: "optional-suffix"
@@ -204,13 +210,17 @@ changes. If you use relative paths, they are relative to the repository root.
> The default is > The default is
> ```yaml > ```yaml
> cache-dependency-glob: | > cache-dependency-glob: |
> **/requirements*.txt > **/*requirements*.txt
> **/*requirements*.in
> **/*constraints*.txt
> **/*constraints*.in
> **/pyproject.toml
> **/uv.lock > **/uv.lock
> ``` > ```
```yaml ```yaml
- name: Define a cache dependency glob - name: Define a cache dependency glob
uses: astral-sh/setup-uv@v5 uses: astral-sh/setup-uv@v6
with: with:
enable-cache: true enable-cache: true
cache-dependency-glob: "**/pyproject.toml" cache-dependency-glob: "**/pyproject.toml"
@@ -218,7 +228,7 @@ changes. If you use relative paths, they are relative to the repository root.
```yaml ```yaml
- name: Define a list of cache dependency globs - name: Define a list of cache dependency globs
uses: astral-sh/setup-uv@v5 uses: astral-sh/setup-uv@v6
with: with:
enable-cache: true enable-cache: true
cache-dependency-glob: | cache-dependency-glob: |
@@ -228,7 +238,7 @@ changes. If you use relative paths, they are relative to the repository root.
```yaml ```yaml
- name: Define an absolute cache dependency glob - name: Define an absolute cache dependency glob
uses: astral-sh/setup-uv@v5 uses: astral-sh/setup-uv@v6
with: with:
enable-cache: true enable-cache: true
cache-dependency-glob: "/tmp/my-folder/requirements*.txt" cache-dependency-glob: "/tmp/my-folder/requirements*.txt"
@@ -236,7 +246,7 @@ changes. If you use relative paths, they are relative to the repository root.
```yaml ```yaml
- name: Never invalidate the cache - name: Never invalidate the cache
uses: astral-sh/setup-uv@v5 uses: astral-sh/setup-uv@v6
with: with:
enable-cache: true enable-cache: true
cache-dependency-glob: "" cache-dependency-glob: ""
@@ -251,7 +261,7 @@ It defaults to `setup-uv-cache` in the `TMP` dir, `D:\a\_temp\uv-tool-dir` on Wi
```yaml ```yaml
- name: Define a custom uv cache path - name: Define a custom uv cache path
uses: astral-sh/setup-uv@v5 uses: astral-sh/setup-uv@v6
with: with:
cache-local-path: "/path/to/cache" cache-local-path: "/path/to/cache"
``` ```
@@ -270,7 +280,7 @@ input.
```yaml ```yaml
- name: Don't prune the cache before saving it - name: Don't prune the cache before saving it
uses: astral-sh/setup-uv@v5 uses: astral-sh/setup-uv@v6
with: with:
enable-cache: true enable-cache: true
prune-cache: false prune-cache: false
@@ -283,7 +293,7 @@ If you want to ignore this, set the `ignore-nothing-to-cache` input to `true`.
```yaml ```yaml
- name: Ignore nothing to cache - name: Ignore nothing to cache
uses: astral-sh/setup-uv@v5 uses: astral-sh/setup-uv@v6
with: with:
enable-cache: true enable-cache: true
ignore-nothing-to-cache: true ignore-nothing-to-cache: true
@@ -298,7 +308,7 @@ If you want to ignore this, set the `ignore-empty-workdir` input to `true`.
```yaml ```yaml
- name: Ignore empty workdir - name: Ignore empty workdir
uses: astral-sh/setup-uv@v5 uses: astral-sh/setup-uv@v6
with: with:
ignore-empty-workdir: true ignore-empty-workdir: true
``` ```
@@ -315,7 +325,7 @@ are not sufficient, you can provide a custom GitHub token with the necessary per
```yaml ```yaml
- name: Install the latest version of uv with a custom GitHub token - name: Install the latest version of uv with a custom GitHub token
uses: astral-sh/setup-uv@v5 uses: astral-sh/setup-uv@v6
with: with:
github-token: ${{ secrets.CUSTOM_GITHUB_TOKEN }} github-token: ${{ secrets.CUSTOM_GITHUB_TOKEN }}
``` ```
@@ -333,7 +343,7 @@ input:
```yaml ```yaml
- name: Install the latest version of uv with a custom tool dir - name: Install the latest version of uv with a custom tool dir
uses: astral-sh/setup-uv@v5 uses: astral-sh/setup-uv@v6
with: with:
tool-dir: "/path/to/tool/dir" tool-dir: "/path/to/tool/dir"
``` ```
@@ -352,7 +362,7 @@ If you want to change this behaviour (especially on self-hosted runners) you can
```yaml ```yaml
- name: Install the latest version of uv with a custom tool bin dir - name: Install the latest version of uv with a custom tool bin dir
uses: astral-sh/setup-uv@v5 uses: astral-sh/setup-uv@v6
with: with:
tool-bin-dir: "/path/to/tool-bin/dir" tool-bin-dir: "/path/to/tool-bin/dir"
``` ```
@@ -368,7 +378,7 @@ This action supports expanding the `~` character to the user's home directory fo
```yaml ```yaml
- name: Expand the tilde character - name: Expand the tilde character
uses: astral-sh/setup-uv@v5 uses: astral-sh/setup-uv@v6
with: with:
cache-local-path: "~/path/to/cache" cache-local-path: "~/path/to/cache"
tool-dir: "~/path/to/tool/dir" tool-dir: "~/path/to/tool/dir"
@@ -383,7 +393,7 @@ This action downloads uv from the uv repo's official
[GitHub Actions Toolkit](https://github.com/actions/toolkit) to cache it as a tool to speed up [GitHub Actions Toolkit](https://github.com/actions/toolkit) to cache it as a tool to speed up
consecutive runs on self-hosted runners. consecutive runs on self-hosted runners.
The installed version of uv is then added to the runner PATH, enabling subsequent steps to invoke it The installed version of uv is then added to the runner PATH, enabling later steps to invoke it
by name (`uv`). by name (`uv`).
## FAQ ## FAQ
@@ -401,7 +411,7 @@ For example:
- name: Checkout the repository - name: Checkout the repository
uses: actions/checkout@main uses: actions/checkout@main
- name: Install the latest version of uv - name: Install the latest version of uv
uses: astral-sh/setup-uv@v5 uses: astral-sh/setup-uv@v6
with: with:
enable-cache: true enable-cache: true
- name: Test - name: Test
@@ -413,7 +423,7 @@ To install a specific version of Python, use
```yaml ```yaml
- name: Install the latest version of uv - name: Install the latest version of uv
uses: astral-sh/setup-uv@v5 uses: astral-sh/setup-uv@v6
with: with:
enable-cache: true enable-cache: true
- name: Install Python 3.12 - name: Install Python 3.12
@@ -432,7 +442,7 @@ output:
uses: actions/checkout@main uses: actions/checkout@main
- name: Install the default version of uv - name: Install the default version of uv
id: setup-uv id: setup-uv
uses: astral-sh/setup-uv@v5 uses: astral-sh/setup-uv@v6
- name: Print the installed version - name: Print the installed version
run: echo "Installed uv version is ${{ steps.setup-uv.outputs.uv-version }}" run: echo "Installed uv version is ${{ steps.setup-uv.outputs.uv-version }}"
``` ```

View File

@@ -6,15 +6,15 @@ inputs:
version: version:
description: "The version of uv to install e.g., `0.5.0` Defaults to the version in pyproject.toml or 'latest'." description: "The version of uv to install e.g., `0.5.0` Defaults to the version in pyproject.toml or 'latest'."
default: "" default: ""
pyproject-file:
description: "Path to a pyproject.toml"
default: ""
uv-file:
description: "Path to a uv.toml"
default: ""
python-version: python-version:
description: "The version of Python to set UV_PYTHON to" description: "The version of Python to set UV_PYTHON to"
required: false required: false
activate-environment:
description: "Use uv venv to activate a venv ready to be used by later steps. "
default: "false"
working-directory:
description: "The directory to execute all commands in and look for files such as pyproject.toml"
default: ${{ github.workspace }}
checksum: checksum:
description: "The checksum of the uv version to install" description: "The checksum of the uv version to install"
required: false required: false
@@ -31,8 +31,12 @@ inputs:
"Glob pattern to match files relative to the repository root to control "Glob pattern to match files relative to the repository root to control
the cache." the cache."
default: | default: |
**/*requirements*.txt
**/*requirements*.in
**/*constraints*.txt
**/*constraints*.in
**/pyproject.toml
**/uv.lock **/uv.lock
**/requirements*.txt
cache-suffix: cache-suffix:
description: "Suffix for the cache key" description: "Suffix for the cache key"
required: false required: false

14
dist/save-cache/index.js generated vendored
View File

@@ -88731,7 +88731,7 @@ async function getPythonVersion() {
}, },
}; };
try { try {
const execArgs = ["python", "find"]; const execArgs = ["python", "find", "--directory", inputs_1.workingDirectory];
await exec.exec("uv", execArgs, options); await exec.exec("uv", execArgs, options);
const pythonPath = output.trim(); const pythonPath = output.trim();
output = ""; output = "";
@@ -88997,13 +88997,13 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod }; return (mod && mod.__esModule) ? mod : { "default": mod };
}; };
Object.defineProperty(exports, "__esModule", ({ value: true })); Object.defineProperty(exports, "__esModule", ({ value: true }));
exports.githubToken = exports.toolDir = exports.toolBinDir = exports.ignoreEmptyWorkdir = exports.ignoreNothingToCache = exports.pruneCache = exports.cacheDependencyGlob = exports.cacheLocalPath = exports.cacheSuffix = exports.enableCache = exports.checkSum = exports.pythonVersion = exports.uvFile = exports.pyProjectFile = exports.version = void 0; exports.githubToken = exports.toolDir = exports.toolBinDir = exports.ignoreEmptyWorkdir = exports.ignoreNothingToCache = exports.pruneCache = exports.cacheDependencyGlob = exports.cacheLocalPath = exports.cacheSuffix = exports.enableCache = exports.checkSum = exports.workingDirectory = exports.activateEnvironment = exports.pythonVersion = exports.version = void 0;
const core = __importStar(__nccwpck_require__(7484)); const core = __importStar(__nccwpck_require__(7484));
const node_path_1 = __importDefault(__nccwpck_require__(6760)); const node_path_1 = __importDefault(__nccwpck_require__(6760));
exports.version = core.getInput("version"); exports.version = core.getInput("version");
exports.pyProjectFile = core.getInput("pyproject-file");
exports.uvFile = core.getInput("uv-file");
exports.pythonVersion = core.getInput("python-version"); exports.pythonVersion = core.getInput("python-version");
exports.activateEnvironment = core.getBooleanInput("activate-environment");
exports.workingDirectory = core.getInput("working-directory");
exports.checkSum = core.getInput("checksum"); exports.checkSum = core.getInput("checksum");
exports.enableCache = getEnableCache(); exports.enableCache = getEnableCache();
exports.cacheSuffix = core.getInput("cache-suffix") || ""; exports.cacheSuffix = core.getInput("cache-suffix") || "";
@@ -89053,11 +89053,17 @@ function getCacheLocalPath() {
if (cacheLocalPathInput !== "") { if (cacheLocalPathInput !== "") {
return expandTilde(cacheLocalPathInput); return expandTilde(cacheLocalPathInput);
} }
if (process.env.RUNNER_ENVIRONMENT === "github-hosted") {
if (process.env.RUNNER_TEMP !== undefined) { if (process.env.RUNNER_TEMP !== undefined) {
return `${process.env.RUNNER_TEMP}${node_path_1.default.sep}setup-uv-cache`; return `${process.env.RUNNER_TEMP}${node_path_1.default.sep}setup-uv-cache`;
} }
throw Error("Could not determine UV_CACHE_DIR. Please make sure RUNNER_TEMP is set or provide the cache-local-path input"); throw Error("Could not determine UV_CACHE_DIR. Please make sure RUNNER_TEMP is set or provide the cache-local-path input");
} }
if (process.platform === "win32") {
return `${process.env.APPDATA}${node_path_1.default.sep}uv${node_path_1.default.sep}cache`;
}
return `${process.env.HOME}${node_path_1.default.sep}.cache${node_path_1.default.sep}uv`;
}
function expandTilde(input) { function expandTilde(input) {
if (input.startsWith("~")) { if (input.startsWith("~")) {
return `${process.env.HOME}${input.substring(1)}`; return `${process.env.HOME}${input.substring(1)}`;

404
dist/setup/index.js generated vendored
View File

@@ -121062,7 +121062,7 @@ async function getPythonVersion() {
}, },
}; };
try { try {
const execArgs = ["python", "find"]; const execArgs = ["python", "find", "--directory", inputs_1.workingDirectory];
await exec.exec("uv", execArgs, options); await exec.exec("uv", execArgs, options);
const pythonPath = output.trim(); const pythonPath = output.trim();
output = ""; output = "";
@@ -121188,6 +121188,57 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
exports.KNOWN_CHECKSUMS = void 0; exports.KNOWN_CHECKSUMS = void 0;
// AUTOGENERATED_DO_NOT_EDIT // AUTOGENERATED_DO_NOT_EDIT
exports.KNOWN_CHECKSUMS = { exports.KNOWN_CHECKSUMS = {
"aarch64-apple-darwin-0.6.17": "e686c73b9314c77a36a6a4c9f94b07c001f0c9157c50c63c764941141c0d0088",
"aarch64-pc-windows-msvc-0.6.17": "3a9468e90df970f75759da6caed7dfde2816e0f3842031235c3835fc0c4e7d09",
"aarch64-unknown-linux-gnu-0.6.17": "6fb716c36e8ca9cf98b7cb347b0ced41679145837eb22890ee5fa9d8b68ce9f5",
"aarch64-unknown-linux-musl-0.6.17": "98750f5c0cd9eb520799d10649efb18441b616150f07e6c1125f616a3fd137e8",
"arm-unknown-linux-musleabihf-0.6.17": "649d8d0f37e8365af5aaa012b09dd083d6e71018e569a4d2e78316d5013f18a7",
"armv7-unknown-linux-gnueabihf-0.6.17": "efc12955d7a6120ea0be2de5ee03dbb33d0d7d9de9dbe0dce560514f2ee129d3",
"armv7-unknown-linux-musleabihf-0.6.17": "0661d97df8262ef83ccdc6a55ed101abfe8f1cf1ff1be879d9b0d7d1e894c970",
"i686-pc-windows-msvc-0.6.17": "56dea6c98e1606e95445e77177d7e3cd49bb3d1a63c81b11fe49bf733adb62a2",
"i686-unknown-linux-gnu-0.6.17": "4bc37f8303a4a5aae1c309f08166884027f325b6872c418cfbaa2cf20a2b2ac5",
"i686-unknown-linux-musl-0.6.17": "8ec08cca0806a9205ccf5758258c617b57e413b33275bcd861fca363e0eaddf7",
"powerpc64-unknown-linux-gnu-0.6.17": "d33b70ab206e1ed0663e755506a11db3776787012bfe9d2b2138a90942f506be",
"powerpc64le-unknown-linux-gnu-0.6.17": "cd91a579850fc45d3b786a654a2c0343836f007929b2e35de9606082eec5361f",
"s390x-unknown-linux-gnu-0.6.17": "3c753a9d3485bbac23403a0b41a9e70ceeb586f3b4df891ced7ed27d4c6c542b",
"x86_64-apple-darwin-0.6.17": "61e9bdc02aacdb994da6ea2a477b11b34c23fc09203237aeee8d3817daab012d",
"x86_64-pc-windows-msvc-0.6.17": "32882cf98f646cafca003e7a7c471b7ff4ba977b681c9fa3b12cf908ba64af82",
"x86_64-unknown-linux-gnu-0.6.17": "720ec28f7a94aa8cd91d3d57dec1434d64b9ae13d1dd6a25f4c0cdb837ba9cf6",
"x86_64-unknown-linux-musl-0.6.17": "28bd6b50be068cc09d8a46b76f8c4b72271d471c6673a5bdb47793622e62224d",
"aarch64-apple-darwin-0.6.16": "2b1ea0d5cf27375738f5f0f229587bc3590c0f501cb00bc48133a3d122d28364",
"aarch64-pc-windows-msvc-0.6.16": "5abca187b8aecbdffef7547cb39a527168e4cb93d8d2e4ce14271f5831a4d902",
"aarch64-unknown-linux-gnu-0.6.16": "a82f96ab5f285825f9acee6ac1563683c4940d80df2f08549cad43d37c7ba4a7",
"aarch64-unknown-linux-musl-0.6.16": "ae3f793c62fe6ced80483d6c78cb49f06a01088bc5d86f1446a9b5988b2acecc",
"arm-unknown-linux-musleabihf-0.6.16": "91f7f5a4eb97b7983a8e5421d5bfea8802064422ce2f535055f373726eb0aa9a",
"armv7-unknown-linux-gnueabihf-0.6.16": "a4ffe043952bf4e757a5ca0f546bb83b055b6ee0646dd5c4f5e5f13dbc5ee8f8",
"armv7-unknown-linux-musleabihf-0.6.16": "0237c8d9914e0d9fd2f022d6d5f91ce392d13e0ccbb7fa7ebe601296a67c3d6c",
"i686-pc-windows-msvc-0.6.16": "f5c6400f07db2014b2b0c66770e1125fa70efe4dd99cc8351838bed0045c34f8",
"i686-unknown-linux-gnu-0.6.16": "f46f89efcc599a6695e8378a1201e62cd4afb9a4438d65a89098ab11201f84ab",
"i686-unknown-linux-musl-0.6.16": "afe69380a9d3592a87893d6bdc11ff33e4180b98f1e1fd4e626c0307d7598914",
"powerpc64-unknown-linux-gnu-0.6.16": "bf455747580dbbf76cbcf616f67f825c40bd1bdec20c9ff993e03485f9eaad44",
"powerpc64le-unknown-linux-gnu-0.6.16": "508ec561b1740a551d2b33e96671e0e8435a1bcc0e97080f3d7ba88a096bd360",
"s390x-unknown-linux-gnu-0.6.16": "e25c5527826524f51f114388bff47871bf1ca67badbfd72d45427bdba4b46794",
"x86_64-apple-darwin-0.6.16": "ce512b5e40a8ad2916a46df2bdba729d5541e4b3649a09aaddff6e525be012e4",
"x86_64-pc-windows-msvc-0.6.16": "f1b4c24ec602b6c0b06b6bc64aa447bbe4cf313e93fbec326741961e80ffa8b7",
"x86_64-unknown-linux-gnu-0.6.16": "e9ef28b675df68978a60f87192fb8c730b8bfca9bef42b121686b218ea0f6542",
"x86_64-unknown-linux-musl-0.6.16": "25024557931d04cc34f80b818c7547c9c62b762ec6df807e30cb52f383fa2615",
"aarch64-apple-darwin-0.6.15": "1c5b25f75c6438b6910dbc4c6903debe53f31ee14aee55d02243dfe7bf7c9f72",
"aarch64-pc-windows-msvc-0.6.15": "317fe0b29e647aad1e9f02ffe764dcbbc6e2ef189f018c81b673884173ab98ba",
"aarch64-unknown-linux-gnu-0.6.15": "3bf650aec162157b7e01461f41c2a9797366b6043452c6e7035c6c926d0a585b",
"aarch64-unknown-linux-musl-0.6.15": "183cebae8c9d91bbd48219f9006a5c0c41c90a075d6724aec53a7ea0503c665a",
"arm-unknown-linux-musleabihf-0.6.15": "d83c76e130ffb25fb6a4ba8ea5870207d810190733a14ae87084c63a417912f6",
"armv7-unknown-linux-gnueabihf-0.6.15": "d661ec44e5fc7553cd8dd5ad5f48848c5a4d5279ba0df0036c0e2422ec9f312b",
"armv7-unknown-linux-musleabihf-0.6.15": "6fc86a829965362f99602c47627b269c9b676731586a60ca5bb9d6069677938d",
"i686-pc-windows-msvc-0.6.15": "7f15e3377e94fac882b33465cb8cbb24705f5c8d63d9d65c6f1b0816c1d30a0b",
"i686-unknown-linux-gnu-0.6.15": "bfedd03be9f579a9bc10e6c25176017e514cca0500cfb9bba43794387a577661",
"i686-unknown-linux-musl-0.6.15": "82bf8666c0a57514af4e5403f162314b710e1682e1065ab71a845ebb5d8db0b7",
"powerpc64-unknown-linux-gnu-0.6.15": "6e9795344d61ee9ac497d6e03a447d808f2aab13925f30e44c00638abec57deb",
"powerpc64le-unknown-linux-gnu-0.6.15": "e38f13284ed8b645b87ef07c8b549d1f1a5b746aa0411c2115dcd5cda0da13fc",
"s390x-unknown-linux-gnu-0.6.15": "416f61249b330ea9735cda0c866c9460f87111bc9d4e040c98916fda6a45be09",
"x86_64-apple-darwin-0.6.15": "97adf61511c0f6ea42c090443c38d8d71116b78ae626363f9f149924c91ae886",
"x86_64-pc-windows-msvc-0.6.15": "10c75d566db1447f3bdcbcb31d6598e4b5f4ea638be5d8b73a7350929389512b",
"x86_64-unknown-linux-gnu-0.6.15": "85d98ef282cdbfcb4020922f0c12421ecca4130f0a4570d3b827a15ffd544acc",
"x86_64-unknown-linux-musl-0.6.15": "78289c93836cb32b8b24e3216b5b316e7fdf483365de2fc571844d308387e8a4",
"aarch64-apple-darwin-0.6.14": "4ea4731010fbd1bc8e790e07f199f55a5c7c2c732e9b77f85e302b0bee61b756", "aarch64-apple-darwin-0.6.14": "4ea4731010fbd1bc8e790e07f199f55a5c7c2c732e9b77f85e302b0bee61b756",
"aarch64-pc-windows-msvc-0.6.14": "7b0b3367c4060c9b47b961201ceb4252e97496c890ad1bd13c664bf5b0744d57", "aarch64-pc-windows-msvc-0.6.14": "7b0b3367c4060c9b47b961201ceb4252e97496c890ad1bd13c664bf5b0744d57",
"aarch64-unknown-linux-gnu-0.6.14": "ea25597354af186bdd55aee0de431e16d45d82951a4f41f065a8e4dc27885265", "aarch64-unknown-linux-gnu-0.6.14": "ea25597354af186bdd55aee0de431e16d45d82951a4f41f065a8e4dc27885265",
@@ -124281,7 +124332,7 @@ const platforms_1 = __nccwpck_require__(98361);
const inputs_1 = __nccwpck_require__(9612); const inputs_1 = __nccwpck_require__(9612);
const exec = __importStar(__nccwpck_require__(95236)); const exec = __importStar(__nccwpck_require__(95236));
const node_fs_1 = __importDefault(__nccwpck_require__(73024)); const node_fs_1 = __importDefault(__nccwpck_require__(73024));
const pyproject_1 = __nccwpck_require__(53929); const config_file_1 = __nccwpck_require__(27846);
async function run() { async function run() {
detectEmptyWorkdir(); detectEmptyWorkdir();
const platform = await (0, platforms_1.getPlatform)(); const platform = await (0, platforms_1.getPlatform)();
@@ -124297,7 +124348,8 @@ async function run() {
addToolBinToPath(); addToolBinToPath();
addUvToPathAndOutput(setupResult.uvDir); addUvToPathAndOutput(setupResult.uvDir);
setToolDir(); setToolDir();
await setupPython(); setupPython();
await activateEnvironment();
addMatchers(); addMatchers();
setCacheDir(inputs_1.cacheLocalPath); setCacheDir(inputs_1.cacheLocalPath);
core.setOutput("uv-version", setupResult.version); core.setOutput("uv-version", setupResult.version);
@@ -124341,20 +124393,12 @@ async function determineVersion() {
if (inputs_1.version !== "") { if (inputs_1.version !== "") {
return await (0, download_version_1.resolveVersion)(inputs_1.version, inputs_1.githubToken); return await (0, download_version_1.resolveVersion)(inputs_1.version, inputs_1.githubToken);
} }
const configFile = inputs_1.uvFile !== "" ? inputs_1.uvFile : inputs_1.pyProjectFile; const versionFromUvToml = (0, config_file_1.getUvVersionFromConfigFile)(`${inputs_1.workingDirectory}${path.sep}uv.toml`);
if (configFile !== "") { const versionFromPyproject = (0, config_file_1.getUvVersionFromConfigFile)(`${inputs_1.workingDirectory}${path.sep}pyproject.toml`);
const versionFromConfigFile = (0, pyproject_1.getUvVersionFromConfigFile)(configFile); if (versionFromUvToml === undefined && versionFromPyproject === undefined) {
if (versionFromConfigFile === undefined) { core.info("Could not determine uv version from uv.toml or pyproject.toml. Falling back to latest.");
core.warning(`Could not find required-version under [tool.uv] in ${configFile}. Falling back to latest`);
} }
return await (0, download_version_1.resolveVersion)(versionFromConfigFile || "latest", inputs_1.githubToken); return await (0, download_version_1.resolveVersion)(versionFromUvToml || versionFromPyproject || "latest", inputs_1.githubToken);
}
if (!node_fs_1.default.existsSync("uv.toml") && !node_fs_1.default.existsSync("pyproject.toml")) {
return await (0, download_version_1.resolveVersion)("latest", inputs_1.githubToken);
}
const versionFile = node_fs_1.default.existsSync("uv.toml") ? "uv.toml" : "pyproject.toml";
const versionFromConfigFile = (0, pyproject_1.getUvVersionFromConfigFile)(versionFile);
return await (0, download_version_1.resolveVersion)(versionFromConfigFile || "latest", inputs_1.githubToken);
} }
function addUvToPathAndOutput(cachedPath) { function addUvToPathAndOutput(cachedPath) {
core.setOutput("uv-path", `${cachedPath}${path.sep}uv`); core.setOutput("uv-path", `${cachedPath}${path.sep}uv`);
@@ -124390,22 +124434,23 @@ function setToolDir() {
core.info(`Set UV_TOOL_DIR to ${inputs_1.toolDir}`); core.info(`Set UV_TOOL_DIR to ${inputs_1.toolDir}`);
} }
} }
async function setupPython() { function setupPython() {
if (inputs_1.pythonVersion !== "") { if (inputs_1.pythonVersion !== "") {
core.exportVariable("UV_PYTHON", inputs_1.pythonVersion); core.exportVariable("UV_PYTHON", inputs_1.pythonVersion);
core.info(`Set UV_PYTHON to ${inputs_1.pythonVersion}`); core.info(`Set UV_PYTHON to ${inputs_1.pythonVersion}`);
const options = { }
silent: !core.isDebug(), }
}; async function activateEnvironment() {
const execArgs = ["venv", "--python", inputs_1.pythonVersion]; if (inputs_1.activateEnvironment) {
const execArgs = ["venv", ".venv", "--directory", inputs_1.workingDirectory];
core.info("Activating python venv..."); core.info("Activating python venv...");
await exec.exec("uv", execArgs, options); await exec.exec("uv", execArgs);
let venvBinPath = ".venv/bin"; let venvBinPath = `${inputs_1.workingDirectory}${path.sep}.venv${path.sep}bin`;
if (process.platform === "win32") { if (process.platform === "win32") {
venvBinPath = ".venv/Scripts"; venvBinPath = `${inputs_1.workingDirectory}${path.sep}.venv${path.sep}Scripts`;
} }
core.addPath(path.resolve(venvBinPath)); core.addPath(path.resolve(venvBinPath));
core.exportVariable("VIRTUAL_ENV", path.resolve(".venv")); core.exportVariable("VIRTUAL_ENV", path.resolve(`${inputs_1.workingDirectory}${path.sep}.venv`));
} }
} }
function setCacheDir(cacheLocalPath) { function setCacheDir(cacheLocalPath) {
@@ -124419,6 +124464,88 @@ function addMatchers() {
run(); run();
/***/ }),
/***/ 27846:
/***/ (function(__unused_webpack_module, exports, __nccwpck_require__) {
"use strict";
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
if (k2 === undefined) k2 = k;
var desc = Object.getOwnPropertyDescriptor(m, k);
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
desc = { enumerable: true, get: function() { return m[k]; } };
}
Object.defineProperty(o, k2, desc);
}) : (function(o, m, k, k2) {
if (k2 === undefined) k2 = k;
o[k2] = m[k];
}));
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
Object.defineProperty(o, "default", { enumerable: true, value: v });
}) : function(o, v) {
o["default"] = v;
});
var __importStar = (this && this.__importStar) || (function () {
var ownKeys = function(o) {
ownKeys = Object.getOwnPropertyNames || function (o) {
var ar = [];
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
return ar;
};
return ownKeys(o);
};
return function (mod) {
if (mod && mod.__esModule) return mod;
var result = {};
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
__setModuleDefault(result, mod);
return result;
};
})();
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", ({ value: true }));
exports.getUvVersionFromConfigFile = getUvVersionFromConfigFile;
const node_fs_1 = __importDefault(__nccwpck_require__(73024));
const core = __importStar(__nccwpck_require__(37484));
const toml = __importStar(__nccwpck_require__(27106));
function getUvVersionFromConfigFile(filePath) {
core.info(`Trying to find required-version for uv in: ${filePath}`);
if (!node_fs_1.default.existsSync(filePath)) {
core.info(`Could not find file: ${filePath}`);
return undefined;
}
let requiredVersion;
try {
requiredVersion = getRequiredVersion(filePath);
}
catch (err) {
const message = err.message;
core.warning(`Error while parsing ${filePath}: ${message}`);
return undefined;
}
if (requiredVersion?.startsWith("==")) {
requiredVersion = requiredVersion.slice(2);
}
if (requiredVersion !== undefined) {
core.info(`Found required-version for uv in ${filePath}: ${requiredVersion}`);
}
return requiredVersion;
}
function getRequiredVersion(filePath) {
const fileContent = node_fs_1.default.readFileSync(filePath, "utf-8");
if (filePath.endsWith("pyproject.toml")) {
const tomlContent = toml.parse(fileContent);
return tomlContent?.tool?.uv?.["required-version"];
}
const tomlContent = toml.parse(fileContent);
return tomlContent["required-version"];
}
/***/ }), /***/ }),
/***/ 56156: /***/ 56156:
@@ -124477,13 +124604,13 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod }; return (mod && mod.__esModule) ? mod : { "default": mod };
}; };
Object.defineProperty(exports, "__esModule", ({ value: true })); Object.defineProperty(exports, "__esModule", ({ value: true }));
exports.githubToken = exports.toolDir = exports.toolBinDir = exports.ignoreEmptyWorkdir = exports.ignoreNothingToCache = exports.pruneCache = exports.cacheDependencyGlob = exports.cacheLocalPath = exports.cacheSuffix = exports.enableCache = exports.checkSum = exports.pythonVersion = exports.uvFile = exports.pyProjectFile = exports.version = void 0; exports.githubToken = exports.toolDir = exports.toolBinDir = exports.ignoreEmptyWorkdir = exports.ignoreNothingToCache = exports.pruneCache = exports.cacheDependencyGlob = exports.cacheLocalPath = exports.cacheSuffix = exports.enableCache = exports.checkSum = exports.workingDirectory = exports.activateEnvironment = exports.pythonVersion = exports.version = void 0;
const core = __importStar(__nccwpck_require__(37484)); const core = __importStar(__nccwpck_require__(37484));
const node_path_1 = __importDefault(__nccwpck_require__(76760)); const node_path_1 = __importDefault(__nccwpck_require__(76760));
exports.version = core.getInput("version"); exports.version = core.getInput("version");
exports.pyProjectFile = core.getInput("pyproject-file");
exports.uvFile = core.getInput("uv-file");
exports.pythonVersion = core.getInput("python-version"); exports.pythonVersion = core.getInput("python-version");
exports.activateEnvironment = core.getBooleanInput("activate-environment");
exports.workingDirectory = core.getInput("working-directory");
exports.checkSum = core.getInput("checksum"); exports.checkSum = core.getInput("checksum");
exports.enableCache = getEnableCache(); exports.enableCache = getEnableCache();
exports.cacheSuffix = core.getInput("cache-suffix") || ""; exports.cacheSuffix = core.getInput("cache-suffix") || "";
@@ -124533,11 +124660,17 @@ function getCacheLocalPath() {
if (cacheLocalPathInput !== "") { if (cacheLocalPathInput !== "") {
return expandTilde(cacheLocalPathInput); return expandTilde(cacheLocalPathInput);
} }
if (process.env.RUNNER_ENVIRONMENT === "github-hosted") {
if (process.env.RUNNER_TEMP !== undefined) { if (process.env.RUNNER_TEMP !== undefined) {
return `${process.env.RUNNER_TEMP}${node_path_1.default.sep}setup-uv-cache`; return `${process.env.RUNNER_TEMP}${node_path_1.default.sep}setup-uv-cache`;
} }
throw Error("Could not determine UV_CACHE_DIR. Please make sure RUNNER_TEMP is set or provide the cache-local-path input"); throw Error("Could not determine UV_CACHE_DIR. Please make sure RUNNER_TEMP is set or provide the cache-local-path input");
} }
if (process.platform === "win32") {
return `${process.env.APPDATA}${node_path_1.default.sep}uv${node_path_1.default.sep}cache`;
}
return `${process.env.HOME}${node_path_1.default.sep}.cache${node_path_1.default.sep}uv`;
}
function expandTilde(input) { function expandTilde(input) {
if (input.startsWith("~")) { if (input.startsWith("~")) {
return `${process.env.HOME}${input.substring(1)}`; return `${process.env.HOME}${input.substring(1)}`;
@@ -124694,88 +124827,6 @@ async function isMuslOs() {
} }
/***/ }),
/***/ 53929:
/***/ (function(__unused_webpack_module, exports, __nccwpck_require__) {
"use strict";
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
if (k2 === undefined) k2 = k;
var desc = Object.getOwnPropertyDescriptor(m, k);
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
desc = { enumerable: true, get: function() { return m[k]; } };
}
Object.defineProperty(o, k2, desc);
}) : (function(o, m, k, k2) {
if (k2 === undefined) k2 = k;
o[k2] = m[k];
}));
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
Object.defineProperty(o, "default", { enumerable: true, value: v });
}) : function(o, v) {
o["default"] = v;
});
var __importStar = (this && this.__importStar) || (function () {
var ownKeys = function(o) {
ownKeys = Object.getOwnPropertyNames || function (o) {
var ar = [];
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
return ar;
};
return ownKeys(o);
};
return function (mod) {
if (mod && mod.__esModule) return mod;
var result = {};
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
__setModuleDefault(result, mod);
return result;
};
})();
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", ({ value: true }));
exports.getUvVersionFromConfigFile = getUvVersionFromConfigFile;
const node_fs_1 = __importDefault(__nccwpck_require__(73024));
const core = __importStar(__nccwpck_require__(37484));
const toml = __importStar(__nccwpck_require__(27106));
function getUvVersionFromConfigFile(filePath) {
core.debug(`Trying to find required-version for uv in: ${filePath}`);
if (!node_fs_1.default.existsSync(filePath)) {
core.warning(`Could not find file: ${filePath}`);
return undefined;
}
let requiredVersion;
try {
requiredVersion = getRequiredVersion(filePath);
}
catch (err) {
const message = err.message;
core.warning(`Error while parsing ${filePath}: ${message}`);
return undefined;
}
if (requiredVersion?.startsWith("==")) {
requiredVersion = requiredVersion.slice(2);
}
if (requiredVersion !== undefined) {
core.info(`Found required-version for uv in ${filePath}: ${requiredVersion}`);
}
return requiredVersion;
}
function getRequiredVersion(filePath) {
const fileContent = node_fs_1.default.readFileSync(filePath, "utf-8");
if (filePath.endsWith("pyproject.toml")) {
const tomlContent = toml.parse(fileContent);
return tomlContent?.tool?.uv?.["required-version"];
}
const tomlContent = toml.parse(fileContent);
return tomlContent["required-version"];
}
/***/ }), /***/ }),
/***/ 42078: /***/ 42078:
@@ -129127,8 +129178,10 @@ var paginatingEndpoints = [
"GET /notifications", "GET /notifications",
"GET /organizations", "GET /organizations",
"GET /orgs/{org}/actions/cache/usage-by-repository", "GET /orgs/{org}/actions/cache/usage-by-repository",
"GET /orgs/{org}/actions/hosted-runners",
"GET /orgs/{org}/actions/permissions/repositories", "GET /orgs/{org}/actions/permissions/repositories",
"GET /orgs/{org}/actions/runner-groups", "GET /orgs/{org}/actions/runner-groups",
"GET /orgs/{org}/actions/runner-groups/{runner_group_id}/hosted-runners",
"GET /orgs/{org}/actions/runner-groups/{runner_group_id}/repositories", "GET /orgs/{org}/actions/runner-groups/{runner_group_id}/repositories",
"GET /orgs/{org}/actions/runner-groups/{runner_group_id}/runners", "GET /orgs/{org}/actions/runner-groups/{runner_group_id}/runners",
"GET /orgs/{org}/actions/runners", "GET /orgs/{org}/actions/runners",
@@ -129138,6 +129191,7 @@ var paginatingEndpoints = [
"GET /orgs/{org}/actions/variables/{name}/repositories", "GET /orgs/{org}/actions/variables/{name}/repositories",
"GET /orgs/{org}/attestations/{subject_digest}", "GET /orgs/{org}/attestations/{subject_digest}",
"GET /orgs/{org}/blocks", "GET /orgs/{org}/blocks",
"GET /orgs/{org}/campaigns",
"GET /orgs/{org}/code-scanning/alerts", "GET /orgs/{org}/code-scanning/alerts",
"GET /orgs/{org}/code-security/configurations", "GET /orgs/{org}/code-security/configurations",
"GET /orgs/{org}/code-security/configurations/{configuration_id}/repositories", "GET /orgs/{org}/code-security/configurations/{configuration_id}/repositories",
@@ -129146,7 +129200,6 @@ var paginatingEndpoints = [
"GET /orgs/{org}/codespaces/secrets/{secret_name}/repositories", "GET /orgs/{org}/codespaces/secrets/{secret_name}/repositories",
"GET /orgs/{org}/copilot/billing/seats", "GET /orgs/{org}/copilot/billing/seats",
"GET /orgs/{org}/copilot/metrics", "GET /orgs/{org}/copilot/metrics",
"GET /orgs/{org}/copilot/usage",
"GET /orgs/{org}/dependabot/alerts", "GET /orgs/{org}/dependabot/alerts",
"GET /orgs/{org}/dependabot/secrets", "GET /orgs/{org}/dependabot/secrets",
"GET /orgs/{org}/dependabot/secrets/{secret_name}/repositories", "GET /orgs/{org}/dependabot/secrets/{secret_name}/repositories",
@@ -129181,10 +129234,11 @@ var paginatingEndpoints = [
"GET /orgs/{org}/repos", "GET /orgs/{org}/repos",
"GET /orgs/{org}/rulesets", "GET /orgs/{org}/rulesets",
"GET /orgs/{org}/rulesets/rule-suites", "GET /orgs/{org}/rulesets/rule-suites",
"GET /orgs/{org}/rulesets/{ruleset_id}/history",
"GET /orgs/{org}/secret-scanning/alerts", "GET /orgs/{org}/secret-scanning/alerts",
"GET /orgs/{org}/security-advisories", "GET /orgs/{org}/security-advisories",
"GET /orgs/{org}/settings/network-configurations",
"GET /orgs/{org}/team/{team_slug}/copilot/metrics", "GET /orgs/{org}/team/{team_slug}/copilot/metrics",
"GET /orgs/{org}/team/{team_slug}/copilot/usage",
"GET /orgs/{org}/teams", "GET /orgs/{org}/teams",
"GET /orgs/{org}/teams/{team_slug}/discussions", "GET /orgs/{org}/teams/{team_slug}/discussions",
"GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments", "GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments",
@@ -129279,6 +129333,7 @@ var paginatingEndpoints = [
"GET /repos/{owner}/{repo}/rules/branches/{branch}", "GET /repos/{owner}/{repo}/rules/branches/{branch}",
"GET /repos/{owner}/{repo}/rulesets", "GET /repos/{owner}/{repo}/rulesets",
"GET /repos/{owner}/{repo}/rulesets/rule-suites", "GET /repos/{owner}/{repo}/rulesets/rule-suites",
"GET /repos/{owner}/{repo}/rulesets/{ruleset_id}/history",
"GET /repos/{owner}/{repo}/secret-scanning/alerts", "GET /repos/{owner}/{repo}/secret-scanning/alerts",
"GET /repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}/locations", "GET /repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}/locations",
"GET /repos/{owner}/{repo}/security-advisories", "GET /repos/{owner}/{repo}/security-advisories",
@@ -129390,7 +129445,7 @@ __nccwpck_require__.d(__webpack_exports__, {
}); });
;// CONCATENATED MODULE: ./node_modules/@octokit/plugin-rest-endpoint-methods/dist-src/version.js ;// CONCATENATED MODULE: ./node_modules/@octokit/plugin-rest-endpoint-methods/dist-src/version.js
const VERSION = "13.3.1"; const VERSION = "14.0.0";
//# sourceMappingURL=version.js.map //# sourceMappingURL=version.js.map
@@ -129421,6 +129476,7 @@ const Endpoints = {
createEnvironmentVariable: [ createEnvironmentVariable: [
"POST /repos/{owner}/{repo}/environments/{environment_name}/variables" "POST /repos/{owner}/{repo}/environments/{environment_name}/variables"
], ],
createHostedRunnerForOrg: ["POST /orgs/{org}/actions/hosted-runners"],
createOrUpdateEnvironmentSecret: [ createOrUpdateEnvironmentSecret: [
"PUT /repos/{owner}/{repo}/environments/{environment_name}/secrets/{secret_name}" "PUT /repos/{owner}/{repo}/environments/{environment_name}/secrets/{secret_name}"
], ],
@@ -129458,6 +129514,9 @@ const Endpoints = {
deleteEnvironmentVariable: [ deleteEnvironmentVariable: [
"DELETE /repos/{owner}/{repo}/environments/{environment_name}/variables/{name}" "DELETE /repos/{owner}/{repo}/environments/{environment_name}/variables/{name}"
], ],
deleteHostedRunnerForOrg: [
"DELETE /orgs/{org}/actions/hosted-runners/{hosted_runner_id}"
],
deleteOrgSecret: ["DELETE /orgs/{org}/actions/secrets/{secret_name}"], deleteOrgSecret: ["DELETE /orgs/{org}/actions/secrets/{secret_name}"],
deleteOrgVariable: ["DELETE /orgs/{org}/actions/variables/{name}"], deleteOrgVariable: ["DELETE /orgs/{org}/actions/variables/{name}"],
deleteRepoSecret: [ deleteRepoSecret: [
@@ -129546,6 +129605,24 @@ const Endpoints = {
getGithubActionsPermissionsRepository: [ getGithubActionsPermissionsRepository: [
"GET /repos/{owner}/{repo}/actions/permissions" "GET /repos/{owner}/{repo}/actions/permissions"
], ],
getHostedRunnerForOrg: [
"GET /orgs/{org}/actions/hosted-runners/{hosted_runner_id}"
],
getHostedRunnersGithubOwnedImagesForOrg: [
"GET /orgs/{org}/actions/hosted-runners/images/github-owned"
],
getHostedRunnersLimitsForOrg: [
"GET /orgs/{org}/actions/hosted-runners/limits"
],
getHostedRunnersMachineSpecsForOrg: [
"GET /orgs/{org}/actions/hosted-runners/machine-sizes"
],
getHostedRunnersPartnerImagesForOrg: [
"GET /orgs/{org}/actions/hosted-runners/images/partner"
],
getHostedRunnersPlatformsForOrg: [
"GET /orgs/{org}/actions/hosted-runners/platforms"
],
getJobForWorkflowRun: ["GET /repos/{owner}/{repo}/actions/jobs/{job_id}"], getJobForWorkflowRun: ["GET /repos/{owner}/{repo}/actions/jobs/{job_id}"],
getOrgPublicKey: ["GET /orgs/{org}/actions/secrets/public-key"], getOrgPublicKey: ["GET /orgs/{org}/actions/secrets/public-key"],
getOrgSecret: ["GET /orgs/{org}/actions/secrets/{secret_name}"], getOrgSecret: ["GET /orgs/{org}/actions/secrets/{secret_name}"],
@@ -129589,6 +129666,10 @@ const Endpoints = {
listEnvironmentVariables: [ listEnvironmentVariables: [
"GET /repos/{owner}/{repo}/environments/{environment_name}/variables" "GET /repos/{owner}/{repo}/environments/{environment_name}/variables"
], ],
listGithubHostedRunnersInGroupForOrg: [
"GET /orgs/{org}/actions/runner-groups/{runner_group_id}/hosted-runners"
],
listHostedRunnersForOrg: ["GET /orgs/{org}/actions/hosted-runners"],
listJobsForWorkflowRun: [ listJobsForWorkflowRun: [
"GET /repos/{owner}/{repo}/actions/runs/{run_id}/jobs" "GET /repos/{owner}/{repo}/actions/runs/{run_id}/jobs"
], ],
@@ -129707,6 +129788,9 @@ const Endpoints = {
updateEnvironmentVariable: [ updateEnvironmentVariable: [
"PATCH /repos/{owner}/{repo}/environments/{environment_name}/variables/{name}" "PATCH /repos/{owner}/{repo}/environments/{environment_name}/variables/{name}"
], ],
updateHostedRunnerForOrg: [
"PATCH /orgs/{org}/actions/hosted-runners/{hosted_runner_id}"
],
updateOrgVariable: ["PATCH /orgs/{org}/actions/variables/{name}"], updateOrgVariable: ["PATCH /orgs/{org}/actions/variables/{name}"],
updateRepoVariable: [ updateRepoVariable: [
"PATCH /repos/{owner}/{repo}/actions/variables/{name}" "PATCH /repos/{owner}/{repo}/actions/variables/{name}"
@@ -129848,6 +129932,13 @@ const Endpoints = {
"GET /users/{username}/settings/billing/shared-storage" "GET /users/{username}/settings/billing/shared-storage"
] ]
}, },
campaigns: {
createCampaign: ["POST /orgs/{org}/campaigns"],
deleteCampaign: ["DELETE /orgs/{org}/campaigns/{campaign_number}"],
getCampaignSummary: ["GET /orgs/{org}/campaigns/{campaign_number}"],
listOrgCampaigns: ["GET /orgs/{org}/campaigns"],
updateCampaign: ["PATCH /orgs/{org}/campaigns/{campaign_number}"]
},
checks: { checks: {
create: ["POST /repos/{owner}/{repo}/check-runs"], create: ["POST /repos/{owner}/{repo}/check-runs"],
createSuite: ["POST /repos/{owner}/{repo}/check-suites"], createSuite: ["POST /repos/{owner}/{repo}/check-suites"],
@@ -130126,9 +130217,7 @@ const Endpoints = {
getCopilotSeatDetailsForUser: [ getCopilotSeatDetailsForUser: [
"GET /orgs/{org}/members/{username}/copilot" "GET /orgs/{org}/members/{username}/copilot"
], ],
listCopilotSeats: ["GET /orgs/{org}/copilot/billing/seats"], listCopilotSeats: ["GET /orgs/{org}/copilot/billing/seats"]
usageMetricsForOrg: ["GET /orgs/{org}/copilot/usage"],
usageMetricsForTeam: ["GET /orgs/{org}/team/{team_slug}/copilot/usage"]
}, },
dependabot: { dependabot: {
addSelectedRepoToOrgSecret: [ addSelectedRepoToOrgSecret: [
@@ -130224,6 +130313,26 @@ const Endpoints = {
getAllTemplates: ["GET /gitignore/templates"], getAllTemplates: ["GET /gitignore/templates"],
getTemplate: ["GET /gitignore/templates/{name}"] getTemplate: ["GET /gitignore/templates/{name}"]
}, },
hostedCompute: {
createNetworkConfigurationForOrg: [
"POST /orgs/{org}/settings/network-configurations"
],
deleteNetworkConfigurationFromOrg: [
"DELETE /orgs/{org}/settings/network-configurations/{network_configuration_id}"
],
getNetworkConfigurationForOrg: [
"GET /orgs/{org}/settings/network-configurations/{network_configuration_id}"
],
getNetworkSettingsForOrg: [
"GET /orgs/{org}/settings/network-settings/{network_settings_id}"
],
listNetworkConfigurationsForOrg: [
"GET /orgs/{org}/settings/network-configurations"
],
updateNetworkConfigurationForOrg: [
"PATCH /orgs/{org}/settings/network-configurations/{network_configuration_id}"
]
},
interactions: { interactions: {
getRestrictionsForAuthenticatedUser: ["GET /user/interaction-limits"], getRestrictionsForAuthenticatedUser: ["GET /user/interaction-limits"],
getRestrictionsForOrg: ["GET /orgs/{org}/interaction-limits"], getRestrictionsForOrg: ["GET /orgs/{org}/interaction-limits"],
@@ -130415,6 +130524,7 @@ const Endpoints = {
"PUT /orgs/{org}/outside_collaborators/{username}" "PUT /orgs/{org}/outside_collaborators/{username}"
], ],
createInvitation: ["POST /orgs/{org}/invitations"], createInvitation: ["POST /orgs/{org}/invitations"],
createIssueType: ["POST /orgs/{org}/issue-types"],
createOrUpdateCustomProperties: ["PATCH /orgs/{org}/properties/schema"], createOrUpdateCustomProperties: ["PATCH /orgs/{org}/properties/schema"],
createOrUpdateCustomPropertiesValuesForRepos: [ createOrUpdateCustomPropertiesValuesForRepos: [
"PATCH /orgs/{org}/properties/values" "PATCH /orgs/{org}/properties/values"
@@ -130424,6 +130534,7 @@ const Endpoints = {
], ],
createWebhook: ["POST /orgs/{org}/hooks"], createWebhook: ["POST /orgs/{org}/hooks"],
delete: ["DELETE /orgs/{org}"], delete: ["DELETE /orgs/{org}"],
deleteIssueType: ["DELETE /orgs/{org}/issue-types/{issue_type_id}"],
deleteWebhook: ["DELETE /orgs/{org}/hooks/{hook_id}"], deleteWebhook: ["DELETE /orgs/{org}/hooks/{hook_id}"],
enableOrDisableSecurityProductOnAllOrgRepos: [ enableOrDisableSecurityProductOnAllOrgRepos: [
"POST /orgs/{org}/{security_product}/{enablement}", "POST /orgs/{org}/{security_product}/{enablement}",
@@ -130440,6 +130551,10 @@ const Endpoints = {
getMembershipForAuthenticatedUser: ["GET /user/memberships/orgs/{org}"], getMembershipForAuthenticatedUser: ["GET /user/memberships/orgs/{org}"],
getMembershipForUser: ["GET /orgs/{org}/memberships/{username}"], getMembershipForUser: ["GET /orgs/{org}/memberships/{username}"],
getOrgRole: ["GET /orgs/{org}/organization-roles/{role_id}"], getOrgRole: ["GET /orgs/{org}/organization-roles/{role_id}"],
getOrgRulesetHistory: ["GET /orgs/{org}/rulesets/{ruleset_id}/history"],
getOrgRulesetVersion: [
"GET /orgs/{org}/rulesets/{ruleset_id}/history/{version_id}"
],
getWebhook: ["GET /orgs/{org}/hooks/{hook_id}"], getWebhook: ["GET /orgs/{org}/hooks/{hook_id}"],
getWebhookConfigForOrg: ["GET /orgs/{org}/hooks/{hook_id}/config"], getWebhookConfigForOrg: ["GET /orgs/{org}/hooks/{hook_id}/config"],
getWebhookDelivery: [ getWebhookDelivery: [
@@ -130454,6 +130569,7 @@ const Endpoints = {
listForAuthenticatedUser: ["GET /user/orgs"], listForAuthenticatedUser: ["GET /user/orgs"],
listForUser: ["GET /users/{username}/orgs"], listForUser: ["GET /users/{username}/orgs"],
listInvitationTeams: ["GET /orgs/{org}/invitations/{invitation_id}/teams"], listInvitationTeams: ["GET /orgs/{org}/invitations/{invitation_id}/teams"],
listIssueTypes: ["GET /orgs/{org}/issue-types"],
listMembers: ["GET /orgs/{org}/members"], listMembers: ["GET /orgs/{org}/members"],
listMembershipsForAuthenticatedUser: ["GET /user/memberships/orgs"], listMembershipsForAuthenticatedUser: ["GET /user/memberships/orgs"],
listOrgRoleTeams: ["GET /orgs/{org}/organization-roles/{role_id}/teams"], listOrgRoleTeams: ["GET /orgs/{org}/organization-roles/{role_id}/teams"],
@@ -130528,6 +130644,7 @@ const Endpoints = {
], ],
unblockUser: ["DELETE /orgs/{org}/blocks/{username}"], unblockUser: ["DELETE /orgs/{org}/blocks/{username}"],
update: ["PATCH /orgs/{org}"], update: ["PATCH /orgs/{org}"],
updateIssueType: ["PUT /orgs/{org}/issue-types/{issue_type_id}"],
updateMembershipForAuthenticatedUser: [ updateMembershipForAuthenticatedUser: [
"PATCH /user/memberships/orgs/{org}" "PATCH /user/memberships/orgs/{org}"
], ],
@@ -130640,37 +130757,6 @@ const Endpoints = {
"PATCH /orgs/{org}/private-registries/{secret_name}" "PATCH /orgs/{org}/private-registries/{secret_name}"
] ]
}, },
projects: {
addCollaborator: ["PUT /projects/{project_id}/collaborators/{username}"],
createCard: ["POST /projects/columns/{column_id}/cards"],
createColumn: ["POST /projects/{project_id}/columns"],
createForAuthenticatedUser: ["POST /user/projects"],
createForOrg: ["POST /orgs/{org}/projects"],
createForRepo: ["POST /repos/{owner}/{repo}/projects"],
delete: ["DELETE /projects/{project_id}"],
deleteCard: ["DELETE /projects/columns/cards/{card_id}"],
deleteColumn: ["DELETE /projects/columns/{column_id}"],
get: ["GET /projects/{project_id}"],
getCard: ["GET /projects/columns/cards/{card_id}"],
getColumn: ["GET /projects/columns/{column_id}"],
getPermissionForUser: [
"GET /projects/{project_id}/collaborators/{username}/permission"
],
listCards: ["GET /projects/columns/{column_id}/cards"],
listCollaborators: ["GET /projects/{project_id}/collaborators"],
listColumns: ["GET /projects/{project_id}/columns"],
listForOrg: ["GET /orgs/{org}/projects"],
listForRepo: ["GET /repos/{owner}/{repo}/projects"],
listForUser: ["GET /users/{username}/projects"],
moveCard: ["POST /projects/columns/cards/{card_id}/moves"],
moveColumn: ["POST /projects/columns/{column_id}/moves"],
removeCollaborator: [
"DELETE /projects/{project_id}/collaborators/{username}"
],
update: ["PATCH /projects/{project_id}"],
updateCard: ["PATCH /projects/columns/cards/{card_id}"],
updateColumn: ["PATCH /projects/columns/{column_id}"]
},
pulls: { pulls: {
checkIfMerged: ["GET /repos/{owner}/{repo}/pulls/{pull_number}/merge"], checkIfMerged: ["GET /repos/{owner}/{repo}/pulls/{pull_number}/merge"],
create: ["POST /repos/{owner}/{repo}/pulls"], create: ["POST /repos/{owner}/{repo}/pulls"],
@@ -131042,6 +131128,12 @@ const Endpoints = {
], ],
getRepoRuleSuites: ["GET /repos/{owner}/{repo}/rulesets/rule-suites"], getRepoRuleSuites: ["GET /repos/{owner}/{repo}/rulesets/rule-suites"],
getRepoRuleset: ["GET /repos/{owner}/{repo}/rulesets/{ruleset_id}"], getRepoRuleset: ["GET /repos/{owner}/{repo}/rulesets/{ruleset_id}"],
getRepoRulesetHistory: [
"GET /repos/{owner}/{repo}/rulesets/{ruleset_id}/history"
],
getRepoRulesetVersion: [
"GET /repos/{owner}/{repo}/rulesets/{ruleset_id}/history/{version_id}"
],
getRepoRulesets: ["GET /repos/{owner}/{repo}/rulesets"], getRepoRulesets: ["GET /repos/{owner}/{repo}/rulesets"],
getStatusChecksProtection: [ getStatusChecksProtection: [
"GET /repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks" "GET /repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks"
@@ -131215,7 +131307,13 @@ const Endpoints = {
search: { search: {
code: ["GET /search/code"], code: ["GET /search/code"],
commits: ["GET /search/commits"], commits: ["GET /search/commits"],
issuesAndPullRequests: ["GET /search/issues"], issuesAndPullRequests: [
"GET /search/issues",
{},
{
deprecated: "octokit.rest.search.issuesAndPullRequests() is deprecated, see https://docs.github.com/rest/search/search#search-issues-and-pull-requests"
}
],
labels: ["GET /search/labels"], labels: ["GET /search/labels"],
repos: ["GET /search/repositories"], repos: ["GET /search/repositories"],
topics: ["GET /search/topics"], topics: ["GET /search/topics"],
@@ -131269,15 +131367,9 @@ const Endpoints = {
addOrUpdateMembershipForUserInOrg: [ addOrUpdateMembershipForUserInOrg: [
"PUT /orgs/{org}/teams/{team_slug}/memberships/{username}" "PUT /orgs/{org}/teams/{team_slug}/memberships/{username}"
], ],
addOrUpdateProjectPermissionsInOrg: [
"PUT /orgs/{org}/teams/{team_slug}/projects/{project_id}"
],
addOrUpdateRepoPermissionsInOrg: [ addOrUpdateRepoPermissionsInOrg: [
"PUT /orgs/{org}/teams/{team_slug}/repos/{owner}/{repo}" "PUT /orgs/{org}/teams/{team_slug}/repos/{owner}/{repo}"
], ],
checkPermissionsForProjectInOrg: [
"GET /orgs/{org}/teams/{team_slug}/projects/{project_id}"
],
checkPermissionsForRepoInOrg: [ checkPermissionsForRepoInOrg: [
"GET /orgs/{org}/teams/{team_slug}/repos/{owner}/{repo}" "GET /orgs/{org}/teams/{team_slug}/repos/{owner}/{repo}"
], ],
@@ -131314,14 +131406,10 @@ const Endpoints = {
listPendingInvitationsInOrg: [ listPendingInvitationsInOrg: [
"GET /orgs/{org}/teams/{team_slug}/invitations" "GET /orgs/{org}/teams/{team_slug}/invitations"
], ],
listProjectsInOrg: ["GET /orgs/{org}/teams/{team_slug}/projects"],
listReposInOrg: ["GET /orgs/{org}/teams/{team_slug}/repos"], listReposInOrg: ["GET /orgs/{org}/teams/{team_slug}/repos"],
removeMembershipForUserInOrg: [ removeMembershipForUserInOrg: [
"DELETE /orgs/{org}/teams/{team_slug}/memberships/{username}" "DELETE /orgs/{org}/teams/{team_slug}/memberships/{username}"
], ],
removeProjectInOrg: [
"DELETE /orgs/{org}/teams/{team_slug}/projects/{project_id}"
],
removeRepoInOrg: [ removeRepoInOrg: [
"DELETE /orgs/{org}/teams/{team_slug}/repos/{owner}/{repo}" "DELETE /orgs/{org}/teams/{team_slug}/repos/{owner}/{repo}"
], ],

184
dist/update-known-checksums/index.js generated vendored
View File

@@ -58847,6 +58847,57 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
exports.KNOWN_CHECKSUMS = void 0; exports.KNOWN_CHECKSUMS = void 0;
// AUTOGENERATED_DO_NOT_EDIT // AUTOGENERATED_DO_NOT_EDIT
exports.KNOWN_CHECKSUMS = { exports.KNOWN_CHECKSUMS = {
"aarch64-apple-darwin-0.6.17": "e686c73b9314c77a36a6a4c9f94b07c001f0c9157c50c63c764941141c0d0088",
"aarch64-pc-windows-msvc-0.6.17": "3a9468e90df970f75759da6caed7dfde2816e0f3842031235c3835fc0c4e7d09",
"aarch64-unknown-linux-gnu-0.6.17": "6fb716c36e8ca9cf98b7cb347b0ced41679145837eb22890ee5fa9d8b68ce9f5",
"aarch64-unknown-linux-musl-0.6.17": "98750f5c0cd9eb520799d10649efb18441b616150f07e6c1125f616a3fd137e8",
"arm-unknown-linux-musleabihf-0.6.17": "649d8d0f37e8365af5aaa012b09dd083d6e71018e569a4d2e78316d5013f18a7",
"armv7-unknown-linux-gnueabihf-0.6.17": "efc12955d7a6120ea0be2de5ee03dbb33d0d7d9de9dbe0dce560514f2ee129d3",
"armv7-unknown-linux-musleabihf-0.6.17": "0661d97df8262ef83ccdc6a55ed101abfe8f1cf1ff1be879d9b0d7d1e894c970",
"i686-pc-windows-msvc-0.6.17": "56dea6c98e1606e95445e77177d7e3cd49bb3d1a63c81b11fe49bf733adb62a2",
"i686-unknown-linux-gnu-0.6.17": "4bc37f8303a4a5aae1c309f08166884027f325b6872c418cfbaa2cf20a2b2ac5",
"i686-unknown-linux-musl-0.6.17": "8ec08cca0806a9205ccf5758258c617b57e413b33275bcd861fca363e0eaddf7",
"powerpc64-unknown-linux-gnu-0.6.17": "d33b70ab206e1ed0663e755506a11db3776787012bfe9d2b2138a90942f506be",
"powerpc64le-unknown-linux-gnu-0.6.17": "cd91a579850fc45d3b786a654a2c0343836f007929b2e35de9606082eec5361f",
"s390x-unknown-linux-gnu-0.6.17": "3c753a9d3485bbac23403a0b41a9e70ceeb586f3b4df891ced7ed27d4c6c542b",
"x86_64-apple-darwin-0.6.17": "61e9bdc02aacdb994da6ea2a477b11b34c23fc09203237aeee8d3817daab012d",
"x86_64-pc-windows-msvc-0.6.17": "32882cf98f646cafca003e7a7c471b7ff4ba977b681c9fa3b12cf908ba64af82",
"x86_64-unknown-linux-gnu-0.6.17": "720ec28f7a94aa8cd91d3d57dec1434d64b9ae13d1dd6a25f4c0cdb837ba9cf6",
"x86_64-unknown-linux-musl-0.6.17": "28bd6b50be068cc09d8a46b76f8c4b72271d471c6673a5bdb47793622e62224d",
"aarch64-apple-darwin-0.6.16": "2b1ea0d5cf27375738f5f0f229587bc3590c0f501cb00bc48133a3d122d28364",
"aarch64-pc-windows-msvc-0.6.16": "5abca187b8aecbdffef7547cb39a527168e4cb93d8d2e4ce14271f5831a4d902",
"aarch64-unknown-linux-gnu-0.6.16": "a82f96ab5f285825f9acee6ac1563683c4940d80df2f08549cad43d37c7ba4a7",
"aarch64-unknown-linux-musl-0.6.16": "ae3f793c62fe6ced80483d6c78cb49f06a01088bc5d86f1446a9b5988b2acecc",
"arm-unknown-linux-musleabihf-0.6.16": "91f7f5a4eb97b7983a8e5421d5bfea8802064422ce2f535055f373726eb0aa9a",
"armv7-unknown-linux-gnueabihf-0.6.16": "a4ffe043952bf4e757a5ca0f546bb83b055b6ee0646dd5c4f5e5f13dbc5ee8f8",
"armv7-unknown-linux-musleabihf-0.6.16": "0237c8d9914e0d9fd2f022d6d5f91ce392d13e0ccbb7fa7ebe601296a67c3d6c",
"i686-pc-windows-msvc-0.6.16": "f5c6400f07db2014b2b0c66770e1125fa70efe4dd99cc8351838bed0045c34f8",
"i686-unknown-linux-gnu-0.6.16": "f46f89efcc599a6695e8378a1201e62cd4afb9a4438d65a89098ab11201f84ab",
"i686-unknown-linux-musl-0.6.16": "afe69380a9d3592a87893d6bdc11ff33e4180b98f1e1fd4e626c0307d7598914",
"powerpc64-unknown-linux-gnu-0.6.16": "bf455747580dbbf76cbcf616f67f825c40bd1bdec20c9ff993e03485f9eaad44",
"powerpc64le-unknown-linux-gnu-0.6.16": "508ec561b1740a551d2b33e96671e0e8435a1bcc0e97080f3d7ba88a096bd360",
"s390x-unknown-linux-gnu-0.6.16": "e25c5527826524f51f114388bff47871bf1ca67badbfd72d45427bdba4b46794",
"x86_64-apple-darwin-0.6.16": "ce512b5e40a8ad2916a46df2bdba729d5541e4b3649a09aaddff6e525be012e4",
"x86_64-pc-windows-msvc-0.6.16": "f1b4c24ec602b6c0b06b6bc64aa447bbe4cf313e93fbec326741961e80ffa8b7",
"x86_64-unknown-linux-gnu-0.6.16": "e9ef28b675df68978a60f87192fb8c730b8bfca9bef42b121686b218ea0f6542",
"x86_64-unknown-linux-musl-0.6.16": "25024557931d04cc34f80b818c7547c9c62b762ec6df807e30cb52f383fa2615",
"aarch64-apple-darwin-0.6.15": "1c5b25f75c6438b6910dbc4c6903debe53f31ee14aee55d02243dfe7bf7c9f72",
"aarch64-pc-windows-msvc-0.6.15": "317fe0b29e647aad1e9f02ffe764dcbbc6e2ef189f018c81b673884173ab98ba",
"aarch64-unknown-linux-gnu-0.6.15": "3bf650aec162157b7e01461f41c2a9797366b6043452c6e7035c6c926d0a585b",
"aarch64-unknown-linux-musl-0.6.15": "183cebae8c9d91bbd48219f9006a5c0c41c90a075d6724aec53a7ea0503c665a",
"arm-unknown-linux-musleabihf-0.6.15": "d83c76e130ffb25fb6a4ba8ea5870207d810190733a14ae87084c63a417912f6",
"armv7-unknown-linux-gnueabihf-0.6.15": "d661ec44e5fc7553cd8dd5ad5f48848c5a4d5279ba0df0036c0e2422ec9f312b",
"armv7-unknown-linux-musleabihf-0.6.15": "6fc86a829965362f99602c47627b269c9b676731586a60ca5bb9d6069677938d",
"i686-pc-windows-msvc-0.6.15": "7f15e3377e94fac882b33465cb8cbb24705f5c8d63d9d65c6f1b0816c1d30a0b",
"i686-unknown-linux-gnu-0.6.15": "bfedd03be9f579a9bc10e6c25176017e514cca0500cfb9bba43794387a577661",
"i686-unknown-linux-musl-0.6.15": "82bf8666c0a57514af4e5403f162314b710e1682e1065ab71a845ebb5d8db0b7",
"powerpc64-unknown-linux-gnu-0.6.15": "6e9795344d61ee9ac497d6e03a447d808f2aab13925f30e44c00638abec57deb",
"powerpc64le-unknown-linux-gnu-0.6.15": "e38f13284ed8b645b87ef07c8b549d1f1a5b746aa0411c2115dcd5cda0da13fc",
"s390x-unknown-linux-gnu-0.6.15": "416f61249b330ea9735cda0c866c9460f87111bc9d4e040c98916fda6a45be09",
"x86_64-apple-darwin-0.6.15": "97adf61511c0f6ea42c090443c38d8d71116b78ae626363f9f149924c91ae886",
"x86_64-pc-windows-msvc-0.6.15": "10c75d566db1447f3bdcbcb31d6598e4b5f4ea638be5d8b73a7350929389512b",
"x86_64-unknown-linux-gnu-0.6.15": "85d98ef282cdbfcb4020922f0c12421ecca4130f0a4570d3b827a15ffd544acc",
"x86_64-unknown-linux-musl-0.6.15": "78289c93836cb32b8b24e3216b5b316e7fdf483365de2fc571844d308387e8a4",
"aarch64-apple-darwin-0.6.14": "4ea4731010fbd1bc8e790e07f199f55a5c7c2c732e9b77f85e302b0bee61b756", "aarch64-apple-darwin-0.6.14": "4ea4731010fbd1bc8e790e07f199f55a5c7c2c732e9b77f85e302b0bee61b756",
"aarch64-pc-windows-msvc-0.6.14": "7b0b3367c4060c9b47b961201ceb4252e97496c890ad1bd13c664bf5b0744d57", "aarch64-pc-windows-msvc-0.6.14": "7b0b3367c4060c9b47b961201ceb4252e97496c890ad1bd13c664bf5b0744d57",
"aarch64-unknown-linux-gnu-0.6.14": "ea25597354af186bdd55aee0de431e16d45d82951a4f41f065a8e4dc27885265", "aarch64-unknown-linux-gnu-0.6.14": "ea25597354af186bdd55aee0de431e16d45d82951a4f41f065a8e4dc27885265",
@@ -65268,8 +65319,10 @@ var paginatingEndpoints = [
"GET /notifications", "GET /notifications",
"GET /organizations", "GET /organizations",
"GET /orgs/{org}/actions/cache/usage-by-repository", "GET /orgs/{org}/actions/cache/usage-by-repository",
"GET /orgs/{org}/actions/hosted-runners",
"GET /orgs/{org}/actions/permissions/repositories", "GET /orgs/{org}/actions/permissions/repositories",
"GET /orgs/{org}/actions/runner-groups", "GET /orgs/{org}/actions/runner-groups",
"GET /orgs/{org}/actions/runner-groups/{runner_group_id}/hosted-runners",
"GET /orgs/{org}/actions/runner-groups/{runner_group_id}/repositories", "GET /orgs/{org}/actions/runner-groups/{runner_group_id}/repositories",
"GET /orgs/{org}/actions/runner-groups/{runner_group_id}/runners", "GET /orgs/{org}/actions/runner-groups/{runner_group_id}/runners",
"GET /orgs/{org}/actions/runners", "GET /orgs/{org}/actions/runners",
@@ -65279,6 +65332,7 @@ var paginatingEndpoints = [
"GET /orgs/{org}/actions/variables/{name}/repositories", "GET /orgs/{org}/actions/variables/{name}/repositories",
"GET /orgs/{org}/attestations/{subject_digest}", "GET /orgs/{org}/attestations/{subject_digest}",
"GET /orgs/{org}/blocks", "GET /orgs/{org}/blocks",
"GET /orgs/{org}/campaigns",
"GET /orgs/{org}/code-scanning/alerts", "GET /orgs/{org}/code-scanning/alerts",
"GET /orgs/{org}/code-security/configurations", "GET /orgs/{org}/code-security/configurations",
"GET /orgs/{org}/code-security/configurations/{configuration_id}/repositories", "GET /orgs/{org}/code-security/configurations/{configuration_id}/repositories",
@@ -65287,7 +65341,6 @@ var paginatingEndpoints = [
"GET /orgs/{org}/codespaces/secrets/{secret_name}/repositories", "GET /orgs/{org}/codespaces/secrets/{secret_name}/repositories",
"GET /orgs/{org}/copilot/billing/seats", "GET /orgs/{org}/copilot/billing/seats",
"GET /orgs/{org}/copilot/metrics", "GET /orgs/{org}/copilot/metrics",
"GET /orgs/{org}/copilot/usage",
"GET /orgs/{org}/dependabot/alerts", "GET /orgs/{org}/dependabot/alerts",
"GET /orgs/{org}/dependabot/secrets", "GET /orgs/{org}/dependabot/secrets",
"GET /orgs/{org}/dependabot/secrets/{secret_name}/repositories", "GET /orgs/{org}/dependabot/secrets/{secret_name}/repositories",
@@ -65322,10 +65375,11 @@ var paginatingEndpoints = [
"GET /orgs/{org}/repos", "GET /orgs/{org}/repos",
"GET /orgs/{org}/rulesets", "GET /orgs/{org}/rulesets",
"GET /orgs/{org}/rulesets/rule-suites", "GET /orgs/{org}/rulesets/rule-suites",
"GET /orgs/{org}/rulesets/{ruleset_id}/history",
"GET /orgs/{org}/secret-scanning/alerts", "GET /orgs/{org}/secret-scanning/alerts",
"GET /orgs/{org}/security-advisories", "GET /orgs/{org}/security-advisories",
"GET /orgs/{org}/settings/network-configurations",
"GET /orgs/{org}/team/{team_slug}/copilot/metrics", "GET /orgs/{org}/team/{team_slug}/copilot/metrics",
"GET /orgs/{org}/team/{team_slug}/copilot/usage",
"GET /orgs/{org}/teams", "GET /orgs/{org}/teams",
"GET /orgs/{org}/teams/{team_slug}/discussions", "GET /orgs/{org}/teams/{team_slug}/discussions",
"GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments", "GET /orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments",
@@ -65420,6 +65474,7 @@ var paginatingEndpoints = [
"GET /repos/{owner}/{repo}/rules/branches/{branch}", "GET /repos/{owner}/{repo}/rules/branches/{branch}",
"GET /repos/{owner}/{repo}/rulesets", "GET /repos/{owner}/{repo}/rulesets",
"GET /repos/{owner}/{repo}/rulesets/rule-suites", "GET /repos/{owner}/{repo}/rulesets/rule-suites",
"GET /repos/{owner}/{repo}/rulesets/{ruleset_id}/history",
"GET /repos/{owner}/{repo}/secret-scanning/alerts", "GET /repos/{owner}/{repo}/secret-scanning/alerts",
"GET /repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}/locations", "GET /repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}/locations",
"GET /repos/{owner}/{repo}/security-advisories", "GET /repos/{owner}/{repo}/security-advisories",
@@ -65531,7 +65586,7 @@ __nccwpck_require__.d(__webpack_exports__, {
}); });
;// CONCATENATED MODULE: ./node_modules/@octokit/plugin-rest-endpoint-methods/dist-src/version.js ;// CONCATENATED MODULE: ./node_modules/@octokit/plugin-rest-endpoint-methods/dist-src/version.js
const VERSION = "13.3.1"; const VERSION = "14.0.0";
//# sourceMappingURL=version.js.map //# sourceMappingURL=version.js.map
@@ -65562,6 +65617,7 @@ const Endpoints = {
createEnvironmentVariable: [ createEnvironmentVariable: [
"POST /repos/{owner}/{repo}/environments/{environment_name}/variables" "POST /repos/{owner}/{repo}/environments/{environment_name}/variables"
], ],
createHostedRunnerForOrg: ["POST /orgs/{org}/actions/hosted-runners"],
createOrUpdateEnvironmentSecret: [ createOrUpdateEnvironmentSecret: [
"PUT /repos/{owner}/{repo}/environments/{environment_name}/secrets/{secret_name}" "PUT /repos/{owner}/{repo}/environments/{environment_name}/secrets/{secret_name}"
], ],
@@ -65599,6 +65655,9 @@ const Endpoints = {
deleteEnvironmentVariable: [ deleteEnvironmentVariable: [
"DELETE /repos/{owner}/{repo}/environments/{environment_name}/variables/{name}" "DELETE /repos/{owner}/{repo}/environments/{environment_name}/variables/{name}"
], ],
deleteHostedRunnerForOrg: [
"DELETE /orgs/{org}/actions/hosted-runners/{hosted_runner_id}"
],
deleteOrgSecret: ["DELETE /orgs/{org}/actions/secrets/{secret_name}"], deleteOrgSecret: ["DELETE /orgs/{org}/actions/secrets/{secret_name}"],
deleteOrgVariable: ["DELETE /orgs/{org}/actions/variables/{name}"], deleteOrgVariable: ["DELETE /orgs/{org}/actions/variables/{name}"],
deleteRepoSecret: [ deleteRepoSecret: [
@@ -65687,6 +65746,24 @@ const Endpoints = {
getGithubActionsPermissionsRepository: [ getGithubActionsPermissionsRepository: [
"GET /repos/{owner}/{repo}/actions/permissions" "GET /repos/{owner}/{repo}/actions/permissions"
], ],
getHostedRunnerForOrg: [
"GET /orgs/{org}/actions/hosted-runners/{hosted_runner_id}"
],
getHostedRunnersGithubOwnedImagesForOrg: [
"GET /orgs/{org}/actions/hosted-runners/images/github-owned"
],
getHostedRunnersLimitsForOrg: [
"GET /orgs/{org}/actions/hosted-runners/limits"
],
getHostedRunnersMachineSpecsForOrg: [
"GET /orgs/{org}/actions/hosted-runners/machine-sizes"
],
getHostedRunnersPartnerImagesForOrg: [
"GET /orgs/{org}/actions/hosted-runners/images/partner"
],
getHostedRunnersPlatformsForOrg: [
"GET /orgs/{org}/actions/hosted-runners/platforms"
],
getJobForWorkflowRun: ["GET /repos/{owner}/{repo}/actions/jobs/{job_id}"], getJobForWorkflowRun: ["GET /repos/{owner}/{repo}/actions/jobs/{job_id}"],
getOrgPublicKey: ["GET /orgs/{org}/actions/secrets/public-key"], getOrgPublicKey: ["GET /orgs/{org}/actions/secrets/public-key"],
getOrgSecret: ["GET /orgs/{org}/actions/secrets/{secret_name}"], getOrgSecret: ["GET /orgs/{org}/actions/secrets/{secret_name}"],
@@ -65730,6 +65807,10 @@ const Endpoints = {
listEnvironmentVariables: [ listEnvironmentVariables: [
"GET /repos/{owner}/{repo}/environments/{environment_name}/variables" "GET /repos/{owner}/{repo}/environments/{environment_name}/variables"
], ],
listGithubHostedRunnersInGroupForOrg: [
"GET /orgs/{org}/actions/runner-groups/{runner_group_id}/hosted-runners"
],
listHostedRunnersForOrg: ["GET /orgs/{org}/actions/hosted-runners"],
listJobsForWorkflowRun: [ listJobsForWorkflowRun: [
"GET /repos/{owner}/{repo}/actions/runs/{run_id}/jobs" "GET /repos/{owner}/{repo}/actions/runs/{run_id}/jobs"
], ],
@@ -65848,6 +65929,9 @@ const Endpoints = {
updateEnvironmentVariable: [ updateEnvironmentVariable: [
"PATCH /repos/{owner}/{repo}/environments/{environment_name}/variables/{name}" "PATCH /repos/{owner}/{repo}/environments/{environment_name}/variables/{name}"
], ],
updateHostedRunnerForOrg: [
"PATCH /orgs/{org}/actions/hosted-runners/{hosted_runner_id}"
],
updateOrgVariable: ["PATCH /orgs/{org}/actions/variables/{name}"], updateOrgVariable: ["PATCH /orgs/{org}/actions/variables/{name}"],
updateRepoVariable: [ updateRepoVariable: [
"PATCH /repos/{owner}/{repo}/actions/variables/{name}" "PATCH /repos/{owner}/{repo}/actions/variables/{name}"
@@ -65989,6 +66073,13 @@ const Endpoints = {
"GET /users/{username}/settings/billing/shared-storage" "GET /users/{username}/settings/billing/shared-storage"
] ]
}, },
campaigns: {
createCampaign: ["POST /orgs/{org}/campaigns"],
deleteCampaign: ["DELETE /orgs/{org}/campaigns/{campaign_number}"],
getCampaignSummary: ["GET /orgs/{org}/campaigns/{campaign_number}"],
listOrgCampaigns: ["GET /orgs/{org}/campaigns"],
updateCampaign: ["PATCH /orgs/{org}/campaigns/{campaign_number}"]
},
checks: { checks: {
create: ["POST /repos/{owner}/{repo}/check-runs"], create: ["POST /repos/{owner}/{repo}/check-runs"],
createSuite: ["POST /repos/{owner}/{repo}/check-suites"], createSuite: ["POST /repos/{owner}/{repo}/check-suites"],
@@ -66267,9 +66358,7 @@ const Endpoints = {
getCopilotSeatDetailsForUser: [ getCopilotSeatDetailsForUser: [
"GET /orgs/{org}/members/{username}/copilot" "GET /orgs/{org}/members/{username}/copilot"
], ],
listCopilotSeats: ["GET /orgs/{org}/copilot/billing/seats"], listCopilotSeats: ["GET /orgs/{org}/copilot/billing/seats"]
usageMetricsForOrg: ["GET /orgs/{org}/copilot/usage"],
usageMetricsForTeam: ["GET /orgs/{org}/team/{team_slug}/copilot/usage"]
}, },
dependabot: { dependabot: {
addSelectedRepoToOrgSecret: [ addSelectedRepoToOrgSecret: [
@@ -66365,6 +66454,26 @@ const Endpoints = {
getAllTemplates: ["GET /gitignore/templates"], getAllTemplates: ["GET /gitignore/templates"],
getTemplate: ["GET /gitignore/templates/{name}"] getTemplate: ["GET /gitignore/templates/{name}"]
}, },
hostedCompute: {
createNetworkConfigurationForOrg: [
"POST /orgs/{org}/settings/network-configurations"
],
deleteNetworkConfigurationFromOrg: [
"DELETE /orgs/{org}/settings/network-configurations/{network_configuration_id}"
],
getNetworkConfigurationForOrg: [
"GET /orgs/{org}/settings/network-configurations/{network_configuration_id}"
],
getNetworkSettingsForOrg: [
"GET /orgs/{org}/settings/network-settings/{network_settings_id}"
],
listNetworkConfigurationsForOrg: [
"GET /orgs/{org}/settings/network-configurations"
],
updateNetworkConfigurationForOrg: [
"PATCH /orgs/{org}/settings/network-configurations/{network_configuration_id}"
]
},
interactions: { interactions: {
getRestrictionsForAuthenticatedUser: ["GET /user/interaction-limits"], getRestrictionsForAuthenticatedUser: ["GET /user/interaction-limits"],
getRestrictionsForOrg: ["GET /orgs/{org}/interaction-limits"], getRestrictionsForOrg: ["GET /orgs/{org}/interaction-limits"],
@@ -66556,6 +66665,7 @@ const Endpoints = {
"PUT /orgs/{org}/outside_collaborators/{username}" "PUT /orgs/{org}/outside_collaborators/{username}"
], ],
createInvitation: ["POST /orgs/{org}/invitations"], createInvitation: ["POST /orgs/{org}/invitations"],
createIssueType: ["POST /orgs/{org}/issue-types"],
createOrUpdateCustomProperties: ["PATCH /orgs/{org}/properties/schema"], createOrUpdateCustomProperties: ["PATCH /orgs/{org}/properties/schema"],
createOrUpdateCustomPropertiesValuesForRepos: [ createOrUpdateCustomPropertiesValuesForRepos: [
"PATCH /orgs/{org}/properties/values" "PATCH /orgs/{org}/properties/values"
@@ -66565,6 +66675,7 @@ const Endpoints = {
], ],
createWebhook: ["POST /orgs/{org}/hooks"], createWebhook: ["POST /orgs/{org}/hooks"],
delete: ["DELETE /orgs/{org}"], delete: ["DELETE /orgs/{org}"],
deleteIssueType: ["DELETE /orgs/{org}/issue-types/{issue_type_id}"],
deleteWebhook: ["DELETE /orgs/{org}/hooks/{hook_id}"], deleteWebhook: ["DELETE /orgs/{org}/hooks/{hook_id}"],
enableOrDisableSecurityProductOnAllOrgRepos: [ enableOrDisableSecurityProductOnAllOrgRepos: [
"POST /orgs/{org}/{security_product}/{enablement}", "POST /orgs/{org}/{security_product}/{enablement}",
@@ -66581,6 +66692,10 @@ const Endpoints = {
getMembershipForAuthenticatedUser: ["GET /user/memberships/orgs/{org}"], getMembershipForAuthenticatedUser: ["GET /user/memberships/orgs/{org}"],
getMembershipForUser: ["GET /orgs/{org}/memberships/{username}"], getMembershipForUser: ["GET /orgs/{org}/memberships/{username}"],
getOrgRole: ["GET /orgs/{org}/organization-roles/{role_id}"], getOrgRole: ["GET /orgs/{org}/organization-roles/{role_id}"],
getOrgRulesetHistory: ["GET /orgs/{org}/rulesets/{ruleset_id}/history"],
getOrgRulesetVersion: [
"GET /orgs/{org}/rulesets/{ruleset_id}/history/{version_id}"
],
getWebhook: ["GET /orgs/{org}/hooks/{hook_id}"], getWebhook: ["GET /orgs/{org}/hooks/{hook_id}"],
getWebhookConfigForOrg: ["GET /orgs/{org}/hooks/{hook_id}/config"], getWebhookConfigForOrg: ["GET /orgs/{org}/hooks/{hook_id}/config"],
getWebhookDelivery: [ getWebhookDelivery: [
@@ -66595,6 +66710,7 @@ const Endpoints = {
listForAuthenticatedUser: ["GET /user/orgs"], listForAuthenticatedUser: ["GET /user/orgs"],
listForUser: ["GET /users/{username}/orgs"], listForUser: ["GET /users/{username}/orgs"],
listInvitationTeams: ["GET /orgs/{org}/invitations/{invitation_id}/teams"], listInvitationTeams: ["GET /orgs/{org}/invitations/{invitation_id}/teams"],
listIssueTypes: ["GET /orgs/{org}/issue-types"],
listMembers: ["GET /orgs/{org}/members"], listMembers: ["GET /orgs/{org}/members"],
listMembershipsForAuthenticatedUser: ["GET /user/memberships/orgs"], listMembershipsForAuthenticatedUser: ["GET /user/memberships/orgs"],
listOrgRoleTeams: ["GET /orgs/{org}/organization-roles/{role_id}/teams"], listOrgRoleTeams: ["GET /orgs/{org}/organization-roles/{role_id}/teams"],
@@ -66669,6 +66785,7 @@ const Endpoints = {
], ],
unblockUser: ["DELETE /orgs/{org}/blocks/{username}"], unblockUser: ["DELETE /orgs/{org}/blocks/{username}"],
update: ["PATCH /orgs/{org}"], update: ["PATCH /orgs/{org}"],
updateIssueType: ["PUT /orgs/{org}/issue-types/{issue_type_id}"],
updateMembershipForAuthenticatedUser: [ updateMembershipForAuthenticatedUser: [
"PATCH /user/memberships/orgs/{org}" "PATCH /user/memberships/orgs/{org}"
], ],
@@ -66781,37 +66898,6 @@ const Endpoints = {
"PATCH /orgs/{org}/private-registries/{secret_name}" "PATCH /orgs/{org}/private-registries/{secret_name}"
] ]
}, },
projects: {
addCollaborator: ["PUT /projects/{project_id}/collaborators/{username}"],
createCard: ["POST /projects/columns/{column_id}/cards"],
createColumn: ["POST /projects/{project_id}/columns"],
createForAuthenticatedUser: ["POST /user/projects"],
createForOrg: ["POST /orgs/{org}/projects"],
createForRepo: ["POST /repos/{owner}/{repo}/projects"],
delete: ["DELETE /projects/{project_id}"],
deleteCard: ["DELETE /projects/columns/cards/{card_id}"],
deleteColumn: ["DELETE /projects/columns/{column_id}"],
get: ["GET /projects/{project_id}"],
getCard: ["GET /projects/columns/cards/{card_id}"],
getColumn: ["GET /projects/columns/{column_id}"],
getPermissionForUser: [
"GET /projects/{project_id}/collaborators/{username}/permission"
],
listCards: ["GET /projects/columns/{column_id}/cards"],
listCollaborators: ["GET /projects/{project_id}/collaborators"],
listColumns: ["GET /projects/{project_id}/columns"],
listForOrg: ["GET /orgs/{org}/projects"],
listForRepo: ["GET /repos/{owner}/{repo}/projects"],
listForUser: ["GET /users/{username}/projects"],
moveCard: ["POST /projects/columns/cards/{card_id}/moves"],
moveColumn: ["POST /projects/columns/{column_id}/moves"],
removeCollaborator: [
"DELETE /projects/{project_id}/collaborators/{username}"
],
update: ["PATCH /projects/{project_id}"],
updateCard: ["PATCH /projects/columns/cards/{card_id}"],
updateColumn: ["PATCH /projects/columns/{column_id}"]
},
pulls: { pulls: {
checkIfMerged: ["GET /repos/{owner}/{repo}/pulls/{pull_number}/merge"], checkIfMerged: ["GET /repos/{owner}/{repo}/pulls/{pull_number}/merge"],
create: ["POST /repos/{owner}/{repo}/pulls"], create: ["POST /repos/{owner}/{repo}/pulls"],
@@ -67183,6 +67269,12 @@ const Endpoints = {
], ],
getRepoRuleSuites: ["GET /repos/{owner}/{repo}/rulesets/rule-suites"], getRepoRuleSuites: ["GET /repos/{owner}/{repo}/rulesets/rule-suites"],
getRepoRuleset: ["GET /repos/{owner}/{repo}/rulesets/{ruleset_id}"], getRepoRuleset: ["GET /repos/{owner}/{repo}/rulesets/{ruleset_id}"],
getRepoRulesetHistory: [
"GET /repos/{owner}/{repo}/rulesets/{ruleset_id}/history"
],
getRepoRulesetVersion: [
"GET /repos/{owner}/{repo}/rulesets/{ruleset_id}/history/{version_id}"
],
getRepoRulesets: ["GET /repos/{owner}/{repo}/rulesets"], getRepoRulesets: ["GET /repos/{owner}/{repo}/rulesets"],
getStatusChecksProtection: [ getStatusChecksProtection: [
"GET /repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks" "GET /repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks"
@@ -67356,7 +67448,13 @@ const Endpoints = {
search: { search: {
code: ["GET /search/code"], code: ["GET /search/code"],
commits: ["GET /search/commits"], commits: ["GET /search/commits"],
issuesAndPullRequests: ["GET /search/issues"], issuesAndPullRequests: [
"GET /search/issues",
{},
{
deprecated: "octokit.rest.search.issuesAndPullRequests() is deprecated, see https://docs.github.com/rest/search/search#search-issues-and-pull-requests"
}
],
labels: ["GET /search/labels"], labels: ["GET /search/labels"],
repos: ["GET /search/repositories"], repos: ["GET /search/repositories"],
topics: ["GET /search/topics"], topics: ["GET /search/topics"],
@@ -67410,15 +67508,9 @@ const Endpoints = {
addOrUpdateMembershipForUserInOrg: [ addOrUpdateMembershipForUserInOrg: [
"PUT /orgs/{org}/teams/{team_slug}/memberships/{username}" "PUT /orgs/{org}/teams/{team_slug}/memberships/{username}"
], ],
addOrUpdateProjectPermissionsInOrg: [
"PUT /orgs/{org}/teams/{team_slug}/projects/{project_id}"
],
addOrUpdateRepoPermissionsInOrg: [ addOrUpdateRepoPermissionsInOrg: [
"PUT /orgs/{org}/teams/{team_slug}/repos/{owner}/{repo}" "PUT /orgs/{org}/teams/{team_slug}/repos/{owner}/{repo}"
], ],
checkPermissionsForProjectInOrg: [
"GET /orgs/{org}/teams/{team_slug}/projects/{project_id}"
],
checkPermissionsForRepoInOrg: [ checkPermissionsForRepoInOrg: [
"GET /orgs/{org}/teams/{team_slug}/repos/{owner}/{repo}" "GET /orgs/{org}/teams/{team_slug}/repos/{owner}/{repo}"
], ],
@@ -67455,14 +67547,10 @@ const Endpoints = {
listPendingInvitationsInOrg: [ listPendingInvitationsInOrg: [
"GET /orgs/{org}/teams/{team_slug}/invitations" "GET /orgs/{org}/teams/{team_slug}/invitations"
], ],
listProjectsInOrg: ["GET /orgs/{org}/teams/{team_slug}/projects"],
listReposInOrg: ["GET /orgs/{org}/teams/{team_slug}/repos"], listReposInOrg: ["GET /orgs/{org}/teams/{team_slug}/repos"],
removeMembershipForUserInOrg: [ removeMembershipForUserInOrg: [
"DELETE /orgs/{org}/teams/{team_slug}/memberships/{username}" "DELETE /orgs/{org}/teams/{team_slug}/memberships/{username}"
], ],
removeProjectInOrg: [
"DELETE /orgs/{org}/teams/{team_slug}/projects/{project_id}"
],
removeRepoInOrg: [ removeRepoInOrg: [
"DELETE /orgs/{org}/teams/{team_slug}/repos/{owner}/{repo}" "DELETE /orgs/{org}/teams/{team_slug}/repos/{owner}/{repo}"
], ],

185
package-lock.json generated
View File

@@ -16,20 +16,20 @@
"@actions/io": "^1.1.3", "@actions/io": "^1.1.3",
"@actions/tool-cache": "^2.0.2", "@actions/tool-cache": "^2.0.2",
"@octokit/core": "^6.1.4", "@octokit/core": "^6.1.4",
"@octokit/plugin-paginate-rest": "^11.4.3", "@octokit/plugin-paginate-rest": "^12.0.0",
"@octokit/plugin-rest-endpoint-methods": "^13.3.1", "@octokit/plugin-rest-endpoint-methods": "^14.0.0",
"@renovatebot/pep440": "^4.1.0", "@renovatebot/pep440": "^4.1.0",
"smol-toml": "^1.3.1", "smol-toml": "^1.3.1",
"undici": "^7.5.0" "undici": "^7.5.0"
}, },
"devDependencies": { "devDependencies": {
"@biomejs/biome": "1.9.4", "@biomejs/biome": "1.9.4",
"@types/node": "^22.13.10", "@types/node": "^22.15.3",
"@types/semver": "^7.5.8", "@types/semver": "^7.7.0",
"@vercel/ncc": "^0.38.3", "@vercel/ncc": "^0.38.3",
"jest": "^29.7.0", "jest": "^29.7.0",
"js-yaml": "^4.1.0", "js-yaml": "^4.1.0",
"ts-jest": "^29.2.6", "ts-jest": "^29.3.2",
"typescript": "^5.8.2" "typescript": "^5.8.2"
} }
}, },
@@ -1567,11 +1567,12 @@
"integrity": "sha512-izFjMJ1sir0jn0ldEKhZ7xegCTj/ObmEDlEfpFrx4k/JyZSMRHbO3/rBwgE7f3m2DHt+RrNGIVw4wSmwnm3t/g==" "integrity": "sha512-izFjMJ1sir0jn0ldEKhZ7xegCTj/ObmEDlEfpFrx4k/JyZSMRHbO3/rBwgE7f3m2DHt+RrNGIVw4wSmwnm3t/g=="
}, },
"node_modules/@octokit/plugin-paginate-rest": { "node_modules/@octokit/plugin-paginate-rest": {
"version": "11.4.3", "version": "12.0.0",
"resolved": "https://registry.npmjs.org/@octokit/plugin-paginate-rest/-/plugin-paginate-rest-11.4.3.tgz", "resolved": "https://registry.npmjs.org/@octokit/plugin-paginate-rest/-/plugin-paginate-rest-12.0.0.tgz",
"integrity": "sha512-tBXaAbXkqVJlRoA/zQVe9mUdb8rScmivqtpv3ovsC5xhje/a+NOCivs7eUhWBwCApJVsR4G5HMeaLbq7PxqZGA==", "integrity": "sha512-MPd6WK1VtZ52lFrgZ0R2FlaoiWllzgqFHaSZxvp72NmoDeZ0m8GeJdg4oB6ctqMTYyrnDYp592Xma21mrgiyDA==",
"license": "MIT",
"dependencies": { "dependencies": {
"@octokit/types": "^13.7.0" "@octokit/types": "^14.0.0"
}, },
"engines": { "engines": {
"node": ">= 18" "node": ">= 18"
@@ -1580,12 +1581,28 @@
"@octokit/core": ">=6" "@octokit/core": ">=6"
} }
}, },
"node_modules/@octokit/plugin-rest-endpoint-methods": { "node_modules/@octokit/plugin-paginate-rest/node_modules/@octokit/openapi-types": {
"version": "13.3.1", "version": "25.0.0",
"resolved": "https://registry.npmjs.org/@octokit/plugin-rest-endpoint-methods/-/plugin-rest-endpoint-methods-13.3.1.tgz", "resolved": "https://registry.npmjs.org/@octokit/openapi-types/-/openapi-types-25.0.0.tgz",
"integrity": "sha512-o8uOBdsyR+WR8MK9Cco8dCgvG13H1RlM1nWnK/W7TEACQBFux/vPREgKucxUfuDQ5yi1T3hGf4C5ZmZXAERgwQ==", "integrity": "sha512-FZvktFu7HfOIJf2BScLKIEYjDsw6RKc7rBJCdvCTfKsVnx2GEB/Nbzjr29DUdb7vQhlzS/j8qDzdditP0OC6aw==",
"license": "MIT"
},
"node_modules/@octokit/plugin-paginate-rest/node_modules/@octokit/types": {
"version": "14.0.0",
"resolved": "https://registry.npmjs.org/@octokit/types/-/types-14.0.0.tgz",
"integrity": "sha512-VVmZP0lEhbo2O1pdq63gZFiGCKkm8PPp8AUOijlwPO6hojEVjspA0MWKP7E4hbvGxzFKNqKr6p0IYtOH/Wf/zA==",
"license": "MIT",
"dependencies": { "dependencies": {
"@octokit/types": "^13.8.0" "@octokit/openapi-types": "^25.0.0"
}
},
"node_modules/@octokit/plugin-rest-endpoint-methods": {
"version": "14.0.0",
"resolved": "https://registry.npmjs.org/@octokit/plugin-rest-endpoint-methods/-/plugin-rest-endpoint-methods-14.0.0.tgz",
"integrity": "sha512-iQt6ovem4b7zZYZQtdv+PwgbL5VPq37th1m2x2TdkgimIDJpsi2A6Q/OI/23i/hR6z5mL0EgisNR4dcbmckSZQ==",
"license": "MIT",
"dependencies": {
"@octokit/types": "^14.0.0"
}, },
"engines": { "engines": {
"node": ">= 18" "node": ">= 18"
@@ -1594,6 +1611,21 @@
"@octokit/core": ">=6" "@octokit/core": ">=6"
} }
}, },
"node_modules/@octokit/plugin-rest-endpoint-methods/node_modules/@octokit/openapi-types": {
"version": "25.0.0",
"resolved": "https://registry.npmjs.org/@octokit/openapi-types/-/openapi-types-25.0.0.tgz",
"integrity": "sha512-FZvktFu7HfOIJf2BScLKIEYjDsw6RKc7rBJCdvCTfKsVnx2GEB/Nbzjr29DUdb7vQhlzS/j8qDzdditP0OC6aw==",
"license": "MIT"
},
"node_modules/@octokit/plugin-rest-endpoint-methods/node_modules/@octokit/types": {
"version": "14.0.0",
"resolved": "https://registry.npmjs.org/@octokit/types/-/types-14.0.0.tgz",
"integrity": "sha512-VVmZP0lEhbo2O1pdq63gZFiGCKkm8PPp8AUOijlwPO6hojEVjspA0MWKP7E4hbvGxzFKNqKr6p0IYtOH/Wf/zA==",
"license": "MIT",
"dependencies": {
"@octokit/openapi-types": "^25.0.0"
}
},
"node_modules/@octokit/request": { "node_modules/@octokit/request": {
"version": "9.2.2", "version": "9.2.2",
"resolved": "https://registry.npmjs.org/@octokit/request/-/request-9.2.2.tgz", "resolved": "https://registry.npmjs.org/@octokit/request/-/request-9.2.2.tgz",
@@ -1815,11 +1847,12 @@
} }
}, },
"node_modules/@types/node": { "node_modules/@types/node": {
"version": "22.13.10", "version": "22.15.3",
"resolved": "https://registry.npmjs.org/@types/node/-/node-22.13.10.tgz", "resolved": "https://registry.npmjs.org/@types/node/-/node-22.15.3.tgz",
"integrity": "sha512-I6LPUvlRH+O6VRUqYOcMudhaIdUVWfsjnZavnsraHvpBwaEyMN29ry+0UVJhImYL16xsscu0aske3yA+uPOWfw==", "integrity": "sha512-lX7HFZeHf4QG/J7tBZqrCAXwz9J5RD56Y6MpP0eJkka8p+K0RY/yBTW7CYFJ4VGCclxqOLKmiGP5juQc6MKgcw==",
"license": "MIT",
"dependencies": { "dependencies": {
"undici-types": "~6.20.0" "undici-types": "~6.21.0"
} }
}, },
"node_modules/@types/node-fetch": { "node_modules/@types/node-fetch": {
@@ -1845,10 +1878,11 @@
} }
}, },
"node_modules/@types/semver": { "node_modules/@types/semver": {
"version": "7.5.8", "version": "7.7.0",
"resolved": "https://registry.npmjs.org/@types/semver/-/semver-7.5.8.tgz", "resolved": "https://registry.npmjs.org/@types/semver/-/semver-7.7.0.tgz",
"integrity": "sha512-I8EUhyrgfLrcTkzV3TSsGyl1tSuPrEDzr0yd5m90UgNxQkyDXULk3b6MlQqTCpZpNtWe1K0hzclnZkTcLBe2UQ==", "integrity": "sha512-k107IF4+Xr7UHjwDc7Cfd6PRQfbdkiRabXGRjo07b4WyPahFBZCZ1sE+BNxYIJPPg73UkfOsVOLwqVc/6ETrIA==",
"dev": true "dev": true,
"license": "MIT"
}, },
"node_modules/@types/stack-utils": { "node_modules/@types/stack-utils": {
"version": "2.0.1", "version": "2.0.1",
@@ -4360,10 +4394,11 @@
"integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==" "integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw=="
}, },
"node_modules/ts-jest": { "node_modules/ts-jest": {
"version": "29.2.6", "version": "29.3.2",
"resolved": "https://registry.npmjs.org/ts-jest/-/ts-jest-29.2.6.tgz", "resolved": "https://registry.npmjs.org/ts-jest/-/ts-jest-29.3.2.tgz",
"integrity": "sha512-yTNZVZqc8lSixm+QGVFcPe6+yj7+TWZwIesuOWvfcn4B9bz5x4NDzVCQQjOs7Hfouu36aEqfEbo9Qpo+gq8dDg==", "integrity": "sha512-bJJkrWc6PjFVz5g2DGCNUo8z7oFEYaz1xP1NpeDU7KNLMWPpEyV8Chbpkn8xjzgRDpQhnGMyvyldoL7h8JXyug==",
"dev": true, "dev": true,
"license": "MIT",
"dependencies": { "dependencies": {
"bs-logger": "^0.2.6", "bs-logger": "^0.2.6",
"ejs": "^3.1.10", "ejs": "^3.1.10",
@@ -4373,6 +4408,7 @@
"lodash.memoize": "^4.1.2", "lodash.memoize": "^4.1.2",
"make-error": "^1.3.6", "make-error": "^1.3.6",
"semver": "^7.7.1", "semver": "^7.7.1",
"type-fest": "^4.39.1",
"yargs-parser": "^21.1.1" "yargs-parser": "^21.1.1"
}, },
"bin": { "bin": {
@@ -4441,6 +4477,19 @@
"node": ">=4" "node": ">=4"
} }
}, },
"node_modules/type-fest": {
"version": "4.40.1",
"resolved": "https://registry.npmjs.org/type-fest/-/type-fest-4.40.1.tgz",
"integrity": "sha512-9YvLNnORDpI+vghLU/Nf+zSv0kL47KbVJ1o3sKgoTefl6i+zebxbiDQWoe/oWWqPhIgQdRZRT1KA9sCPL810SA==",
"dev": true,
"license": "(MIT OR CC0-1.0)",
"engines": {
"node": ">=16"
},
"funding": {
"url": "https://github.com/sponsors/sindresorhus"
}
},
"node_modules/typescript": { "node_modules/typescript": {
"version": "5.8.2", "version": "5.8.2",
"resolved": "https://registry.npmjs.org/typescript/-/typescript-5.8.2.tgz", "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.8.2.tgz",
@@ -4463,9 +4512,10 @@
} }
}, },
"node_modules/undici-types": { "node_modules/undici-types": {
"version": "6.20.0", "version": "6.21.0",
"resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.21.0.tgz",
"integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==" "integrity": "sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ==",
"license": "MIT"
}, },
"node_modules/universal-user-agent": { "node_modules/universal-user-agent": {
"version": "7.0.2", "version": "7.0.2",
@@ -5843,19 +5893,49 @@
"integrity": "sha512-izFjMJ1sir0jn0ldEKhZ7xegCTj/ObmEDlEfpFrx4k/JyZSMRHbO3/rBwgE7f3m2DHt+RrNGIVw4wSmwnm3t/g==" "integrity": "sha512-izFjMJ1sir0jn0ldEKhZ7xegCTj/ObmEDlEfpFrx4k/JyZSMRHbO3/rBwgE7f3m2DHt+RrNGIVw4wSmwnm3t/g=="
}, },
"@octokit/plugin-paginate-rest": { "@octokit/plugin-paginate-rest": {
"version": "11.4.3", "version": "12.0.0",
"resolved": "https://registry.npmjs.org/@octokit/plugin-paginate-rest/-/plugin-paginate-rest-11.4.3.tgz", "resolved": "https://registry.npmjs.org/@octokit/plugin-paginate-rest/-/plugin-paginate-rest-12.0.0.tgz",
"integrity": "sha512-tBXaAbXkqVJlRoA/zQVe9mUdb8rScmivqtpv3ovsC5xhje/a+NOCivs7eUhWBwCApJVsR4G5HMeaLbq7PxqZGA==", "integrity": "sha512-MPd6WK1VtZ52lFrgZ0R2FlaoiWllzgqFHaSZxvp72NmoDeZ0m8GeJdg4oB6ctqMTYyrnDYp592Xma21mrgiyDA==",
"requires": { "requires": {
"@octokit/types": "^13.7.0" "@octokit/types": "^14.0.0"
},
"dependencies": {
"@octokit/openapi-types": {
"version": "25.0.0",
"resolved": "https://registry.npmjs.org/@octokit/openapi-types/-/openapi-types-25.0.0.tgz",
"integrity": "sha512-FZvktFu7HfOIJf2BScLKIEYjDsw6RKc7rBJCdvCTfKsVnx2GEB/Nbzjr29DUdb7vQhlzS/j8qDzdditP0OC6aw=="
},
"@octokit/types": {
"version": "14.0.0",
"resolved": "https://registry.npmjs.org/@octokit/types/-/types-14.0.0.tgz",
"integrity": "sha512-VVmZP0lEhbo2O1pdq63gZFiGCKkm8PPp8AUOijlwPO6hojEVjspA0MWKP7E4hbvGxzFKNqKr6p0IYtOH/Wf/zA==",
"requires": {
"@octokit/openapi-types": "^25.0.0"
}
}
} }
}, },
"@octokit/plugin-rest-endpoint-methods": { "@octokit/plugin-rest-endpoint-methods": {
"version": "13.3.1", "version": "14.0.0",
"resolved": "https://registry.npmjs.org/@octokit/plugin-rest-endpoint-methods/-/plugin-rest-endpoint-methods-13.3.1.tgz", "resolved": "https://registry.npmjs.org/@octokit/plugin-rest-endpoint-methods/-/plugin-rest-endpoint-methods-14.0.0.tgz",
"integrity": "sha512-o8uOBdsyR+WR8MK9Cco8dCgvG13H1RlM1nWnK/W7TEACQBFux/vPREgKucxUfuDQ5yi1T3hGf4C5ZmZXAERgwQ==", "integrity": "sha512-iQt6ovem4b7zZYZQtdv+PwgbL5VPq37th1m2x2TdkgimIDJpsi2A6Q/OI/23i/hR6z5mL0EgisNR4dcbmckSZQ==",
"requires": { "requires": {
"@octokit/types": "^13.8.0" "@octokit/types": "^14.0.0"
},
"dependencies": {
"@octokit/openapi-types": {
"version": "25.0.0",
"resolved": "https://registry.npmjs.org/@octokit/openapi-types/-/openapi-types-25.0.0.tgz",
"integrity": "sha512-FZvktFu7HfOIJf2BScLKIEYjDsw6RKc7rBJCdvCTfKsVnx2GEB/Nbzjr29DUdb7vQhlzS/j8qDzdditP0OC6aw=="
},
"@octokit/types": {
"version": "14.0.0",
"resolved": "https://registry.npmjs.org/@octokit/types/-/types-14.0.0.tgz",
"integrity": "sha512-VVmZP0lEhbo2O1pdq63gZFiGCKkm8PPp8AUOijlwPO6hojEVjspA0MWKP7E4hbvGxzFKNqKr6p0IYtOH/Wf/zA==",
"requires": {
"@octokit/openapi-types": "^25.0.0"
}
}
} }
}, },
"@octokit/request": { "@octokit/request": {
@@ -6048,11 +6128,11 @@
} }
}, },
"@types/node": { "@types/node": {
"version": "22.13.10", "version": "22.15.3",
"resolved": "https://registry.npmjs.org/@types/node/-/node-22.13.10.tgz", "resolved": "https://registry.npmjs.org/@types/node/-/node-22.15.3.tgz",
"integrity": "sha512-I6LPUvlRH+O6VRUqYOcMudhaIdUVWfsjnZavnsraHvpBwaEyMN29ry+0UVJhImYL16xsscu0aske3yA+uPOWfw==", "integrity": "sha512-lX7HFZeHf4QG/J7tBZqrCAXwz9J5RD56Y6MpP0eJkka8p+K0RY/yBTW7CYFJ4VGCclxqOLKmiGP5juQc6MKgcw==",
"requires": { "requires": {
"undici-types": "~6.20.0" "undici-types": "~6.21.0"
} }
}, },
"@types/node-fetch": { "@types/node-fetch": {
@@ -6077,9 +6157,9 @@
} }
}, },
"@types/semver": { "@types/semver": {
"version": "7.5.8", "version": "7.7.0",
"resolved": "https://registry.npmjs.org/@types/semver/-/semver-7.5.8.tgz", "resolved": "https://registry.npmjs.org/@types/semver/-/semver-7.7.0.tgz",
"integrity": "sha512-I8EUhyrgfLrcTkzV3TSsGyl1tSuPrEDzr0yd5m90UgNxQkyDXULk3b6MlQqTCpZpNtWe1K0hzclnZkTcLBe2UQ==", "integrity": "sha512-k107IF4+Xr7UHjwDc7Cfd6PRQfbdkiRabXGRjo07b4WyPahFBZCZ1sE+BNxYIJPPg73UkfOsVOLwqVc/6ETrIA==",
"dev": true "dev": true
}, },
"@types/stack-utils": { "@types/stack-utils": {
@@ -7933,9 +8013,9 @@
"integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==" "integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw=="
}, },
"ts-jest": { "ts-jest": {
"version": "29.2.6", "version": "29.3.2",
"resolved": "https://registry.npmjs.org/ts-jest/-/ts-jest-29.2.6.tgz", "resolved": "https://registry.npmjs.org/ts-jest/-/ts-jest-29.3.2.tgz",
"integrity": "sha512-yTNZVZqc8lSixm+QGVFcPe6+yj7+TWZwIesuOWvfcn4B9bz5x4NDzVCQQjOs7Hfouu36aEqfEbo9Qpo+gq8dDg==", "integrity": "sha512-bJJkrWc6PjFVz5g2DGCNUo8z7oFEYaz1xP1NpeDU7KNLMWPpEyV8Chbpkn8xjzgRDpQhnGMyvyldoL7h8JXyug==",
"dev": true, "dev": true,
"requires": { "requires": {
"bs-logger": "^0.2.6", "bs-logger": "^0.2.6",
@@ -7946,6 +8026,7 @@
"lodash.memoize": "^4.1.2", "lodash.memoize": "^4.1.2",
"make-error": "^1.3.6", "make-error": "^1.3.6",
"semver": "^7.7.1", "semver": "^7.7.1",
"type-fest": "^4.39.1",
"yargs-parser": "^21.1.1" "yargs-parser": "^21.1.1"
}, },
"dependencies": { "dependencies": {
@@ -7973,6 +8054,12 @@
"integrity": "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==", "integrity": "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==",
"dev": true "dev": true
}, },
"type-fest": {
"version": "4.40.1",
"resolved": "https://registry.npmjs.org/type-fest/-/type-fest-4.40.1.tgz",
"integrity": "sha512-9YvLNnORDpI+vghLU/Nf+zSv0kL47KbVJ1o3sKgoTefl6i+zebxbiDQWoe/oWWqPhIgQdRZRT1KA9sCPL810SA==",
"dev": true
},
"typescript": { "typescript": {
"version": "5.8.2", "version": "5.8.2",
"resolved": "https://registry.npmjs.org/typescript/-/typescript-5.8.2.tgz", "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.8.2.tgz",
@@ -7985,9 +8072,9 @@
"integrity": "sha512-NFQG741e8mJ0fLQk90xKxFdaSM7z4+IQpAgsFI36bCDY9Z2+aXXZjVy2uUksMouWfMI9+w5ejOq5zYYTBCQJDQ==" "integrity": "sha512-NFQG741e8mJ0fLQk90xKxFdaSM7z4+IQpAgsFI36bCDY9Z2+aXXZjVy2uUksMouWfMI9+w5ejOq5zYYTBCQJDQ=="
}, },
"undici-types": { "undici-types": {
"version": "6.20.0", "version": "6.21.0",
"resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.21.0.tgz",
"integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==" "integrity": "sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ=="
}, },
"universal-user-agent": { "universal-user-agent": {
"version": "7.0.2", "version": "7.0.2",

View File

@@ -30,20 +30,20 @@
"@actions/io": "^1.1.3", "@actions/io": "^1.1.3",
"@actions/tool-cache": "^2.0.2", "@actions/tool-cache": "^2.0.2",
"@octokit/core": "^6.1.4", "@octokit/core": "^6.1.4",
"@octokit/plugin-paginate-rest": "^11.4.3", "@octokit/plugin-paginate-rest": "^12.0.0",
"@octokit/plugin-rest-endpoint-methods": "^13.3.1", "@octokit/plugin-rest-endpoint-methods": "^14.0.0",
"@renovatebot/pep440": "^4.1.0", "@renovatebot/pep440": "^4.1.0",
"smol-toml": "^1.3.1", "smol-toml": "^1.3.1",
"undici": "^7.5.0" "undici": "^7.5.0"
}, },
"devDependencies": { "devDependencies": {
"@biomejs/biome": "1.9.4", "@biomejs/biome": "1.9.4",
"@types/node": "^22.13.10", "@types/node": "^22.15.3",
"@types/semver": "^7.5.8", "@types/semver": "^7.7.0",
"@vercel/ncc": "^0.38.3", "@vercel/ncc": "^0.38.3",
"jest": "^29.7.0", "jest": "^29.7.0",
"js-yaml": "^4.1.0", "js-yaml": "^4.1.0",
"ts-jest": "^29.2.6", "ts-jest": "^29.3.2",
"typescript": "^5.8.2" "typescript": "^5.8.2"
} }
} }

View File

@@ -5,6 +5,7 @@ import {
cacheLocalPath, cacheLocalPath,
cacheSuffix, cacheSuffix,
pythonVersion as pythonVersionInput, pythonVersion as pythonVersionInput,
workingDirectory,
} from "../utils/inputs"; } from "../utils/inputs";
import { getArch, getPlatform } from "../utils/platforms"; import { getArch, getPlatform } from "../utils/platforms";
import { hashFiles } from "../hash/hash-files"; import { hashFiles } from "../hash/hash-files";
@@ -73,7 +74,7 @@ async function getPythonVersion(): Promise<string> {
}; };
try { try {
const execArgs = ["python", "find"]; const execArgs = ["python", "find", "--directory", workingDirectory];
await exec.exec("uv", execArgs, options); await exec.exec("uv", execArgs, options);
const pythonPath = output.trim(); const pythonPath = output.trim();

View File

@@ -1,5 +1,107 @@
// AUTOGENERATED_DO_NOT_EDIT // AUTOGENERATED_DO_NOT_EDIT
export const KNOWN_CHECKSUMS: { [key: string]: string } = { export const KNOWN_CHECKSUMS: { [key: string]: string } = {
"aarch64-apple-darwin-0.6.17":
"e686c73b9314c77a36a6a4c9f94b07c001f0c9157c50c63c764941141c0d0088",
"aarch64-pc-windows-msvc-0.6.17":
"3a9468e90df970f75759da6caed7dfde2816e0f3842031235c3835fc0c4e7d09",
"aarch64-unknown-linux-gnu-0.6.17":
"6fb716c36e8ca9cf98b7cb347b0ced41679145837eb22890ee5fa9d8b68ce9f5",
"aarch64-unknown-linux-musl-0.6.17":
"98750f5c0cd9eb520799d10649efb18441b616150f07e6c1125f616a3fd137e8",
"arm-unknown-linux-musleabihf-0.6.17":
"649d8d0f37e8365af5aaa012b09dd083d6e71018e569a4d2e78316d5013f18a7",
"armv7-unknown-linux-gnueabihf-0.6.17":
"efc12955d7a6120ea0be2de5ee03dbb33d0d7d9de9dbe0dce560514f2ee129d3",
"armv7-unknown-linux-musleabihf-0.6.17":
"0661d97df8262ef83ccdc6a55ed101abfe8f1cf1ff1be879d9b0d7d1e894c970",
"i686-pc-windows-msvc-0.6.17":
"56dea6c98e1606e95445e77177d7e3cd49bb3d1a63c81b11fe49bf733adb62a2",
"i686-unknown-linux-gnu-0.6.17":
"4bc37f8303a4a5aae1c309f08166884027f325b6872c418cfbaa2cf20a2b2ac5",
"i686-unknown-linux-musl-0.6.17":
"8ec08cca0806a9205ccf5758258c617b57e413b33275bcd861fca363e0eaddf7",
"powerpc64-unknown-linux-gnu-0.6.17":
"d33b70ab206e1ed0663e755506a11db3776787012bfe9d2b2138a90942f506be",
"powerpc64le-unknown-linux-gnu-0.6.17":
"cd91a579850fc45d3b786a654a2c0343836f007929b2e35de9606082eec5361f",
"s390x-unknown-linux-gnu-0.6.17":
"3c753a9d3485bbac23403a0b41a9e70ceeb586f3b4df891ced7ed27d4c6c542b",
"x86_64-apple-darwin-0.6.17":
"61e9bdc02aacdb994da6ea2a477b11b34c23fc09203237aeee8d3817daab012d",
"x86_64-pc-windows-msvc-0.6.17":
"32882cf98f646cafca003e7a7c471b7ff4ba977b681c9fa3b12cf908ba64af82",
"x86_64-unknown-linux-gnu-0.6.17":
"720ec28f7a94aa8cd91d3d57dec1434d64b9ae13d1dd6a25f4c0cdb837ba9cf6",
"x86_64-unknown-linux-musl-0.6.17":
"28bd6b50be068cc09d8a46b76f8c4b72271d471c6673a5bdb47793622e62224d",
"aarch64-apple-darwin-0.6.16":
"2b1ea0d5cf27375738f5f0f229587bc3590c0f501cb00bc48133a3d122d28364",
"aarch64-pc-windows-msvc-0.6.16":
"5abca187b8aecbdffef7547cb39a527168e4cb93d8d2e4ce14271f5831a4d902",
"aarch64-unknown-linux-gnu-0.6.16":
"a82f96ab5f285825f9acee6ac1563683c4940d80df2f08549cad43d37c7ba4a7",
"aarch64-unknown-linux-musl-0.6.16":
"ae3f793c62fe6ced80483d6c78cb49f06a01088bc5d86f1446a9b5988b2acecc",
"arm-unknown-linux-musleabihf-0.6.16":
"91f7f5a4eb97b7983a8e5421d5bfea8802064422ce2f535055f373726eb0aa9a",
"armv7-unknown-linux-gnueabihf-0.6.16":
"a4ffe043952bf4e757a5ca0f546bb83b055b6ee0646dd5c4f5e5f13dbc5ee8f8",
"armv7-unknown-linux-musleabihf-0.6.16":
"0237c8d9914e0d9fd2f022d6d5f91ce392d13e0ccbb7fa7ebe601296a67c3d6c",
"i686-pc-windows-msvc-0.6.16":
"f5c6400f07db2014b2b0c66770e1125fa70efe4dd99cc8351838bed0045c34f8",
"i686-unknown-linux-gnu-0.6.16":
"f46f89efcc599a6695e8378a1201e62cd4afb9a4438d65a89098ab11201f84ab",
"i686-unknown-linux-musl-0.6.16":
"afe69380a9d3592a87893d6bdc11ff33e4180b98f1e1fd4e626c0307d7598914",
"powerpc64-unknown-linux-gnu-0.6.16":
"bf455747580dbbf76cbcf616f67f825c40bd1bdec20c9ff993e03485f9eaad44",
"powerpc64le-unknown-linux-gnu-0.6.16":
"508ec561b1740a551d2b33e96671e0e8435a1bcc0e97080f3d7ba88a096bd360",
"s390x-unknown-linux-gnu-0.6.16":
"e25c5527826524f51f114388bff47871bf1ca67badbfd72d45427bdba4b46794",
"x86_64-apple-darwin-0.6.16":
"ce512b5e40a8ad2916a46df2bdba729d5541e4b3649a09aaddff6e525be012e4",
"x86_64-pc-windows-msvc-0.6.16":
"f1b4c24ec602b6c0b06b6bc64aa447bbe4cf313e93fbec326741961e80ffa8b7",
"x86_64-unknown-linux-gnu-0.6.16":
"e9ef28b675df68978a60f87192fb8c730b8bfca9bef42b121686b218ea0f6542",
"x86_64-unknown-linux-musl-0.6.16":
"25024557931d04cc34f80b818c7547c9c62b762ec6df807e30cb52f383fa2615",
"aarch64-apple-darwin-0.6.15":
"1c5b25f75c6438b6910dbc4c6903debe53f31ee14aee55d02243dfe7bf7c9f72",
"aarch64-pc-windows-msvc-0.6.15":
"317fe0b29e647aad1e9f02ffe764dcbbc6e2ef189f018c81b673884173ab98ba",
"aarch64-unknown-linux-gnu-0.6.15":
"3bf650aec162157b7e01461f41c2a9797366b6043452c6e7035c6c926d0a585b",
"aarch64-unknown-linux-musl-0.6.15":
"183cebae8c9d91bbd48219f9006a5c0c41c90a075d6724aec53a7ea0503c665a",
"arm-unknown-linux-musleabihf-0.6.15":
"d83c76e130ffb25fb6a4ba8ea5870207d810190733a14ae87084c63a417912f6",
"armv7-unknown-linux-gnueabihf-0.6.15":
"d661ec44e5fc7553cd8dd5ad5f48848c5a4d5279ba0df0036c0e2422ec9f312b",
"armv7-unknown-linux-musleabihf-0.6.15":
"6fc86a829965362f99602c47627b269c9b676731586a60ca5bb9d6069677938d",
"i686-pc-windows-msvc-0.6.15":
"7f15e3377e94fac882b33465cb8cbb24705f5c8d63d9d65c6f1b0816c1d30a0b",
"i686-unknown-linux-gnu-0.6.15":
"bfedd03be9f579a9bc10e6c25176017e514cca0500cfb9bba43794387a577661",
"i686-unknown-linux-musl-0.6.15":
"82bf8666c0a57514af4e5403f162314b710e1682e1065ab71a845ebb5d8db0b7",
"powerpc64-unknown-linux-gnu-0.6.15":
"6e9795344d61ee9ac497d6e03a447d808f2aab13925f30e44c00638abec57deb",
"powerpc64le-unknown-linux-gnu-0.6.15":
"e38f13284ed8b645b87ef07c8b549d1f1a5b746aa0411c2115dcd5cda0da13fc",
"s390x-unknown-linux-gnu-0.6.15":
"416f61249b330ea9735cda0c866c9460f87111bc9d4e040c98916fda6a45be09",
"x86_64-apple-darwin-0.6.15":
"97adf61511c0f6ea42c090443c38d8d71116b78ae626363f9f149924c91ae886",
"x86_64-pc-windows-msvc-0.6.15":
"10c75d566db1447f3bdcbcb31d6598e4b5f4ea638be5d8b73a7350929389512b",
"x86_64-unknown-linux-gnu-0.6.15":
"85d98ef282cdbfcb4020922f0c12421ecca4130f0a4570d3b827a15ffd544acc",
"x86_64-unknown-linux-musl-0.6.15":
"78289c93836cb32b8b24e3216b5b316e7fdf483365de2fc571844d308387e8a4",
"aarch64-apple-darwin-0.6.14": "aarch64-apple-darwin-0.6.14":
"4ea4731010fbd1bc8e790e07f199f55a5c7c2c732e9b77f85e302b0bee61b756", "4ea4731010fbd1bc8e790e07f199f55a5c7c2c732e9b77f85e302b0bee61b756",
"aarch64-pc-windows-msvc-0.6.14": "aarch64-pc-windows-msvc-0.6.14":

View File

@@ -14,21 +14,21 @@ import {
type Platform, type Platform,
} from "./utils/platforms"; } from "./utils/platforms";
import { import {
activateEnvironment as activateEnvironmentInput,
cacheLocalPath, cacheLocalPath,
checkSum, checkSum,
ignoreEmptyWorkdir, ignoreEmptyWorkdir,
enableCache, enableCache,
githubToken, githubToken,
pyProjectFile,
pythonVersion, pythonVersion,
toolBinDir, toolBinDir,
toolDir, toolDir,
uvFile,
version as versionInput, version as versionInput,
workingDirectory,
} from "./utils/inputs"; } from "./utils/inputs";
import * as exec from "@actions/exec"; import * as exec from "@actions/exec";
import fs from "node:fs"; import fs from "node:fs";
import { getUvVersionFromConfigFile } from "./utils/pyproject"; import { getUvVersionFromConfigFile } from "./utils/config-file";
async function run(): Promise<void> { async function run(): Promise<void> {
detectEmptyWorkdir(); detectEmptyWorkdir();
@@ -47,7 +47,8 @@ async function run(): Promise<void> {
addToolBinToPath(); addToolBinToPath();
addUvToPathAndOutput(setupResult.uvDir); addUvToPathAndOutput(setupResult.uvDir);
setToolDir(); setToolDir();
await setupPython(); setupPython();
await activateEnvironment();
addMatchers(); addMatchers();
setCacheDir(cacheLocalPath); setCacheDir(cacheLocalPath);
@@ -111,22 +112,21 @@ async function determineVersion(): Promise<string> {
if (versionInput !== "") { if (versionInput !== "") {
return await resolveVersion(versionInput, githubToken); return await resolveVersion(versionInput, githubToken);
} }
const configFile = uvFile !== "" ? uvFile : pyProjectFile; const versionFromUvToml = getUvVersionFromConfigFile(
if (configFile !== "") { `${workingDirectory}${path.sep}uv.toml`,
const versionFromConfigFile = getUvVersionFromConfigFile(configFile); );
if (versionFromConfigFile === undefined) { const versionFromPyproject = getUvVersionFromConfigFile(
core.warning( `${workingDirectory}${path.sep}pyproject.toml`,
`Could not find required-version under [tool.uv] in ${configFile}. Falling back to latest`, );
if (versionFromUvToml === undefined && versionFromPyproject === undefined) {
core.info(
"Could not determine uv version from uv.toml or pyproject.toml. Falling back to latest.",
); );
} }
return await resolveVersion(versionFromConfigFile || "latest", githubToken); return await resolveVersion(
} versionFromUvToml || versionFromPyproject || "latest",
if (!fs.existsSync("uv.toml") && !fs.existsSync("pyproject.toml")) { githubToken,
return await resolveVersion("latest", githubToken); );
}
const versionFile = fs.existsSync("uv.toml") ? "uv.toml" : "pyproject.toml";
const versionFromConfigFile = getUvVersionFromConfigFile(versionFile);
return await resolveVersion(versionFromConfigFile || "latest", githubToken);
} }
function addUvToPathAndOutput(cachedPath: string): void { function addUvToPathAndOutput(cachedPath: string): void {
@@ -163,24 +163,29 @@ function setToolDir(): void {
} }
} }
async function setupPython(): Promise<void> { function setupPython(): void {
if (pythonVersion !== "") { if (pythonVersion !== "") {
core.exportVariable("UV_PYTHON", pythonVersion); core.exportVariable("UV_PYTHON", pythonVersion);
core.info(`Set UV_PYTHON to ${pythonVersion}`); core.info(`Set UV_PYTHON to ${pythonVersion}`);
const options: exec.ExecOptions = { }
silent: !core.isDebug(), }
};
const execArgs = ["venv", "--python", pythonVersion]; async function activateEnvironment(): Promise<void> {
if (activateEnvironmentInput) {
const execArgs = ["venv", ".venv", "--directory", workingDirectory];
core.info("Activating python venv..."); core.info("Activating python venv...");
await exec.exec("uv", execArgs, options); await exec.exec("uv", execArgs);
let venvBinPath = ".venv/bin"; let venvBinPath = `${workingDirectory}${path.sep}.venv${path.sep}bin`;
if (process.platform === "win32") { if (process.platform === "win32") {
venvBinPath = ".venv/Scripts"; venvBinPath = `${workingDirectory}${path.sep}.venv${path.sep}Scripts`;
} }
core.addPath(path.resolve(venvBinPath)); core.addPath(path.resolve(venvBinPath));
core.exportVariable("VIRTUAL_ENV", path.resolve(".venv")); core.exportVariable(
"VIRTUAL_ENV",
path.resolve(`${workingDirectory}${path.sep}.venv`),
);
} }
} }

View File

@@ -5,9 +5,9 @@ import * as toml from "smol-toml";
export function getUvVersionFromConfigFile( export function getUvVersionFromConfigFile(
filePath: string, filePath: string,
): string | undefined { ): string | undefined {
core.debug(`Trying to find required-version for uv in: ${filePath}`); core.info(`Trying to find required-version for uv in: ${filePath}`);
if (!fs.existsSync(filePath)) { if (!fs.existsSync(filePath)) {
core.warning(`Could not find file: ${filePath}`); core.info(`Could not find file: ${filePath}`);
return undefined; return undefined;
} }
let requiredVersion: string | undefined; let requiredVersion: string | undefined;

View File

@@ -2,9 +2,9 @@ import * as core from "@actions/core";
import path from "node:path"; import path from "node:path";
export const version = core.getInput("version"); export const version = core.getInput("version");
export const pyProjectFile = core.getInput("pyproject-file");
export const uvFile = core.getInput("uv-file");
export const pythonVersion = core.getInput("python-version"); export const pythonVersion = core.getInput("python-version");
export const activateEnvironment = core.getBooleanInput("activate-environment");
export const workingDirectory = core.getInput("working-directory");
export const checkSum = core.getInput("checksum"); export const checkSum = core.getInput("checksum");
export const enableCache = getEnableCache(); export const enableCache = getEnableCache();
export const cacheSuffix = core.getInput("cache-suffix") || ""; export const cacheSuffix = core.getInput("cache-suffix") || "";
@@ -64,6 +64,7 @@ function getCacheLocalPath(): string {
if (cacheLocalPathInput !== "") { if (cacheLocalPathInput !== "") {
return expandTilde(cacheLocalPathInput); return expandTilde(cacheLocalPathInput);
} }
if (process.env.RUNNER_ENVIRONMENT === "github-hosted") {
if (process.env.RUNNER_TEMP !== undefined) { if (process.env.RUNNER_TEMP !== undefined) {
return `${process.env.RUNNER_TEMP}${path.sep}setup-uv-cache`; return `${process.env.RUNNER_TEMP}${path.sep}setup-uv-cache`;
} }
@@ -71,6 +72,11 @@ function getCacheLocalPath(): string {
"Could not determine UV_CACHE_DIR. Please make sure RUNNER_TEMP is set or provide the cache-local-path input", "Could not determine UV_CACHE_DIR. Please make sure RUNNER_TEMP is set or provide the cache-local-path input",
); );
} }
if (process.platform === "win32") {
return `${process.env.APPDATA}${path.sep}uv${path.sep}cache`;
}
return `${process.env.HOME}${path.sep}.cache${path.sep}uv`;
}
function expandTilde(input: string): string { function expandTilde(input: string): string {
if (input.startsWith("~")) { if (input.startsWith("~")) {