Skip to content

Commit

Permalink
Replace v3 with v4 in README.md (#176)
Browse files Browse the repository at this point in the history
  • Loading branch information
eifinger authored Nov 28, 2024
1 parent 26ddfef commit 5f42d5a
Showing 1 changed file with 22 additions and 22 deletions.
44 changes: 22 additions & 22 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ Set up your GitHub Actions workflow with a specific version of [uv](https://docs

```yaml
- name: Install the latest version of uv
uses: astral-sh/setup-uv@v3
uses: astral-sh/setup-uv@v4
with:
version: "latest"
```
Expand All @@ -52,7 +52,7 @@ For an example workflow, see

```yaml
- name: Install a specific version of uv
uses: astral-sh/setup-uv@v3
uses: astral-sh/setup-uv@v4
with:
version: "0.4.4"
```
Expand All @@ -64,14 +64,14 @@ to install the latest version that satisfies the range.

```yaml
- name: Install a semver range of uv
uses: astral-sh/setup-uv@v3
uses: astral-sh/setup-uv@v4
with:
version: ">=0.4.0"
```

```yaml
- name: Pinning a minor version of uv
uses: astral-sh/setup-uv@v3
uses: astral-sh/setup-uv@v4
with:
version: "0.4.x"
```
Expand All @@ -84,7 +84,7 @@ This will override any python version specifications in `pyproject.toml` and `.p

```yaml
- name: Install the latest version of uv and set the python version to 3.12
uses: astral-sh/setup-uv@v3
uses: astral-sh/setup-uv@v4
with:
python-version: "3.12"
```
Expand All @@ -101,7 +101,7 @@ jobs:
steps:
- uses: actions/checkout@v4
- name: Install the latest version of uv and set the python version
uses: astral-sh/setup-uv@v3
uses: astral-sh/setup-uv@v4
with:
python-version: ${{ matrix.python-version }}
- name: Test with python ${{ matrix.python-version }}
Expand All @@ -116,7 +116,7 @@ are automatically verified by this action. The sha256 hashes can be found on the

```yaml
- name: Install a specific version and validate the checksum
uses: astral-sh/setup-uv@v3
uses: astral-sh/setup-uv@v4
with:
version: "0.3.1"
checksum: "e11b01402ab645392c7ad6044db63d37e4fd1e745e015306993b07695ea5f9f8"
Expand All @@ -137,7 +137,7 @@ You can optionally define a custom cache key suffix.
```yaml
- name: Enable caching and define a custom cache key suffix
id: setup-uv
uses: astral-sh/setup-uv@v3
uses: astral-sh/setup-uv@v4
with:
enable-cache: true
cache-suffix: "optional-suffix"
Expand All @@ -164,15 +164,15 @@ changes. If you use relative paths, they are relative to the repository root.

```yaml
- name: Define a cache dependency glob
uses: astral-sh/setup-uv@v3
uses: astral-sh/setup-uv@v4
with:
enable-cache: true
cache-dependency-glob: "**/requirements*.txt"
```

```yaml
- name: Define a list of cache dependency globs
uses: astral-sh/setup-uv@v3
uses: astral-sh/setup-uv@v4
with:
enable-cache: true
cache-dependency-glob: |
Expand All @@ -182,15 +182,15 @@ changes. If you use relative paths, they are relative to the repository root.

```yaml
- name: Define an absolute cache dependency glob
uses: astral-sh/setup-uv@v3
uses: astral-sh/setup-uv@v4
with:
enable-cache: true
cache-dependency-glob: "/tmp/my-folder/requirements*.txt"
```

```yaml
- name: Never invalidate the cache
uses: astral-sh/setup-uv@v3
uses: astral-sh/setup-uv@v4
with:
enable-cache: true
cache-dependency-glob: ""
Expand All @@ -205,7 +205,7 @@ It defaults to `setup-uv-cache` in the `TMP` dir, `D:\a\_temp\uv-tool-dir` on Wi

```yaml
- name: Define a custom uv cache path
uses: astral-sh/setup-uv@v3
uses: astral-sh/setup-uv@v4
with:
cache-local-path: "/path/to/cache"
```
Expand All @@ -224,7 +224,7 @@ input.

```yaml
- name: Don't prune the cache before saving it
uses: astral-sh/setup-uv@v3
uses: astral-sh/setup-uv@v4
with:
enable-cache: true
prune-cache: false
Expand All @@ -237,7 +237,7 @@ If you want to ignore this, set the `ignore-nothing-to-cache` input to `true`.

```yaml
- name: Ignore nothing to cache
uses: astral-sh/setup-uv@v3
uses: astral-sh/setup-uv@v4
with:
enable-cache: true
ignore-nothing-to-cache: true
Expand All @@ -255,7 +255,7 @@ are not sufficient, you can provide a custom GitHub token with the necessary per

```yaml
- name: Install the latest version of uv with a custom GitHub token
uses: astral-sh/setup-uv@v3
uses: astral-sh/setup-uv@v4
with:
github-token: ${{ secrets.CUSTOM_GITHUB_TOKEN }}
```
Expand All @@ -273,7 +273,7 @@ input:

```yaml
- name: Install the latest version of uv with a custom tool dir
uses: astral-sh/setup-uv@v3
uses: astral-sh/setup-uv@v4
with:
tool-dir: "/path/to/tool/dir"
```
Expand All @@ -292,7 +292,7 @@ If you want to change this behaviour (especially on self-hosted runners) you can

```yaml
- name: Install the latest version of uv with a custom tool bin dir
uses: astral-sh/setup-uv@v3
uses: astral-sh/setup-uv@v4
with:
tool-bin-dir: "/path/to/tool-bin/dir"
```
Expand All @@ -308,7 +308,7 @@ This action supports expanding the `~` character to the user's home directory fo

```yaml
- name: Expand the tilde character
uses: astral-sh/setup-uv@v3
uses: astral-sh/setup-uv@v4
with:
cache-local-path: "~/path/to/cache"
tool-dir: "~/path/to/tool/dir"
Expand Down Expand Up @@ -340,7 +340,7 @@ For example:
- name: Checkout the repository
uses: actions/checkout@main
- name: Install the latest version of uv
uses: astral-sh/setup-uv@v3
uses: astral-sh/setup-uv@v4
with:
enable-cache: true
- name: Test
Expand All @@ -352,7 +352,7 @@ To install a specific version of Python, use

```yaml
- name: Install the latest version of uv
uses: astral-sh/setup-uv@v3
uses: astral-sh/setup-uv@v4
with:
enable-cache: true
- name: Install Python 3.12
Expand All @@ -371,7 +371,7 @@ output:
uses: actions/checkout@main
- name: Install the default version of uv
id: setup-uv
uses: astral-sh/setup-uv@v3
uses: astral-sh/setup-uv@v4
- name: Print the installed version
run: echo "Installed uv version is ${{ steps.setup-uv.outputs.uv-version }}"
```
Expand Down

0 comments on commit 5f42d5a

Please sign in to comment.