5
0
mirror of https://github.com/astral-sh/setup-uv.git synced 2025-12-15 11:07:14 +00:00

Compare commits

...

116 Commits

Author SHA1 Message Date
pollenJP(@'ω'@)
38f3f10444 Resolve latest version instead of downloading latest release (#178) 2024-11-30 19:12:35 +01:00
Kevin Stillhammer
8bdd012be5 Add test for python-version (#177) 2024-11-29 09:32:51 +01:00
Kevin Stillhammer
5f42d5af6c Replace v3 with v4 in README.md (#176) 2024-11-28 20:49:05 +00:00
Kevin Stillhammer
26ddfef6e1 Add matrix example for python-version (#175) 2024-11-28 20:46:52 +00:00
Kevin Stillhammer
ee4fa33003 Add input python-version (#174) 2024-11-28 20:41:37 +00:00
Kevin Stillhammer
420915557e Reduce test matrices (#173)
Basic functionality for the different OS is tested in
`test-latest-version` Everything else is not OS dependent
2024-11-28 21:07:46 +01:00
github-actions[bot]
9839fa9fb5 chore: update known checksums for 0.5.5 (#170)
chore: update known checksums for 0.5.5

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-11-27 19:28:03 +01:00
Kevin Stillhammer
196fe5f098 Speed up updating known checksums (#166)
Before downloading the checksum file from the releases, check if we
already know that version.
2024-11-25 09:18:03 +01:00
Kevin Stillhammer
49d8a3d9a8 Clarify caching will only fail when enabled and nothing to cache (#165) 2024-11-23 16:24:42 +00:00
Kevin Stillhammer
d8db0a86d3 Change some formulations in README.md (#164) 2024-11-23 15:47:24 +00:00
Kevin Stillhammer
ed171c292b Fail when cache local path does not exist when trying to cache (#163)
Can be disabled by setting `ignore-nothing-to-cache: true`
2024-11-23 16:30:54 +01:00
Kevin Stillhammer
691a091485 Remove working dir from cacheDependencyGlob error message (#162)
Since https://github.com/astral-sh/setup-uv/pull/160 we allow searching
everywhere
2024-11-23 11:03:08 +00:00
Kevin Stillhammer
9b71657bb2 Add comment to clarify process.exit(0) (#161)
Copied from https://github.com/actions/cache/pull/1217
2024-11-23 10:58:21 +00:00
Kevin Stillhammer
caf0cab7a6 Expand TILDE (~) in path inputs (#160)
Closes: #159
2024-11-23 09:21:51 +01:00
github-actions[bot]
7c238111e6 chore: update known checksums for 0.5.4 (#158)
chore: update known checksums for 0.5.4

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-11-20 22:32:28 +00:00
dependabot[bot]
3eca4c2715 Bump @types/node from 22.9.0 to 22.9.1 (#157)
Bumps
[@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node)
from 22.9.0 to 22.9.1.
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=@types/node&package-manager=npm_and_yarn&previous-version=22.9.0&new-version=22.9.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-11-20 16:02:30 +01:00
github-actions[bot]
aee2e918ee chore: update known checksums for 0.5.3 (#156)
chore: update known checksums for 0.5.3

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-11-19 22:03:11 +00:00
dependabot[bot]
4ffb6d766c Bump @vercel/ncc from 0.38.2 to 0.38.3 (#155)
Bumps [@vercel/ncc](https://github.com/vercel/ncc) from 0.38.2 to
0.38.3.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/vercel/ncc/releases"><code>@​vercel/ncc</code>'s
releases</a>.</em></p>
<blockquote>
<h2>0.38.3</h2>
<h2><a
href="https://github.com/vercel/ncc/compare/0.38.2...0.38.3">0.38.3</a>
(2024-11-15)</h2>
<h3>Bug Fixes</h3>
<ul>
<li>add missing <code>--asset-builds</code> to cli help message (<a
href="https://redirect.github.com/vercel/ncc/issues/1228">#1228</a>) (<a
href="84f8c52872">84f8c52</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="84f8c52872"><code>84f8c52</code></a>
fix: add missing <code>--asset-builds</code> to cli help message (<a
href="https://redirect.github.com/vercel/ncc/issues/1228">#1228</a>)</li>
<li><a
href="0ff93c67f8"><code>0ff93c6</code></a>
chore(deps): Bump elliptic from 6.5.7 to 6.6.0 (<a
href="https://redirect.github.com/vercel/ncc/issues/1223">#1223</a>)</li>
<li><a
href="ae5bf16cb3"><code>ae5bf16</code></a>
chore(deps): Bump amannn/action-semantic-pull-request from 5.3.0 to
5.5.3 (<a
href="https://redirect.github.com/vercel/ncc/issues/1">#1</a>...</li>
<li><a
href="738a2bfe3d"><code>738a2bf</code></a>
chore(deps-dev): Bump axios from 0.21.4 to 1.7.7 (<a
href="https://redirect.github.com/vercel/ncc/issues/1209">#1209</a>)</li>
<li>See full diff in <a
href="https://github.com/vercel/ncc/compare/0.38.2...0.38.3">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=@vercel/ncc&package-manager=npm_and_yarn&previous-version=0.38.2&new-version=0.38.3)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-11-15 11:15:58 +01:00
github-actions[bot]
e779db7426 chore: update known checksums for 0.5.2 (#154)
chore: update known checksums for 0.5.2

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-11-15 06:53:19 +00:00
github-actions[bot]
cb1ce8a914 chore: update known checksums for 0.5.1 (#152)
chore: update known checksums for 0.5.1

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-11-09 11:01:15 +01:00
github-actions[bot]
cf7bbf8f13 chore: update known checksums for 0.5.0 (#151)
chore: update known checksums for 0.5.0

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-11-08 09:39:20 +01:00
Kevin Stillhammer
2e657c127d Avoid leftover files by using temp dir (#150)
Fixes: #149
2024-11-06 12:52:46 +01:00
dependabot[bot]
a7e15805d2 Bump @actions/cache from 3.2.4 to 3.3.0 (#143)
Bumps
[@actions/cache](https://github.com/actions/toolkit/tree/HEAD/packages/cache)
from 3.2.4 to 3.3.0.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/actions/toolkit/blob/main/packages/cache/RELEASES.md"><code>@​actions/cache</code>'s
changelog</a>.</em></p>
<blockquote>
<h3>3.3.0</h3>
<ul>
<li>Update <code>@actions/core</code> to <code>1.11.1</code></li>
<li>Remove dependency on <code>uuid</code> package <a
href="https://redirect.github.com/actions/toolkit/pull/1824">#1824</a>,
<a
href="https://redirect.github.com/actions/toolkit/pull/1842">#1842</a></li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/actions/toolkit/commits/HEAD/packages/cache">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=@actions/cache&package-manager=npm_and_yarn&previous-version=3.2.4&new-version=3.3.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-11-05 20:57:00 +00:00
dependabot[bot]
2a578ce17f Bump @types/node from 22.8.6 to 22.9.0 (#146)
Bumps
[@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node)
from 22.8.6 to 22.9.0.
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=@types/node&package-manager=npm_and_yarn&previous-version=22.8.6&new-version=22.9.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-11-05 21:48:02 +01:00
Kevin Stillhammer
6f467a02b3 add archive extension to downloaded assets (#148)
Fixes missing .zip extensions
which breaks on old PowerShell versions

Fixes: #147
2024-11-05 21:21:57 +01:00
github-actions[bot]
d2242d1901 chore: update known checksums for 0.4.30 (#145)
chore: update known checksums for 0.4.30

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-11-05 06:55:55 +00:00
dependabot[bot]
5552ab3709 Bump @types/node from 22.7.9 to 22.8.6 (#142)
Bumps
[@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node)
from 22.7.9 to 22.8.6.
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=@types/node&package-manager=npm_and_yarn&previous-version=22.7.9&new-version=22.8.6)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-11-02 14:48:47 +01:00
github-actions[bot]
3e4fe09ab3 chore: update known checksums for 0.4.29 (#140)
chore: update known checksums for 0.4.29

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-10-31 08:15:34 +00:00
github-actions[bot]
56f89d8124 chore: update known checksums for 0.4.28 (#136)
chore: update known checksums for 0.4.28

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-10-29 09:22:48 +00:00
Merlin
3b9817b1bf feat: add option to disable cache pruning (#134)
This PR adds an input to control whether or not the cache is pruned
before saving.

Closes #122

---------

Co-authored-by: Kevin Stillhammer <kevin.stillhammer@gmail.com>
Co-authored-by: Charlie Marsh <crmarsh416@gmail.com>
Co-authored-by: Charlie Marsh <charlie.r.marsh@gmail.com>
2024-10-25 14:11:32 +02:00
dependabot[bot]
cf841c25e2 Bump @types/node from 22.7.8 to 22.7.9 (#132)
Bumps
[@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node)
from 22.7.8 to 22.7.9.
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=@types/node&package-manager=npm_and_yarn&previous-version=22.7.8&new-version=22.7.9)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-10-24 09:58:30 +02:00
github-actions[bot]
864c48a352 chore: update known checksums for 0.4.26 (#133)
chore: update known checksums for 0.4.26

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-10-24 07:53:38 +00:00
dependabot[bot]
64311bdf43 Bump @types/node from 22.7.7 to 22.7.8 (#131)
Bumps
[@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node)
from 22.7.7 to 22.7.8.
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=@types/node&package-manager=npm_and_yarn&previous-version=22.7.7&new-version=22.7.8)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-10-22 12:36:29 +02:00
github-actions[bot]
59604e6118 chore: update known checksums for 0.4.25 (#130)
chore: update known checksums for 0.4.25

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-10-21 12:21:15 +00:00
dependabot[bot]
260f4a22de Bump @types/node from 22.7.6 to 22.7.7 (#129)
Bumps
[@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node)
from 22.7.6 to 22.7.7.
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=@types/node&package-manager=npm_and_yarn&previous-version=22.7.6&new-version=22.7.7)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-10-21 13:16:28 +02:00
Trevor Manz
273d3782a2 Use 0.4.x for versioning examples (#128)
I figured having the syntax examples with the latest minor semver would
be more convenient for copy pasting.
2024-10-18 12:35:52 -04:00
dependabot[bot]
ed0a39790e Bump @types/node from 22.7.5 to 22.7.6 (#123)
Bumps
[@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node)
from 22.7.5 to 22.7.6.
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=@types/node&package-manager=npm_and_yarn&previous-version=22.7.5&new-version=22.7.6)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-10-18 13:19:40 +02:00
dependabot[bot]
2d11fcb2c1 Bump @biomejs/biome from 1.9.3 to 1.9.4 (#127)
Bumps
[@biomejs/biome](https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome)
from 1.9.3 to 1.9.4.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/biomejs/biome/releases"><code>@​biomejs/biome</code>'s
releases</a>.</em></p>
<blockquote>
<h2>CLI v1.9.4</h2>
<h3>Analyzer</h3>
<h4>Bug fixes</h4>
<ul>
<li>
<p>Improved the message for unused suppression comments. Contributed by
<a href="https://github.com/dyc3"><code>@​dyc3</code></a></p>
</li>
<li>
<p>Fix <a
href="https://redirect.github.com/biomejs/biome/issues/4228">#4228</a>,
where the rule
<code>a11y/noInteractiveElementToNoninteractiveRole</code> incorrectly
reports a <code>role</code> for non-interactive elements. Contributed by
<a href="https://github.com/eryue0220"><code>@​eryue0220</code></a></p>
</li>
<li>
<p><code>noSuspiciousSemicolonInJsx</code> now catches suspicious
semicolons in React fragments. Contributed by <a
href="https://github.com/vasucp1207"><code>@​vasucp1207</code></a></p>
</li>
</ul>
<h3>CLI</h3>
<h4>Enhancements</h4>
<ul>
<li>
<p>The <code>--summary</code> reporter now reports parsing diagnostics
too. Contributed by <a
href="https://github.com/ematipico"><code>@​ematipico</code></a></p>
</li>
<li>
<p>Improved performance of GritQL queries by roughly 25-30%. Contributed
by <a href="https://github.com/arendjr"><code>@​arendjr</code></a></p>
</li>
</ul>
<h3>Configuration</h3>
<h4>Bug fixes</h4>
<ul>
<li>Fix an issue where the JSON schema marked lint rules options as
mandatory. Contributed by <a
href="https://github.com/ematipico"><code>@​ematipico</code></a></li>
</ul>
<h3>Formatter</h3>
<h4>Bug fixes</h4>
<ul>
<li>Fix <a
href="https://redirect.github.com/biomejs/biome/issues/4121">#4121</a>.
Respect line width when printing multiline strings. Contributed by <a
href="https://github.com/ah-yu"><code>@​ah-yu</code></a></li>
</ul>
<h3>Linter</h3>
<h4>New features</h4>
<ul>
<li>Add <a
href="https://biomejs.dev/linter/rules/use-guard-for-in/">useGuardForIn</a>.
Contributed by <a
href="https://github.com/fireairforce"><code>@​fireairforce</code></a></li>
<li>Add <a
href="https://biomejs.dev/linter/rules/no-document-cookie/">noDocumentCookie</a>.
Contributed by <a
href="https://github.com/tunamaguro"><code>@​tunamaguro</code></a></li>
<li>Add <a
href="https://biomejs.dev/linter/rules/no-document-import-in-page/">noDocumentImportInPage</a>.
Contributed by <a
href="https://github.com/kaioduarte"><code>@​kaioduarte</code></a></li>
<li>Add <a
href="https://biomejs.dev/linter/rules/no-duplicate-properties/">noDuplicateProperties</a>.
Contributed by <a
href="https://github.com/togami2864"><code>@​togami2864</code></a></li>
<li>Add <a
href="https://biomejs.dev/linter/rules/no-head-element/">noHeadElement</a>.
Contributed by <a
href="https://github.com/kaioduarte"><code>@​kaioduarte</code></a></li>
<li>Add <a
href="https://biomejs.dev/linter/rules/no-head-import-in-document/">noHeadImportInDocument</a>.
Contributed by <a
href="https://github.com/kaioduarte"><code>@​kaioduarte</code></a></li>
<li>Add <a
href="https://biomejs.dev/linter/rules/no-img-element/">noImgElement</a>.
Contributed by <a
href="https://github.com/kaioduarte"><code>@​kaioduarte</code></a></li>
<li>Add <a
href="https://biomejs.dev/linter/rules/no-unknown-type-selector/">noUnknownTypeSelector</a>.
Contributed by <a
href="https://github.com/Kazuhiro-Mimaki"><code>@​Kazuhiro-Mimaki</code></a></li>
<li>Add <a
href="https://biomejs.dev/linter/rules/use-at-index/">useAtIndex</a>.
Contributed by <a
href="https://github.com/GunseiKPaseri"><code>@​GunseiKPaseri</code></a></li>
<li>Add <a
href="https://biomejs.dev/linter/rules/no-useless-string-raw/">noUselessStringRaw</a>.
Contributed by <a
href="https://github.com/fireairforce"><code>@​fireairforce</code></a></li>
<li>Add <a
href="https://biomejs.dev/linter/rules/use-collapsed-if/">nursery/useCollapsedIf</a>.
Contributed by <a
href="https://github.com/siketyan"><code>@​siketyan</code></a></li>
<li>Add <a
href="https://biomejs.dev/linter/rules/use-google-font-display/">useGoogleFontDisplay</a>.
Contributed by <a
href="https://github.com/kaioduarte"><code>@​kaioduarte</code></a></li>
</ul>
<h4>Bug Fixes</h4>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/biomejs/biome/blob/main/CHANGELOG.md"><code>@​biomejs/biome</code>'s
changelog</a>.</em></p>
<blockquote>
<h2>v1.9.4 (2024-10-17)</h2>
<h3>Analyzer</h3>
<h4>Bug fixes</h4>
<ul>
<li>
<p>Improved the message for unused suppression comments. Contributed by
<a href="https://github.com/dyc3"><code>@​dyc3</code></a></p>
</li>
<li>
<p>Fix <a
href="https://redirect.github.com/biomejs/biome/issues/4228">#4228</a>,
where the rule
<code>a11y/noInteractiveElementToNoninteractiveRole</code> incorrectly
reports a <code>role</code> for non-interactive elements. Contributed by
<a href="https://github.com/eryue0220"><code>@​eryue0220</code></a></p>
</li>
<li>
<p><code>noSuspiciousSemicolonInJsx</code> now catches suspicious
semicolons in React fragments. Contributed by <a
href="https://github.com/vasucp1207"><code>@​vasucp1207</code></a></p>
</li>
</ul>
<h3>CLI</h3>
<h4>Enhancements</h4>
<ul>
<li>
<p>The <code>--summary</code> reporter now reports parsing diagnostics
too. Contributed by <a
href="https://github.com/ematipico"><code>@​ematipico</code></a></p>
</li>
<li>
<p>Improved performance of GritQL queries by roughly 25-30%. Contributed
by <a href="https://github.com/arendjr"><code>@​arendjr</code></a></p>
</li>
</ul>
<h3>Configuration</h3>
<h4>Bug fixes</h4>
<ul>
<li>Fix an issue where the JSON schema marked lint rules options as
mandatory. Contributed by <a
href="https://github.com/ematipico"><code>@​ematipico</code></a></li>
</ul>
<h3>Editors</h3>
<h3>Formatter</h3>
<h4>Bug fixes</h4>
<ul>
<li>Fix <a
href="https://redirect.github.com/biomejs/biome/issues/4121">#4121</a>.
Respect line width when printing multiline strings. Contributed by <a
href="https://github.com/ah-yu"><code>@​ah-yu</code></a></li>
</ul>
<h3>JavaScript APIs</h3>
<h3>Linter</h3>
<h4>New features</h4>
<ul>
<li>Add <a
href="https://biomejs.dev/linter/rules/use-guard-for-in/">useGuardForIn</a>.
Contributed by <a
href="https://github.com/fireairforce"><code>@​fireairforce</code></a></li>
<li>Add <a
href="https://biomejs.dev/linter/rules/no-document-cookie/">noDocumentCookie</a>.
Contributed by <a
href="https://github.com/tunamaguro"><code>@​tunamaguro</code></a></li>
<li>Add <a
href="https://biomejs.dev/linter/rules/no-document-import-in-page/">noDocumentImportInPage</a>.
Contributed by <a
href="https://github.com/kaioduarte"><code>@​kaioduarte</code></a></li>
<li>Add <a
href="https://biomejs.dev/linter/rules/no-duplicate-properties/">noDuplicateProperties</a>.
Contributed by <a
href="https://github.com/togami2864"><code>@​togami2864</code></a></li>
<li>Add <a
href="https://biomejs.dev/linter/rules/no-head-element/">noHeadElement</a>.
Contributed by <a
href="https://github.com/kaioduarte"><code>@​kaioduarte</code></a></li>
<li>Add <a
href="https://biomejs.dev/linter/rules/no-head-import-in-document/">noHeadImportInDocument</a>.
Contributed by <a
href="https://github.com/kaioduarte"><code>@​kaioduarte</code></a></li>
<li>Add <a
href="https://biomejs.dev/linter/rules/no-img-element/">noImgElement</a>.
Contributed by <a
href="https://github.com/kaioduarte"><code>@​kaioduarte</code></a></li>
<li>Add <a
href="https://biomejs.dev/linter/rules/no-unknown-type-selector/">noUnknownTypeSelector</a>.
Contributed by <a
href="https://github.com/Kazuhiro-Mimaki"><code>@​Kazuhiro-Mimaki</code></a></li>
<li>Add <a
href="https://biomejs.dev/linter/rules/use-at-index/">useAtIndex</a>.
Contributed by <a
href="https://github.com/GunseiKPaseri"><code>@​GunseiKPaseri</code></a></li>
<li>Add <a
href="https://biomejs.dev/linter/rules/no-useless-string-raw/">noUselessStringRaw</a>.
Contributed by <a
href="https://github.com/fireairforce"><code>@​fireairforce</code></a></li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="fa93a147ab"><code>fa93a14</code></a>
release: v1.9.4 (<a
href="https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome/issues/4320">#4320</a>)</li>
<li><a
href="2a05cd47fd"><code>2a05cd4</code></a>
feat(lint): add <code>useGoogleFontDisplay</code> rule (<a
href="https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome/issues/4264">#4264</a>)</li>
<li><a
href="bbb93b98b4"><code>bbb93b9</code></a>
feat(lint): useCollapsedIf JS lint rule (<a
href="https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome/issues/4179">#4179</a>)</li>
<li><a
href="561b54c936"><code>561b54c</code></a>
feat(linter): implement noUselessStringRaw (<a
href="https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome/issues/4263">#4263</a>)</li>
<li><a
href="5b7d1581c5"><code>5b7d158</code></a>
feat(linter): implement <code>noDuplicateProperties</code> (<a
href="https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome/issues/4029">#4029</a>)</li>
<li><a
href="2342984b92"><code>2342984</code></a>
feat(lint): add <code>noDocumentImportInPage</code> rule (<a
href="https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome/issues/4265">#4265</a>)</li>
<li><a
href="3cf20ebb81"><code>3cf20eb</code></a>
chore(linter): rename <code>useExplicitFunctionReturnType</code> to
`useExplicit… (<a
href="https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome/issues/4261">#4261</a>)</li>
<li><a
href="970f49884e"><code>970f498</code></a>
feat(useGuardForIn): add rule (<a
href="https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome/issues/4104">#4104</a>)</li>
<li><a
href="2e5b6564d9"><code>2e5b656</code></a>
feat(lint): add <code>noDocumentCookie</code> rule (<a
href="https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome/issues/4204">#4204</a>)</li>
<li><a
href="3364640e1f"><code>3364640</code></a>
feat(lint): add rule <code>useAtIndex</code> (<a
href="https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome/issues/4120">#4120</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/biomejs/biome/commits/cli/v1.9.4/packages/@biomejs/biome">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=@biomejs/biome&package-manager=npm_and_yarn&previous-version=1.9.3&new-version=1.9.4)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-10-18 13:11:13 +02:00
github-actions[bot]
a714a3589c chore: update known checksums for 0.4.24 (#126)
chore: update known checksums for 0.4.24

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-10-18 09:02:22 +00:00
github-actions[bot]
59ca521371 chore: update known checksums for 0.4.23 (#125)
chore: update known checksums for 0.4.23

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-10-17 15:44:41 +00:00
Kevin Stillhammer
f3bcaebff5 Update deps (#121)
Fixes: https://github.com/astral-sh/setup-uv/issues/119
2024-10-15 11:33:59 +00:00
github-actions[bot]
10d8740fc2 chore: update known checksums for 0.4.21 (#120)
chore: update known checksums for 0.4.21

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-10-15 10:00:41 +00:00
Yoshihisa Mochihara
f731690a1d Fix cache linebreak in linux runner (#118)
Related https://github.com/astral-sh/setup-uv/issues/106

We can see the differences `uv --version` in different platforms:

OSX: uv 0.4.20 (0e1b25a53 2024-10-08)\n
Linux: uv 0.4.20\n

In getVersion function we split the output by space and return the
second part.
This PR trims the version number to remove the line break.
2024-10-12 08:59:22 +02:00
github-actions[bot]
77c28f02b3 chore: update known checksums for 0.4.20 (#115)
chore: update known checksums for 0.4.20

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-10-09 09:55:25 +02:00
dependabot[bot]
00c695b84c Bump @types/node from 22.7.4 to 22.7.5 (#114)
Bumps
[@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node)
from 22.7.4 to 22.7.5.
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=@types/node&package-manager=npm_and_yarn&previous-version=22.7.4&new-version=22.7.5)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-10-08 13:21:35 +02:00
github-actions[bot]
2422c84f47 chore: update known checksums for 0.4.19 (#113)
chore: update known checksums for 0.4.19

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-10-08 05:35:45 +00:00
dependabot[bot]
680950fd0f Bump @biomejs/biome from 1.9.2 to 1.9.3 (#110)
Bumps
[@biomejs/biome](https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome)
from 1.9.2 to 1.9.3.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/biomejs/biome/releases"><code>@​biomejs/biome</code>'s
releases</a>.</em></p>
<blockquote>
<h2>CLI v1.9.3</h2>
<h3>CLI</h3>
<h4>New features</h4>
<ul>
<li>
<p>GritQL queries that match functions or methods will now match async
functions or methods as well.</p>
<p>If this is not what you want, you can capture the <code>async</code>
keyword (or its absence) in a metavariable and assert its emptiness:</p>
<pre lang="grit"><code>$async function foo() {} where $async &lt;: .
</code></pre>
<p>Contributed by <a
href="https://github.com/arendjr"><code>@​arendjr</code></a></p>
</li>
</ul>
<h4>Bug fixes</h4>
<ul>
<li>
<p>Fix <a
href="https://redirect.github.com/biomejs/biome/issues/4077">#4077</a>:
Grit queries no longer need to match the statement's trailing semicolon.
Contributed by <a
href="https://github.com/arendjr"><code>@​arendjr</code></a></p>
</li>
<li>
<p>Fix <a
href="https://redirect.github.com/biomejs/biome/issues/4102">#4102</a>.
Now the CLI command <code>lint</code> doesn't exit with an error code
when using <code>--write</code>/<code>--fix</code>. Contributed by <a
href="https://github.com/ematipico"><code>@​ematipico</code></a></p>
</li>
</ul>
<h3>Configuration</h3>
<h4>Bug fixes</h4>
<ul>
<li>Fix <a
href="https://redirect.github.com/biomejs/biome/issues/4125">#4125</a>,
where <code>noLabelWithoutControl</code> options where incorrectly
marked as mandatory. Contributed by <a
href="https://github.com/ematipico"><code>@​ematipico</code></a></li>
</ul>
<h3>Editors</h3>
<ul>
<li>Fix a case where CSS files weren't correctly linted using the
default configuration. Contributed by <a
href="https://github.com/ematipico"><code>@​ematipico</code></a></li>
</ul>
<h3>Formatter</h3>
<h4>Bug fixes</h4>
<ul>
<li>
<p>Fix <a
href="https://redirect.github.com/biomejs/biome/issues/3924">#3924</a>
where GraphQL formatter panics in block comments with empty line.
Contributed by <a
href="https://github.com/vohoanglong0107"><code>@​vohoanglong0107</code></a></p>
</li>
<li>
<p>Fix a case where raw values inside <code>url()</code> functions
weren't properly trimmed.</p>
<pre lang="diff"><code>.value {
-  background: url(
-   whitespace-around-string
-  );
+ background: url(whitespace-around-string);
}
</code></pre>
<p>Contributed by <a
href="https://github.com/ematipico"><code>@​ematipico</code></a></p>
</li>
<li>
<p>Fixed <a
href="https://redirect.github.com/biomejs/biome/issues/4076">#4076</a>,
where a media query wasn't correctly formatted:</p>
<pre lang="diff"><code>.class {
</code></pre>
</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/biomejs/biome/blob/main/CHANGELOG.md"><code>@​biomejs/biome</code>'s
changelog</a>.</em></p>
<blockquote>
<h2>v1.9.3 (2024-10-01)</h2>
<h3>CLI</h3>
<h4>New features</h4>
<ul>
<li>
<p>GritQL queries that match functions or methods will now match async
functions or methods as well.</p>
<p>If this is not what you want, you can capture the <code>async</code>
keyword (or its absence) in a metavariable and assert its emptiness:</p>
<pre lang="grit"><code>$async function foo() {} where $async &lt;: .
</code></pre>
<p>Contributed by <a
href="https://github.com/arendjr"><code>@​arendjr</code></a></p>
</li>
</ul>
<h4>Bug fixes</h4>
<ul>
<li>
<p>Fix <a
href="https://redirect.github.com/biomejs/biome/issues/4077">#4077</a>:
Grit queries no longer need to match the statement's trailing semicolon.
Contributed by <a
href="https://github.com/arendjr"><code>@​arendjr</code></a></p>
</li>
<li>
<p>Fix <a
href="https://redirect.github.com/biomejs/biome/issues/4102">#4102</a>.
Now the CLI command <code>lint</code> doesn't exit with an error code
when using <code>--write</code>/<code>--fix</code>. Contributed by <a
href="https://github.com/ematipico"><code>@​ematipico</code></a></p>
</li>
</ul>
<h3>Configuration</h3>
<h4>Bug fixes</h4>
<ul>
<li>Fix <a
href="https://redirect.github.com/biomejs/biome/issues/4125">#4125</a>,
where <code>noLabelWithoutControl</code> options where incorrectly
marked as mandatory. Contributed by <a
href="https://github.com/ematipico"><code>@​ematipico</code></a></li>
</ul>
<h3>Editors</h3>
<ul>
<li>Fix a case where CSS files weren't correctly linted using the
default configuration. Contributed by <a
href="https://github.com/ematipico"><code>@​ematipico</code></a></li>
</ul>
<h3>Formatter</h3>
<h4>Bug fixes</h4>
<ul>
<li>
<p>Fix <a
href="https://redirect.github.com/biomejs/biome/issues/3924">#3924</a>
where GraphQL formatter panics in block comments with empty line.
Contributed by <a
href="https://github.com/vohoanglong0107"><code>@​vohoanglong0107</code></a></p>
</li>
<li>
<p>Fix a case where raw values inside <code>url()</code> functions
weren't properly trimmed.</p>
<pre lang="diff"><code>.value {
-  background: url(
-   whitespace-around-string
-  );
+ background: url(whitespace-around-string);
}
</code></pre>
<p>Contributed by <a
href="https://github.com/ematipico"><code>@​ematipico</code></a></p>
</li>
<li>
<p>Fixed <a
href="https://redirect.github.com/biomejs/biome/issues/4076">#4076</a>,
where a media query wasn't correctly formatted:</p>
<pre lang="diff"><code></code></pre>
</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="3d498ed639"><code>3d498ed</code></a>
release: v1.9.3 (<a
href="https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome/issues/4140">#4140</a>)</li>
<li><a
href="7e29f06930"><code>7e29f06</code></a>
fix(lint): options for <code>noLabelWithoutControl</code> are optional
(<a
href="https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome/issues/4138">#4138</a>)</li>
<li><a
href="10a1371dca"><code>10a1371</code></a>
feat(useExhaustiveDependencies): add option to disable errors for
unecessary ...</li>
<li><a
href="295efb90b9"><code>295efb9</code></a>
feat(biome_css_analyze): implement <code>noDescendingSpecificity</code>
(<a
href="https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome/issues/4097">#4097</a>)</li>
<li><a
href="f3cfa8a92d"><code>f3cfa8a</code></a>
fix(schema): make optional the <code>options</code> JSON schema field
(<a
href="https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome/issues/4080">#4080</a>)</li>
<li><a
href="cc4c867575"><code>cc4c867</code></a>
feat(linter): implement noTemplateCurlyInString (<a
href="https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome/issues/4069">#4069</a>)</li>
<li><a
href="d03c6cd029"><code>d03c6cd</code></a>
feat(linter): implement no-nested-ternary (<a
href="https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome/issues/4067">#4067</a>)</li>
<li><a
href="2b6b3c8aa9"><code>2b6b3c8</code></a>
chore(deps): update <a
href="https://github.com/biomejs"><code>@​biomejs</code></a> packages
(<a
href="https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome/issues/4047">#4047</a>)</li>
<li><a
href="b76cb416da"><code>b76cb41</code></a>
feat(linter): implement useExplicitFunctionReturnType (<a
href="https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome/issues/3990">#3990</a>)</li>
<li><a
href="a766aebd6c"><code>a766aeb</code></a>
chore(readme): use polar shield (<a
href="https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome/issues/4000">#4000</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/biomejs/biome/commits/cli/v1.9.3/packages/@biomejs/biome">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=@biomejs/biome&package-manager=npm_and_yarn&previous-version=1.9.2&new-version=1.9.3)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-10-08 07:22:05 +02:00
github-actions[bot]
c9aa747934 chore: update known checksums for 0.4.18 (#109)
chore: update known checksums for 0.4.18

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-10-02 09:37:03 +00:00
dependabot[bot]
97dc6041e9 Bump @types/node from 22.7.3 to 22.7.4 (#108)
Bumps
[@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node)
from 22.7.3 to 22.7.4.
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=@types/node&package-manager=npm_and_yarn&previous-version=22.7.3&new-version=22.7.4)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-10-02 09:44:49 +02:00
Charlie Marsh
c11f8674f8 Migrate to Biome for linting and formatting (#107) 2024-09-30 08:55:24 +02:00
github-actions[bot]
023eb7875f chore: update known checksums for 0.4.17 (#104)
chore: update known checksums for 0.4.17

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-09-27 20:26:47 +02:00
dependabot[bot]
315da29189 Bump @types/node from 22.7.0 to 22.7.3 (#103)
Bumps
[@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node)
from 22.7.0 to 22.7.3.
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=@types/node&package-manager=npm_and_yarn&previous-version=22.7.0&new-version=22.7.3)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-27 13:05:44 +02:00
dependabot[bot]
4cda7d7332 Bump @types/node from 22.6.1 to 22.7.0 (#101)
Bumps
[@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node)
from 22.6.1 to 22.7.0.
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=@types/node&package-manager=npm_and_yarn&previous-version=22.6.1&new-version=22.7.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-25 13:02:33 +02:00
github-actions[bot]
8114e5e81b chore: update known checksums for 0.4.16 (#100)
chore: update known checksums for 0.4.16

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-09-25 07:25:31 +00:00
dependabot[bot]
7ee921e18a Bump @types/node from 22.5.5 to 22.6.1 (#98)
Bumps
[@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node)
from 22.5.5 to 22.6.1.
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=@types/node&package-manager=npm_and_yarn&previous-version=22.5.5&new-version=22.6.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-25 09:02:25 +02:00
Kevin Stillhammer
8c3a35e468 Only log checksum is valid when it really is (#97) 2024-09-21 19:10:22 +00:00
Kevin Stillhammer
abac0ce7b0 Use runner label selfhosted-ubuntu-arm64 (#96)
Replaces oracle-aarch64 to better express what the runner is used for
2024-09-21 20:19:02 +02:00
github-actions[bot]
03e245b158 chore: update known checksums for 0.4.15 (#95)
chore: update known checksums for 0.4.15

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-09-21 17:07:50 +02:00
Kevin Stillhammer
aeb46491c7 Set tool(-bin) dir and add to PATH (#87)
Fixes: #83
Fixes: #60
2024-09-21 10:14:36 +02:00
github-actions[bot]
dbb680fbd2 chore: update known checksums for 0.4.14 (#94)
chore: update known checksums for 0.4.14

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-09-20 21:53:28 +00:00
github-actions[bot]
8de9ba90a2 chore: update known checksums for 0.4.13 (#93)
chore: update known checksums for 0.4.13

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-09-19 21:30:53 +00:00
dependabot[bot]
118bd876d2 Bump peter-evans/create-pull-request from 7.0.3 to 7.0.5 (#91)
Bumps
[peter-evans/create-pull-request](https://github.com/peter-evans/create-pull-request)
from 7.0.3 to 7.0.5.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/peter-evans/create-pull-request/releases">peter-evans/create-pull-request's
releases</a>.</em></p>
<blockquote>
<h2>Create Pull Request v7.0.5</h2>
<p>⚙️ Fixes an issue with commit signing to allow it to support
symlinks</p>
<h2>What's Changed</h2>
<ul>
<li>fix: support symlinks when commit signing by <a
href="https://github.com/peter-evans"><code>@​peter-evans</code></a> in
<a
href="https://redirect.github.com/peter-evans/create-pull-request/pull/3359">peter-evans/create-pull-request#3359</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/peter-evans/create-pull-request/compare/v7.0.4...v7.0.5">https://github.com/peter-evans/create-pull-request/compare/v7.0.4...v7.0.5</a></p>
<h2>Create Pull Request v7.0.4</h2>
<p>⚙️ Fixes an issue with commit signing to allow it to support
submodules</p>
<h2>What's Changed</h2>
<ul>
<li>docs: correct suggestion for bot setup by <a
href="https://github.com/henryiii"><code>@​henryiii</code></a> in <a
href="https://redirect.github.com/peter-evans/create-pull-request/pull/3342">peter-evans/create-pull-request#3342</a></li>
<li>build(deps-dev): bump <code>@​types/jest</code> from 29.5.12 to
29.5.13 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/peter-evans/create-pull-request/pull/3343">peter-evans/create-pull-request#3343</a></li>
<li>build(deps-dev): bump eslint from 8.57.0 to 8.57.1 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/peter-evans/create-pull-request/pull/3344">peter-evans/create-pull-request#3344</a></li>
<li>fix: support submodules when commit signing by <a
href="https://github.com/peter-evans"><code>@​peter-evans</code></a> in
<a
href="https://redirect.github.com/peter-evans/create-pull-request/pull/3354">peter-evans/create-pull-request#3354</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a href="https://github.com/henryiii"><code>@​henryiii</code></a>
made their first contribution in <a
href="https://redirect.github.com/peter-evans/create-pull-request/pull/3342">peter-evans/create-pull-request#3342</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/peter-evans/create-pull-request/compare/v7.0.3...v7.0.4">https://github.com/peter-evans/create-pull-request/compare/v7.0.3...v7.0.4</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="5e914681df"><code>5e91468</code></a>
fix: support symlinks when commit signing (<a
href="https://redirect.github.com/peter-evans/create-pull-request/issues/3359">#3359</a>)</li>
<li><a
href="2f38cd26bf"><code>2f38cd2</code></a>
fix: support submodules when commit signing (<a
href="https://redirect.github.com/peter-evans/create-pull-request/issues/3354">#3354</a>)</li>
<li><a
href="7a8aeac749"><code>7a8aeac</code></a>
build(deps-dev): bump eslint from 8.57.0 to 8.57.1 (<a
href="https://redirect.github.com/peter-evans/create-pull-request/issues/3344">#3344</a>)</li>
<li><a
href="d39d596a77"><code>d39d596</code></a>
build(deps-dev): bump <code>@​types/jest</code> from 29.5.12 to 29.5.13
(<a
href="https://redirect.github.com/peter-evans/create-pull-request/issues/3343">#3343</a>)</li>
<li><a
href="f6f978fd3d"><code>f6f978f</code></a>
docs: correct suggestion for bot setup (<a
href="https://redirect.github.com/peter-evans/create-pull-request/issues/3342">#3342</a>)</li>
<li>See full diff in <a
href="6cd32fd936...5e914681df">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=peter-evans/create-pull-request&package-manager=github_actions&previous-version=7.0.3&new-version=7.0.5)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-19 18:40:01 +02:00
Bartosz Sławecki
adcf5c892e Fix a typo SHA265 → SHA256 (#90)
:)
2024-09-19 09:10:29 +00:00
github-actions[bot]
0c326cbd51 chore: update known checksums for 0.4.12 (#86)
chore: update known checksums for 0.4.12

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-09-18 18:53:44 +02:00
Kevin Stillhammer
8205eab75b Update version in README from v2 to v3 (#85) 2024-09-18 09:34:56 +00:00
Kevin Stillhammer
ce0062aac7 Add support for semver version ranges (#82)
Closes: #38
2024-09-18 09:29:09 +00:00
github-actions[bot]
8e09161b4b chore: update known checksums for 0.4.11 (#84)
chore: update known checksums for 0.4.11

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-09-18 07:23:29 +00:00
dependabot[bot]
bf2778f5d6 Bump eslint from 8.57.0 to 8.57.1 (#81) 2024-09-17 23:20:41 -04:00
Charlie Marsh
223591d242 Tweak the action branding (#49) 2024-09-17 23:20:15 -04:00
Kevin Stillhammer
79fb68ebfe Fix prettier destroying markdown NOTE (#80) 2024-09-17 08:27:37 +02:00
Kevin Stillhammer
9f1f1fece2 Run prettier (#78) 2024-09-16 19:33:16 +00:00
dependabot[bot]
6343f7c79b Bump eslint-plugin-github from 5.0.1 to 5.0.2 (#69)
Bumps
[eslint-plugin-github](https://github.com/github/eslint-plugin-github)
from 5.0.1 to 5.0.2.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/github/eslint-plugin-github/releases">eslint-plugin-github's
releases</a>.</em></p>
<blockquote>
<h2>v5.0.2</h2>
<h2>What's Changed</h2>
<ul>
<li>chore(deps): bump the all-dependencies group across 1 directory with
3 updates by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/github/eslint-plugin-github/pull/533">github/eslint-plugin-github#533</a></li>
<li>chore(deps): bump braces from 3.0.2 to 3.0.3 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/github/eslint-plugin-github/pull/534">github/eslint-plugin-github#534</a></li>
<li>chore(deps): bump the all-dependencies group with 3 updates by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/github/eslint-plugin-github/pull/535">github/eslint-plugin-github#535</a></li>
<li>chore(deps): bump the all-dependencies group with 3 updates by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/github/eslint-plugin-github/pull/536">github/eslint-plugin-github#536</a></li>
<li>chore(deps): bump the all-dependencies group with 4 updates by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/github/eslint-plugin-github/pull/537">github/eslint-plugin-github#537</a></li>
<li>chore(deps): bump the all-dependencies group with 3 updates by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/github/eslint-plugin-github/pull/538">github/eslint-plugin-github#538</a></li>
<li>chore(deps): bump the all-dependencies group with 3 updates by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/github/eslint-plugin-github/pull/540">github/eslint-plugin-github#540</a></li>
<li>chore(deps): bump the all-dependencies group with 4 updates by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/github/eslint-plugin-github/pull/541">github/eslint-plugin-github#541</a></li>
<li>chore(deps): bump the all-dependencies group across 1 directory with
3 updates by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/github/eslint-plugin-github/pull/543">github/eslint-plugin-github#543</a></li>
<li>chore(deps): bump the all-dependencies group with 3 updates by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/github/eslint-plugin-github/pull/544">github/eslint-plugin-github#544</a></li>
<li>chore(deps): bump the all-dependencies group with 3 updates by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/github/eslint-plugin-github/pull/545">github/eslint-plugin-github#545</a></li>
<li>chore(deps): bump the all-dependencies group across 1 directory with
4 updates by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/github/eslint-plugin-github/pull/551">github/eslint-plugin-github#551</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/github/eslint-plugin-github/compare/v5.0.1...v5.0.2">https://github.com/github/eslint-plugin-github/compare/v5.0.1...v5.0.2</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="d6f656d78f"><code>d6f656d</code></a>
Merge pull request <a
href="https://redirect.github.com/github/eslint-plugin-github/issues/551">#551</a>
from github/dependabot/npm_and_yarn/all-dependencies-...</li>
<li><a
href="df2c60a624"><code>df2c60a</code></a>
chore(deps): bump the all-dependencies group across 1 directory with 4
updates</li>
<li><a
href="0f0979cb38"><code>0f0979c</code></a>
chore(deps): bump the all-dependencies group with 3 updates (<a
href="https://redirect.github.com/github/eslint-plugin-github/issues/545">#545</a>)</li>
<li><a
href="0e294e5c4d"><code>0e294e5</code></a>
Merge pull request <a
href="https://redirect.github.com/github/eslint-plugin-github/issues/544">#544</a>
from github/dependabot/npm_and_yarn/all-dependencies-...</li>
<li><a
href="17c6e39aa4"><code>17c6e39</code></a>
chore(deps): bump the all-dependencies group with 3 updates</li>
<li><a
href="86d5cb1324"><code>86d5cb1</code></a>
Merge pull request <a
href="https://redirect.github.com/github/eslint-plugin-github/issues/543">#543</a>
from github/dependabot/npm_and_yarn/all-dependencies-...</li>
<li><a
href="522309f8d0"><code>522309f</code></a>
chore(deps): bump the all-dependencies group across 1 directory with 3
updates</li>
<li><a
href="c3857ba01e"><code>c3857ba</code></a>
Merge pull request <a
href="https://redirect.github.com/github/eslint-plugin-github/issues/541">#541</a>
from github/dependabot/npm_and_yarn/all-dependencies-...</li>
<li><a
href="8010f55226"><code>8010f55</code></a>
chore(deps): bump the all-dependencies group with 4 updates</li>
<li><a
href="777227525b"><code>7772275</code></a>
Merge pull request <a
href="https://redirect.github.com/github/eslint-plugin-github/issues/540">#540</a>
from github/dependabot/npm_and_yarn/all-dependencies-...</li>
<li>Additional commits viewable in <a
href="https://github.com/github/eslint-plugin-github/compare/v5.0.1...v5.0.2">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=eslint-plugin-github&package-manager=npm_and_yarn&previous-version=5.0.1&new-version=5.0.2)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-16 21:12:54 +02:00
dependabot[bot]
bfea2a2a76 Bump typescript from 5.5.4 to 5.6.2 (#64)
Bumps [typescript](https://github.com/microsoft/TypeScript) from 5.5.4
to 5.6.2.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/microsoft/TypeScript/releases">typescript's
releases</a>.</em></p>
<blockquote>
<h2>TypeScript 5.6</h2>
<p>For release notes, check out the <a
href="https://devblogs.microsoft.com/typescript/announcing-typescript-5-6/">release
announcement</a>.</p>
<p>For the complete list of fixed issues, check out the</p>
<ul>
<li><a
href="https://github.com/Microsoft/TypeScript/issues?utf8=%E2%9C%93&amp;q=milestone%3A%22TypeScript+5.6.0%22+is%3Aclosed+">fixed
issues query for Typescript 5.6.0 (Beta)</a>.</li>
<li><a
href="https://github.com/Microsoft/TypeScript/issues?utf8=%E2%9C%93&amp;q=milestone%3A%22TypeScript+5.6.1%22+is%3Aclosed+">fixed
issues query for Typescript 5.6.1 (RC)</a>.</li>
<li><a
href="https://github.com/Microsoft/TypeScript/issues?utf8=%E2%9C%93&amp;q=milestone%3A%22TypeScript+5.6.2%22+is%3Aclosed+">fixed
issues query for Typescript 5.6.2 (Stable)</a>.</li>
</ul>
<p>Downloads are available on:</p>
<ul>
<li><a href="https://www.npmjs.com/package/typescript">npm</a></li>
<li><a
href="https://www.nuget.org/packages/Microsoft.TypeScript.MSBuild">NuGet
package</a></li>
</ul>
<h2>TypeScript 5.6 RC</h2>
<p>For release notes, check out the <a
href="https://devblogs.microsoft.com/typescript/announcing-typescript-5-6-rc/">release
announcement</a>.</p>
<p>For the complete list of fixed issues, check out the</p>
<ul>
<li><a
href="https://github.com/Microsoft/TypeScript/issues?utf8=%E2%9C%93&amp;milestone%3A%22TypeScript+5.6.1%22+is%3Aclosed+">fixed
issues query for TypeScript v5.6.1 (RC)</a>.</li>
<li><a
href="https://github.com/Microsoft/TypeScript/issues?utf8=%E2%9C%93&amp;milestone%3A%22TypeScript+5.6.0%22+is%3Aclosed+">fixed
issues query for TypeScript v5.6.0 (Beta)</a>.</li>
</ul>
<p>Downloads are available on:</p>
<ul>
<li><a href="https://www.npmjs.com/package/typescript">npm</a></li>
</ul>
<h2>TypeScript 5.6 Beta</h2>
<p>For release notes, check out the <a
href="https://devblogs.microsoft.com/typescript/announcing-typescript-5-6-beta/">release
announcement</a>.</p>
<p>For the complete list of fixed issues, check out the</p>
<ul>
<li><a
href="https://github.com/Microsoft/TypeScript/issues?utf8=%E2%9C%93&amp;q=milestone%3A%22TypeScript+5.6.0%22+is%3Aclosed+">fixed
issues query for Typescript 5.6.0 (Beta)</a>.</li>
</ul>
<p>Downloads are available on:</p>
<ul>
<li><a href="https://www.npmjs.com/package/typescript">npm</a></li>
<li><a
href="https://www.nuget.org/packages/Microsoft.TypeScript.MSBuild">NuGet
package</a></li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="a7e3374f13"><code>a7e3374</code></a>
Bump version to 5.6.2 and LKG</li>
<li><a
href="20633579fc"><code>2063357</code></a>
🤖 Pick PR <a
href="https://redirect.github.com/microsoft/TypeScript/issues/59708">#59708</a>
(LEGO: Pull request from lego/hb_537...) into release-5.6 (#...</li>
<li><a
href="4fe7e41ea1"><code>4fe7e41</code></a>
🤖 Pick PR <a
href="https://redirect.github.com/microsoft/TypeScript/issues/59670">#59670</a>
(fix(59649): ts Move to a new file d...) into release-5.6 (#...</li>
<li><a
href="1a03e5340a"><code>1a03e53</code></a>
🤖 Pick PR <a
href="https://redirect.github.com/microsoft/TypeScript/issues/59761">#59761</a>
(<code>this</code> can be nullish) into release-5.6 (<a
href="https://redirect.github.com/microsoft/TypeScript/issues/59762">#59762</a>)</li>
<li><a
href="6212132b83"><code>6212132</code></a>
Update LKG</li>
<li><a
href="bbb5faf7e7"><code>bbb5faf</code></a>
🤖 Pick PR <a
href="https://redirect.github.com/microsoft/TypeScript/issues/59542">#59542</a>
(Fixing delay caused in vscode due t...) into release-5.6 (#...</li>
<li><a
href="e6914a5587"><code>e6914a5</code></a>
Bump version to 5.6.1-rc and LKG</li>
<li><a
href="34121c42b6"><code>34121c4</code></a>
Update LKG</li>
<li><a
href="2a30c2a8f0"><code>2a30c2a</code></a>
Merge remote-tracking branch 'origin/main' into release-5.6</li>
<li><a
href="936a79bbb5"><code>936a79b</code></a>
Expose TypeChecker. getAwaitedType to public (<a
href="https://redirect.github.com/microsoft/TypeScript/issues/59268">#59268</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/microsoft/TypeScript/compare/v5.5.4...v5.6.2">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=typescript&package-manager=npm_and_yarn&previous-version=5.5.4&new-version=5.6.2)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-16 21:12:39 +02:00
Kevin Stillhammer
8d65000ec9 Set the cache-dependency-glob default to **/uv.lock (#77)
We should aim for a solution with sane defaults that work as most users
would expect it.

The current default leads to a cache that is never invalidated and thus
never updated.

This also mirrors the default behaviors for setup-python which use
`**/requirements.txt`, `**/Pipfile.lock` or `**/poetry.lock`

Also make it clear that the uv cache on the filesystem can be uploaded to the GitHub Actions cache, but they are distinct things.

Also make it clear that the local cache path can be changed without using `enable-cache: true`
2024-09-16 21:08:44 +02:00
Kevin Stillhammer
4456fa154a Add .idea files to gitignore (#76) 2024-09-16 13:05:47 +00:00
dependabot[bot]
8af341e206 Bump @types/node from 22.5.4 to 22.5.5 (#74)
Bumps
[@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node)
from 22.5.4 to 22.5.5.
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=@types/node&package-manager=npm_and_yarn&previous-version=22.5.4&new-version=22.5.5)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-16 14:57:20 +02:00
dependabot[bot]
6beca84284 Bump peter-evans/create-pull-request from 7.0.2 to 7.0.3 (#75)
Bumps
[peter-evans/create-pull-request](https://github.com/peter-evans/create-pull-request)
from 7.0.2 to 7.0.3.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/peter-evans/create-pull-request/releases">peter-evans/create-pull-request's
releases</a>.</em></p>
<blockquote>
<h2>Create Pull Request v7.0.3</h2>
<p>⚙️ Fixes an issue with commit signing where commit SHAs have variable
lengths when abbreviated.</p>
<h2>What's Changed</h2>
<ul>
<li>fix: disable abbreviated commit shas in diff by <a
href="https://github.com/peter-evans"><code>@​peter-evans</code></a> in
<a
href="https://redirect.github.com/peter-evans/create-pull-request/pull/3337">peter-evans/create-pull-request#3337</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/peter-evans/create-pull-request/compare/v7.0.2...v7.0.3">https://github.com/peter-evans/create-pull-request/compare/v7.0.2...v7.0.3</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="6cd32fd936"><code>6cd32fd</code></a>
fix: disable abbreviated commit shas in diff (<a
href="https://redirect.github.com/peter-evans/create-pull-request/issues/3337">#3337</a>)</li>
<li>See full diff in <a
href="d121e62763...6cd32fd936">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=peter-evans/create-pull-request&package-manager=github_actions&previous-version=7.0.2&new-version=7.0.3)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-16 14:53:59 +02:00
github-actions[bot]
6dfebec6dd chore: update known checksums for 0.4.10 (#72)
chore: update known checksums for 0.4.10

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-09-13 19:15:03 +00:00
dependabot[bot]
756f81db94 Bump peter-evans/create-pull-request from 7.0.1 to 7.0.2 (#71)
Bumps
[peter-evans/create-pull-request](https://github.com/peter-evans/create-pull-request)
from 7.0.1 to 7.0.2.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/peter-evans/create-pull-request/releases">peter-evans/create-pull-request's
releases</a>.</em></p>
<blockquote>
<h2>Create Pull Request v7.0.2</h2>
<p>⚙️ Fixes an issue with commit signing when a change was detected as
being a rename or copy.</p>
<h2>What's Changed</h2>
<ul>
<li>build(deps-dev): bump <code>@​types/node</code> from 18.19.48 to
18.19.50 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/peter-evans/create-pull-request/pull/3320">peter-evans/create-pull-request#3320</a></li>
<li>build(deps-dev): bump typescript from 5.5.4 to 5.6.2 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/peter-evans/create-pull-request/pull/3319">peter-evans/create-pull-request#3319</a></li>
<li>fix: disable diff detection for renames and copies by <a
href="https://github.com/peter-evans"><code>@​peter-evans</code></a> in
<a
href="https://redirect.github.com/peter-evans/create-pull-request/pull/3330">peter-evans/create-pull-request#3330</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/peter-evans/create-pull-request/compare/v7.0.1...v7.0.2">https://github.com/peter-evans/create-pull-request/compare/v7.0.1...v7.0.2</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="d121e62763"><code>d121e62</code></a>
fix: disable diff detection for renames and copies (<a
href="https://redirect.github.com/peter-evans/create-pull-request/issues/3330">#3330</a>)</li>
<li><a
href="f4d66f4d5a"><code>f4d66f4</code></a>
build(deps-dev): bump typescript from 5.5.4 to 5.6.2 (<a
href="https://redirect.github.com/peter-evans/create-pull-request/issues/3319">#3319</a>)</li>
<li><a
href="488c869d17"><code>488c869</code></a>
build(deps-dev): bump <code>@​types/node</code> from 18.19.48 to
18.19.50 (<a
href="https://redirect.github.com/peter-evans/create-pull-request/issues/3320">#3320</a>)</li>
<li><a
href="5354f85616"><code>5354f85</code></a>
docs: update readme</li>
<li>See full diff in <a
href="8867c4aba1...d121e62763">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=peter-evans/create-pull-request&package-manager=github_actions&previous-version=7.0.1&new-version=7.0.2)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-13 16:17:03 +02:00
hori-ryota
8e854494e0 fix example for multiple cache-dependency-glob without quote (#67) 2024-09-12 14:58:45 +02:00
github-actions[bot]
d70817ce85 chore: update known checksums for 0.4.9 (#65)
chore: update known checksums for 0.4.9

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-09-11 10:08:52 +00:00
Lukas Burgholzer
49df72dfcf 🚸 use GitHub token by default (#61)
This PR adjusts the action so that it is no longer necessary to
explicitly specify the GitHub token to circumvent the API rate limit.
To this end, it simply passes the repository's GitHub token (available
via `${{ github.token }}`) as a default for the `github_token` action
input.

This is similar to how this is handled in, e.g.,
https://github.com/peter-evans/create-pull-request; specifically
[here](5354f85616/action.yml (L4-L6)).
2024-09-11 08:18:23 +00:00
github-actions[bot]
89ebbb66d2 chore: update known checksums for 0.4.8 (#62)
chore: update known checksums for 0.4.8

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-09-10 09:54:20 +00:00
Kevin Stillhammer
b463f5b8ca rename utils/utils.ts to constants.ts (#59) 2024-09-07 12:13:50 +00:00
Kevin Stillhammer
417c97acee Use D:\a\_tmp\setup-uv-cache as default cacheLocalPath on Windows (#57)
Fixes: #52
2024-09-07 14:11:25 +02:00
github-actions[bot]
4beb0eca42 chore: update known checksums for 0.4.7 (#58)
chore: update known checksums for 0.4.7

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-09-07 09:47:36 +00:00
dependabot[bot]
428055c3da Bump peter-evans/create-pull-request from 7.0.0 to 7.0.1 (#56)
Bumps
[peter-evans/create-pull-request](https://github.com/peter-evans/create-pull-request)
from 7.0.0 to 7.0.1.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/peter-evans/create-pull-request/releases">peter-evans/create-pull-request's
releases</a>.</em></p>
<blockquote>
<h2>Create Pull Request v7.0.1</h2>
<p>⚙️ Fixes <a
href="https://redirect.github.com/peter-evans/create-pull-request/issues/3311">an
issue</a> affecting one particular use case where the action fails on
<code>diff --stat</code> with <code>fatal: ambiguous
argument</code>.</p>
<h2>What's Changed</h2>
<ul>
<li>build(deps): bump peter-evans/create-pull-request from 6 to 7 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/peter-evans/create-pull-request/pull/3283">peter-evans/create-pull-request#3283</a></li>
<li>build(deps-dev): bump <code>@​types/node</code> from 18.19.46 to
18.19.48 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/peter-evans/create-pull-request/pull/3288">peter-evans/create-pull-request#3288</a></li>
<li>build(deps-dev): bump <code>@​typescript-eslint/parser</code> from
7.17.0 to 7.18.0 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/peter-evans/create-pull-request/pull/3289">peter-evans/create-pull-request#3289</a></li>
<li>build(deps-dev): bump eslint-plugin-import from 2.29.1 to 2.30.0 by
<a href="https://github.com/dependabot"><code>@​dependabot</code></a> in
<a
href="https://redirect.github.com/peter-evans/create-pull-request/pull/3290">peter-evans/create-pull-request#3290</a></li>
<li>build(deps-dev): bump <code>@​typescript-eslint/eslint-plugin</code>
from 7.17.0 to 7.18.0 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a
href="https://redirect.github.com/peter-evans/create-pull-request/pull/3291">peter-evans/create-pull-request#3291</a></li>
<li>fix: handle ambiguous argument failure on diff stat by <a
href="https://github.com/peter-evans"><code>@​peter-evans</code></a> in
<a
href="https://redirect.github.com/peter-evans/create-pull-request/pull/3312">peter-evans/create-pull-request#3312</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/peter-evans/create-pull-request/compare/v7.0.0...v7.0.1">https://github.com/peter-evans/create-pull-request/compare/v7.0.0...v7.0.1</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="8867c4aba1"><code>8867c4a</code></a>
fix: handle ambiguous argument failure on diff stat (<a
href="https://redirect.github.com/peter-evans/create-pull-request/issues/3312">#3312</a>)</li>
<li><a
href="6073f5434b"><code>6073f54</code></a>
build(deps-dev): bump <code>@​typescript-eslint/eslint-plugin</code> (<a
href="https://redirect.github.com/peter-evans/create-pull-request/issues/3291">#3291</a>)</li>
<li><a
href="6d01b5601c"><code>6d01b56</code></a>
build(deps-dev): bump eslint-plugin-import from 2.29.1 to 2.30.0 (<a
href="https://redirect.github.com/peter-evans/create-pull-request/issues/3290">#3290</a>)</li>
<li><a
href="25cf8451c3"><code>25cf845</code></a>
build(deps-dev): bump <code>@​typescript-eslint/parser</code> from
7.17.0 to 7.18.0 (<a
href="https://redirect.github.com/peter-evans/create-pull-request/issues/3289">#3289</a>)</li>
<li><a
href="d87b980a0e"><code>d87b980</code></a>
build(deps-dev): bump <code>@​types/node</code> from 18.19.46 to
18.19.48 (<a
href="https://redirect.github.com/peter-evans/create-pull-request/issues/3288">#3288</a>)</li>
<li><a
href="119d131ea9"><code>119d131</code></a>
build(deps): bump peter-evans/create-pull-request from 6 to 7 (<a
href="https://redirect.github.com/peter-evans/create-pull-request/issues/3283">#3283</a>)</li>
<li><a
href="73e6230af4"><code>73e6230</code></a>
docs: update readme</li>
<li><a
href="c0348e860f"><code>c0348e8</code></a>
ci: add v7 to workflow</li>
<li>See full diff in <a
href="4320041ed3...8867c4aba1">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=peter-evans/create-pull-request&package-manager=github_actions&previous-version=7.0.0&new-version=7.0.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-06 14:47:10 +02:00
Hynek Schlawack
20d812c7a3 Update README to v2 (#50) 2024-09-06 14:46:33 +02:00
Kevin Stillhammer
d9a2b6b6fa Support a list of cache-dependency-glob (#41)
Closes: #40

Because of build conflics (forgot to run `npm i` after pulling) I
deleted the `dist`folder to start fresh. Turns out that it still
contained the source maps from the very first commit. I removed the
argument to generate those a long time ago
2024-09-06 14:44:31 +02:00
github-actions[bot]
606b0d67da chore: update known checksums for 0.4.6 (#55)
chore: update known checksums for 0.4.6

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-09-06 13:31:10 +02:00
Kevin Stillhammer
67736b0f01 Always run check-dist check (#53)
Currently we mark it as a required check and thus prevent automatic PR
merges when only markdown files are contained in the PR
2024-09-06 13:07:34 +02:00
github-actions[bot]
fc672aa0a3 chore: update known checksums for 0.4.5 (#48)
chore: update known checksums for 0.4.5

Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-09-06 09:30:10 +02:00
Kevin Stillhammer
79643936e1 Run test build only on ubuntu-latest (#51)
It is unnecessary to test this on several OS. This is done by the actual
action tests in other jobs.
2024-09-06 09:19:26 +02:00
Kevin Stillhammer
663d8f7082 Fix typo "relaying" in README.md (#47) 2024-09-05 09:54:40 -04:00
dependabot[bot]
d8c8151c2b Bump @actions/glob from 0.4.0 to 0.5.0 (#10) 2024-09-05 09:40:37 -04:00
Charlie Marsh
040c0c3cf0 Make some minor edits to the README (#46) 2024-09-05 13:38:39 +00:00
dependabot[bot]
902c4a5691 Bump typescript from 5.4.5 to 5.5.4 (#30) 2024-09-05 09:30:29 -04:00
Kevin Stillhammer
b3cf8231d5 Do not change default version on known checksum update (#39) 2024-09-05 13:26:17 +00:00
Charlie Marsh
bfebbf80cb Change default to "latest" (#37)
## Summary

Also did some light editing of the README.
2024-09-05 09:24:32 -04:00
dependabot[bot]
a6cb892a36 Bump peter-evans/create-pull-request from 7.0.0 to 7.0.1 (#42) 2024-09-05 09:24:18 -04:00
dependabot[bot]
bd99ba67dc Bump eslint-plugin-jest from 28.8.2 to 28.8.3 (#43) 2024-09-05 09:24:12 -04:00
dependabot[bot]
1f78a33fdb Bump @types/node from 22.5.3 to 22.5.4 (#44) 2024-09-05 09:24:04 -04:00
Charlie Marsh
182c9c7e92 Change Prettier settings (#36)
## Summary

I know this is a little tedious but I'd prefer to use the same settings
as in Ruff.
2024-09-05 08:06:45 -04:00
dependabot[bot]
1785c7bde0 Bump eslint-plugin-import from 2.29.1 to 2.30.0 (#31) 2024-09-04 17:29:25 -04:00
dependabot[bot]
43f9a7cdf9 Bump @types/node from 20.14.9 to 22.5.3 (#32) 2024-09-04 17:29:17 -04:00
Charlie Marsh
0fa3b93f6e Run Prettier over Markdown and YAML files (#35)
## Summary

Partly personal preference, but mostly to align with other Astral
projects.
2024-09-04 21:14:10 +00:00
Charlie Marsh
6f825bd8e7 Add acknowledgements and Astral logo (#34) 2024-09-04 17:13:00 -04:00
Kevin Stillhammer
e4d1d0eef8 Rename repo org in examples and urls (#33) 2024-09-04 20:09:26 +02:00
github-actions[bot]
162b8acf39 chore: update checksums (#29)
Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-09-04 07:53:44 +02:00
dependabot[bot]
5db96a6748 Bump @typescript-eslint/parser from 7.15.0 to 7.18.0 (#9)
Bumps [@typescript-eslint/parser](https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/parser) from 7.15.0 to 7.18.0.
- [Release notes](https://github.com/typescript-eslint/typescript-eslint/releases)
- [Changelog](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/parser/CHANGELOG.md)
- [Commits](https://github.com/typescript-eslint/typescript-eslint/commits/v7.18.0/packages/parser)

---
updated-dependencies:
- dependency-name: "@typescript-eslint/parser"
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-03 14:50:06 +02:00
dependabot[bot]
1916dfcc44 Bump eslint-plugin-jest from 28.6.0 to 28.8.2 (#23)
Bumps [eslint-plugin-jest](https://github.com/jest-community/eslint-plugin-jest) from 28.6.0 to 28.8.2.
- [Release notes](https://github.com/jest-community/eslint-plugin-jest/releases)
- [Changelog](https://github.com/jest-community/eslint-plugin-jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/jest-community/eslint-plugin-jest/compare/v28.6.0...v28.8.2)

---
updated-dependencies:
- dependency-name: eslint-plugin-jest
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-03 13:31:52 +02:00
dependabot[bot]
f2caa9145e Bump peter-evans/create-pull-request from 6.1.0 to 7.0.0 (#26)
Bumps [peter-evans/create-pull-request](https://github.com/peter-evans/create-pull-request) from 6.1.0 to 7.0.0.
- [Release notes](https://github.com/peter-evans/create-pull-request/releases)
- [Commits](c5a7806660...4320041ed3)

---
updated-dependencies:
- dependency-name: peter-evans/create-pull-request
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-03 13:19:58 +02:00
github-actions[bot]
4b68ead320 chore: update checksums (#25)
Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-09-03 08:08:19 +02:00
Kevin Stillhammer
6a540e2907 Add default-version-update category (#24)
This way a default version update is not a bugfix in release notes
2024-09-02 15:58:05 +02:00
github-actions[bot]
b0c1123987 chore: update checksums (#21)
Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-09-01 20:21:25 +02:00
github-actions[bot]
b038954f55 chore: update checksums (#20)
Co-authored-by: eifinger <1481961+eifinger@users.noreply.github.com>
2024-08-30 16:58:12 +02:00
60 changed files with 19439 additions and 53571 deletions

20
.editorconfig Normal file
View File

@@ -0,0 +1,20 @@
# Check http://editorconfig.org for more information
# This is the main config file for this project:
root = true
[*]
charset = utf-8
trim_trailing_whitespace = true
end_of_line = lf
indent_style = space
insert_final_newline = true
indent_size = 2
[*.{rs,py,pyi}]
indent_size = 4
[*.snap]
trim_trailing_whitespace = false
[*.md]
max_line_length = 100

View File

@@ -1,4 +0,0 @@
dist/
lib/
node_modules/
jest.config.js

View File

@@ -1,57 +0,0 @@
{
"plugins": ["jest", "@typescript-eslint"],
"extends": ["plugin:github/recommended"],
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaVersion": 9,
"sourceType": "module",
"project": "./tsconfig.json"
},
"rules": {
"no-shadow": "off",
"@typescript-eslint/no-shadow": ["error"],
"i18n-text/no-en": "off",
"eslint-comments/no-use": "off",
"import/no-namespace": "off",
"no-unused-vars": "off",
"@typescript-eslint/no-unused-vars": "error",
"@typescript-eslint/explicit-member-accessibility": ["error", {"accessibility": "no-public"}],
"@typescript-eslint/no-require-imports": "error",
"@typescript-eslint/array-type": "error",
"@typescript-eslint/await-thenable": "error",
"@typescript-eslint/ban-ts-comment": "error",
"camelcase": "off",
"@typescript-eslint/consistent-type-assertions": "error",
"@typescript-eslint/explicit-function-return-type": ["error", {"allowExpressions": true}],
"@typescript-eslint/func-call-spacing": ["error", "never"],
"@typescript-eslint/no-array-constructor": "error",
"@typescript-eslint/no-empty-interface": "error",
"@typescript-eslint/no-explicit-any": "error",
"@typescript-eslint/no-extraneous-class": "error",
"@typescript-eslint/no-for-in-array": "error",
"@typescript-eslint/no-inferrable-types": "error",
"@typescript-eslint/no-misused-new": "error",
"@typescript-eslint/no-namespace": "error",
"@typescript-eslint/no-non-null-assertion": "warn",
"@typescript-eslint/no-unnecessary-qualifier": "error",
"@typescript-eslint/no-unnecessary-type-assertion": "error",
"@typescript-eslint/no-useless-constructor": "error",
"@typescript-eslint/no-var-requires": "error",
"@typescript-eslint/prefer-for-of": "warn",
"@typescript-eslint/prefer-function-type": "warn",
"@typescript-eslint/prefer-includes": "error",
"@typescript-eslint/prefer-string-starts-ends-with": "error",
"@typescript-eslint/promise-function-async": "error",
"@typescript-eslint/require-array-sort-compare": "error",
"@typescript-eslint/restrict-plus-operands": "error",
"semi": "off",
"@typescript-eslint/semi": ["error", "never"],
"@typescript-eslint/type-annotation-spacing": "error",
"@typescript-eslint/unbound-method": "error"
},
"env": {
"node": true,
"es6": true,
"jest/globals": true
}
}

2
.gitattributes vendored
View File

@@ -1,2 +1,2 @@
* text=auto eol=lf
dist/** -diff linguist-generated=true
dist/** -diff linguist-generated=true

30
.github/python.json vendored
View File

@@ -1,18 +1,18 @@
{
"problemMatcher": [
"problemMatcher": [
{
"owner": "python",
"pattern": [
{
"owner": "python",
"pattern": [
{
"regexp": "^\\s*File\\s\\\"(.*)\\\",\\sline\\s(\\d+),\\sin\\s(.*)$",
"file": 1,
"line": 2
},
{
"regexp": "^\\s*raise\\s(.*)\\(\\'(.*)\\'\\)$",
"message": 2
}
]
"regexp": "^\\s*File\\s\\\"(.*)\\\",\\sline\\s(\\d+),\\sin\\s(.*)$",
"file": 1,
"line": 2
},
{
"regexp": "^\\s*raise\\s(.*)\\(\\'(.*)\\'\\)$",
"message": 2
}
]
}
]
}
]
}

View File

@@ -1,5 +1,5 @@
name-template: 'v$RESOLVED_VERSION 🌈'
tag-template: 'v$RESOLVED_VERSION'
name-template: "v$RESOLVED_VERSION 🌈"
tag-template: "v$RESOLVED_VERSION"
categories:
- title: "🚨 Breaking changes"
labels:
@@ -19,30 +19,32 @@ categories:
labels:
- "maintenance"
- "ci"
- "update-known-checksums"
- title: "📚 Documentation"
labels:
- "documentation"
- title: "⬆️ Dependency updates"
labels:
- "dependencies"
change-template: '- $TITLE @$AUTHOR (#$NUMBER)'
change-template: "- $TITLE @$AUTHOR (#$NUMBER)"
change-title-escapes: '\<*_&' # You can add # and @ to disable mentions, and add ` to disable code blocks.
version-resolver:
major:
labels:
- 'major'
- 'breaking-change'
- "major"
- "breaking-change"
minor:
labels:
- 'minor'
- 'new-feature'
- 'enhancement'
- "minor"
- "new-feature"
- "enhancement"
patch:
labels:
- 'patch'
- 'bugfix'
- "patch"
- "bugfix"
- "default-version-update"
default: patch
template: |
## Changes
$CHANGES
$CHANGES

View File

@@ -9,11 +9,7 @@ on:
push:
branches:
- main
paths-ignore:
- '**.md'
pull_request:
paths-ignore:
- '**.md'
workflow_dispatch:
jobs:

View File

@@ -13,12 +13,12 @@ name: "CodeQL"
on:
push:
branches: [ main ]
branches: [main]
pull_request:
# The branches below must be a subset of the branches above
branches: [ main ]
branches: [main]
schedule:
- cron: '31 7 * * 3'
- cron: "31 7 * * 3"
jobs:
analyze:
@@ -32,40 +32,40 @@ jobs:
strategy:
fail-fast: false
matrix:
language: [ 'TypeScript' ]
language: ["TypeScript"]
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby' ]
# Learn more about CodeQL language support at https://git.io/codeql-language-support
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Checkout repository
uses: actions/checkout@v4
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v3
with:
languages: ${{ matrix.language }}
source-root: src
# If you wish to specify custom queries, you can do so here or in a config file.
# By default, queries listed here will override any specified in a config file.
# Prefix the list here with "+" to use these queries and those in the config file.
# queries: ./path/to/local/query, your-org/your-repo/queries@main
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v3
with:
languages: ${{ matrix.language }}
source-root: src
# If you wish to specify custom queries, you can do so here or in a config file.
# By default, queries listed here will override any specified in a config file.
# Prefix the list here with "+" to use these queries and those in the config file.
# queries: ./path/to/local/query, your-org/your-repo/queries@main
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v3
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v3
# Command-line programs to run using the OS shell.
# 📚 https://git.io/JvXDl
# Command-line programs to run using the OS shell.
# 📚 https://git.io/JvXDl
# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
# and modify them (or add more) to build your code if your project
# uses a compiled language
# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
# and modify them (or add more) to build your code if your project
# uses a compiled language
#- run: |
# make bootstrap
# make release
#- run: |
# make bootstrap
# make release
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3

View File

@@ -16,4 +16,4 @@ jobs:
- name: 🚀 Run Release Drafter
uses: release-drafter/release-drafter@v6.0.0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

View File

@@ -1,4 +1,4 @@
name: 'test-cache-windows'
name: "test-cache-windows"
on:
pull_request:
push:
@@ -11,10 +11,7 @@ concurrency:
jobs:
test-setup-cache:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [windows-latest]
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- name: Setup with cache
@@ -25,10 +22,7 @@ jobs:
- run: uv sync
working-directory: __tests__\fixtures\uv-project
test-restore-cache:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [windows-latest]
runs-on: windows-latest
needs: test-setup-cache
steps:
- uses: actions/checkout@v4
@@ -36,8 +30,8 @@ jobs:
id: restore
uses: ./
with:
enable-cache: true
cache-suffix: ${{ github.run_id }}-${{ github.run_attempt }}
enable-cache: true
cache-suffix: ${{ github.run_id }}-${{ github.run_attempt }}
- name: Cache was hit
run: |
if ($env:CACHE_HIT -ne "true") {

View File

@@ -1,4 +1,4 @@
name: 'test-cache'
name: "test-cache"
on:
pull_request:
push:
@@ -11,24 +11,18 @@ concurrency:
jobs:
test-setup-cache:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest, macos-14]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup with cache
uses: ./
with:
enable-cache: true
cache-suffix: ${{ github.run_id }}-${{ github.run_attempt }}
cache-suffix: ${{ github.run_id }}-${{ github.run_attempt }}-test-setup-cache
- run: uv sync
working-directory: __tests__/fixtures/uv-project
test-restore-cache:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest, macos-14]
runs-on: ubuntu-latest
needs: test-setup-cache
steps:
- uses: actions/checkout@v4
@@ -36,8 +30,8 @@ jobs:
id: restore
uses: ./
with:
enable-cache: true
cache-suffix: ${{ github.run_id }}-${{ github.run_attempt }}
enable-cache: true
cache-suffix: ${{ github.run_id }}-${{ github.run_attempt }}-test-setup-cache
- name: Cache was hit
run: |
if [ "$CACHE_HIT" != "true" ]; then
@@ -48,20 +42,61 @@ jobs:
- run: uv sync
working-directory: __tests__/fixtures/uv-project
test-setup-cache-local:
runs-on: oracle-aarch64
test-setup-cache-dependency-glob:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup with cache
uses: ./
with:
enable-cache: true
cache-suffix: ${{ github.run_id }}-${{ github.run_attempt }}
cache-dependency-glob: |
__tests__/fixtures/uv-project/uv.lock
**/pyproject.toml
cache-suffix: ${{ github.run_id }}-${{ github.run_attempt }}-test-setup-cache-dependency-glob
- run: uv sync
working-directory: __tests__/fixtures/uv-project
test-restore-cache-dependency-glob:
runs-on: ubuntu-latest
needs: test-setup-cache-dependency-glob
steps:
- uses: actions/checkout@v4
- name: Change pyproject.toml
run: |
echo '[tool.uv]' >> __tests__/fixtures/uv-project/pyproject.toml
echo 'dev-dependencies = []' >> __tests__/fixtures/uv-project/pyproject.toml
- name: Restore with cache
id: restore
uses: ./
with:
enable-cache: true
cache-dependency-glob: |
__tests__/fixtures/uv-project/uv.lock
**/pyproject.toml
cache-suffix: ${{ github.run_id }}-${{ github.run_attempt }}-test-setup-cache-dependency-glob
ignore-nothing-to-cache: true
- name: Cache was not hit
run: |
if [ "$CACHE_HIT" == "true" ]; then
exit 1
fi
env:
CACHE_HIT: ${{ steps.restore.outputs.cache-hit }}
test-setup-cache-local:
runs-on: selfhosted-ubuntu-arm64
steps:
- uses: actions/checkout@v4
- name: Setup with cache
uses: ./
with:
enable-cache: true
cache-suffix: ${{ github.run_id }}-${{ github.run_attempt }}-test-setup-cache-local
cache-local-path: /tmp/uv-cache
- run: uv sync
working-directory: __tests__/fixtures/uv-project
test-restore-cache-local:
runs-on: oracle-aarch64
runs-on: selfhosted-ubuntu-arm64
needs: test-setup-cache-local
steps:
- uses: actions/checkout@v4
@@ -69,9 +104,9 @@ jobs:
id: restore
uses: ./
with:
enable-cache: true
cache-suffix: ${{ github.run_id }}-${{ github.run_attempt }}
cache-local-path: /tmp/uv-cache
enable-cache: true
cache-suffix: ${{ github.run_id }}-${{ github.run_attempt }}-test-setup-cache-local
cache-local-path: /tmp/uv-cache
- name: Cache was hit
run: |
if [ "$CACHE_HIT" != "true" ]; then
@@ -81,3 +116,49 @@ jobs:
CACHE_HIT: ${{ steps.restore.outputs.cache-hit }}
- run: uv sync
working-directory: __tests__/fixtures/uv-project
test-tilde-expansion-cache-local-path:
runs-on: selfhosted-ubuntu-arm64
steps:
- uses: actions/checkout@v4
- name: Create cache directory
run: mkdir -p ~/uv-cache
shell: bash
- name: Setup with cache
uses: ./
with:
cache-local-path: ~/uv-cache/cache-local-path
- run: uv sync
working-directory: __tests__/fixtures/uv-project
test-tilde-expansion-cache-dependency-glob:
runs-on: selfhosted-ubuntu-arm64
steps:
- uses: actions/checkout@v4
- name: Create cache directory
run: mkdir -p ~/uv-cache
shell: bash
- name: Create cache dependency glob file
run: touch ~/uv-cache.glob
shell: bash
- name: Setup with cache
uses: ./
with:
enable-cache: true
cache-local-path: ~/uv-cache/cache-dependency-glob
cache-dependency-glob: "~/uv-cache.glob"
- run: uv sync
working-directory: __tests__/fixtures/uv-project
cleanup-tilde-expansion-tests:
needs:
- test-tilde-expansion-cache-local-path
- test-tilde-expansion-cache-dependency-glob
runs-on: selfhosted-ubuntu-arm64
steps:
- name: Remove cache directory
run: rm -rf ~/uv-cache
shell: bash
- name: Remove cache dependency glob file
run: rm -f ~/uv-cache.glob
shell: bash

View File

@@ -1,4 +1,4 @@
name: 'test-windows'
name: "test-windows"
on:
pull_request:
push:
@@ -23,7 +23,5 @@ jobs:
}
- name: Setup uv
uses: ./
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
- run: uv sync
working-directory: __tests__\fixtures\uv-project

View File

@@ -1,4 +1,4 @@
name: 'test'
name: "test"
on:
pull_request:
push:
@@ -11,76 +11,89 @@ concurrency:
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest, macos-14, oracle-aarch64]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: '20'
node-version: "20"
- run: |
npm install
- run: |
npm run all
- name: Make sure no changes from linters are detected
run: |
git diff --exit-code
test-default-version:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest, macos-14, oracle-aarch64]
os: [ubuntu-latest, macos-latest, macos-14]
steps:
- uses: actions/checkout@v4
- name: Install default version
- name: Install latest version
uses: ./
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
- run: uv sync
working-directory: __tests__/fixtures/uv-project
test-specific-version:
runs-on: ${{ matrix.os }}
runs-on: ubuntu-latest
strategy:
matrix:
os: [ubuntu-latest, macos-latest, macos-14, oracle-aarch64]
uv-version: ['latest','0.3.0','0.3.2']
uv-version: ["0.3.0", "0.3.2", "0.3", "0.3.x", ">=0.3.0"]
steps:
- uses: actions/checkout@v4
- name: Install version ${{ matrix.uv-version }}
uses: ./
with:
version: ${{ matrix.uv-version }}
github-token: ${{ secrets.GITHUB_TOKEN }}
- run: uv sync
working-directory: __tests__/fixtures/uv-project
test-semver-range:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install version 0.3
id: setup-uv
uses: ./
with:
version: "0.3"
- name: Correct version gets installed
run: |
if [ "$UV_VERSION" != "0.3.5" ]; then
exit 1
fi
env:
UV_VERSION: ${{ steps.setup-uv.outputs.uv-version }}
test-checksum:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, oracle-aarch64]
checksum: ['4d9279ad5ca596b1e2d703901d508430eb07564dc4d8837de9e2fca9c90f8ecd']
os: [ubuntu-latest, macos-latest]
checksum:
["4d9279ad5ca596b1e2d703901d508430eb07564dc4d8837de9e2fca9c90f8ecd"]
exclude:
- os: oracle-aarch64
checksum: '4d9279ad5ca596b1e2d703901d508430eb07564dc4d8837de9e2fca9c90f8ecd'
- os: macos-latest
checksum: "4d9279ad5ca596b1e2d703901d508430eb07564dc4d8837de9e2fca9c90f8ecd"
include:
- os: oracle-aarch64
checksum: 'e11b01402ab645392c7ad6044db63d37e4fd1e745e015306993b07695ea5f9f8'
- os: macos-latest
checksum: "a70cbfbf3bb5c08b2f84963b4f12c94e08fbb2468ba418a3bfe1066fbe9e7218"
steps:
- uses: actions/checkout@v4
- name: Checksum matches expected
uses: ./
with:
version: '0.3.2'
version: "0.3.2"
checksum: ${{ matrix.checksum }}
github-token: ${{ secrets.GITHUB_TOKEN }}
test-without-github-token:
test-with-explicit-token:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install default version
uses: ./
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
- run: uv sync
working-directory: __tests__/fixtures/uv-project
test-uvx:
runs-on: ubuntu-latest
steps:
@@ -88,3 +101,57 @@ jobs:
- name: Install default version
uses: ./
- run: uvx ruff --version
test-tool-install:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os:
[
ubuntu-latest,
macos-latest,
macos-14,
windows-latest,
]
steps:
- uses: actions/checkout@v4
- name: Install default version
uses: ./
- run: uv tool install ruff
- run: ruff --version
test-tilde-expansion-tool-dirs:
runs-on: selfhosted-ubuntu-arm64
steps:
- uses: actions/checkout@v4
- name: Setup with cache
uses: ./
with:
tool-bin-dir: "~/tool-bin-dir"
tool-dir: "~/tool-dir"
- name: "Check if tool dirs are expanded"
run: |
if ! echo "$PATH" | grep -q "/home/ubuntu/tool-bin-dir"; then
echo "PATH does not contain /home/ubuntu/tool-bin-dir: $PATH"
exit 1
fi
if [ "$UV_TOOL_DIR" != "/home/ubuntu/tool-dir" ]; then
echo "UV_TOOL_DIR does not contain /home/ubuntu/tool-dir: $UV_TOOL_DIR"
exit 1
fi
test-python-version:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.12", "3.13t"]
steps:
- uses: actions/checkout@v4
- name: Install latest version
uses: ./
with:
python-version: ${{ matrix.python-version }}
- name: Verify UV_PYTHON is set to correct version
run: |
if [ "$UV_PYTHON" != "${{ matrix.python-version }}" ]; then
exit 1
fi
- run: uv sync
working-directory: __tests__/fixtures/uv-project

View File

@@ -1,26 +0,0 @@
name: 'Update default version and checksums'
on:
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: '20'
- name: Update default version and checksums
id: update-default-version
run: node dist/update-default-version/index.js src/download/checksum/known-checksums.ts action.yml ${{ secrets.GITHUB_TOKEN }}
- run: npm install && npm run all
- name: Create Pull Request
uses: peter-evans/create-pull-request@c5a7806660adbe173f04e3e038b0ccdcd758773c # v6.1.0
with:
commit-message: "chore: update checksums"
title: "chore: update default version to ${{ steps.update-default-version.outputs.latest-version }}"
body: "chore: update default version to ${{ steps.update-default-version.outputs.latest-version }}"
base: main
labels: "automated-pr,bugfix"
branch: update-default-version-pr
delete-branch: true

View File

@@ -0,0 +1,32 @@
name: "Update known checksums"
on:
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: "20"
- name: Update known checksums
id: update-known-checksums
run:
node dist/update-known-checksums/index.js
src/download/checksum/known-checksums.ts ${{ secrets.GITHUB_TOKEN }}
- run: npm install && npm run all
- name: Create Pull Request
uses: peter-evans/create-pull-request@5e914681df9dc83aa4e4905692ca88beb2f9e91f # v7.0.5
with:
commit-message: "chore: update known checksums"
title:
"chore: update known checksums for ${{
steps.update-known-checksums.outputs.latest-version }}"
body:
"chore: update known checksums for ${{
steps.update-known-checksums.outputs.latest-version }}"
base: main
labels: "automated-pr,update-known-checksums"
branch: update-known-checksums-pr
delete-branch: true

View File

@@ -5,9 +5,9 @@ name: Update Major Minor Tags
on:
push:
branches-ignore:
- '**'
- "**"
tags:
- 'v*.*.*'
- "v*.*.*"
jobs:
update_major_minor_tags:
@@ -16,4 +16,4 @@ jobs:
steps:
- uses: actions/checkout@v4
- name: Run Update semver
uses: haya14busa/action-update-semver@v1.2.1
uses: haya14busa/action-update-semver@v1.2.1

5
.gitignore vendored
View File

@@ -96,4 +96,7 @@ Thumbs.db
# Ignore built ts files
__tests__/runner/*
lib/**/*
lib/**/*
# Idea IDEs (PyCharm, WebStorm, IntelliJ, etc)
.idea/

View File

@@ -1,3 +0,0 @@
dist/
lib/
node_modules/

View File

@@ -1,10 +0,0 @@
{
"printWidth": 80,
"tabWidth": 2,
"useTabs": false,
"semi": false,
"singleQuote": true,
"trailingComma": "none",
"bracketSpacing": false,
"arrowParens": "avoid"
}

358
README.md
View File

@@ -2,92 +2,143 @@
Set up your GitHub Actions workflow with a specific version of [uv](https://docs.astral.sh/uv/).
* Install a version of uv and add it to the path
* Cache the installed version of uv to speed up consecutive runs on self-hosted runners
* Register problem matchers for error output
* Optional: Cache the uv cache
* Optional: Verify the checksum of the downloaded uv executable
- Install a version of uv and add it to PATH
- Cache the installed version of uv to speed up consecutive runs on self-hosted runners
- Register problem matchers for error output
- (Optional) Persist the uv's cache in the GitHub Actions Cache
- (Optional) Verify the checksum of the downloaded uv executable
## Contents
* [Usage](#usage)
* [Install specific version](#install-specific-version)
* [Install latest version](#install-latest-version)
* [Validate checksum](#validate-checksum)
* [Enable Caching](#enable-caching)
* [Local cache path](#local-cache-path)
* [Cache dependency glob](#cache-dependency-glob)
* [API rate limit](#api-rate-limit)
* [How it works](#how-it-works)
* [FAQ](#faq)
- [Usage](#usage)
- [Install the latest version (default)](#install-the-latest-version-default)
- [Install a specific version](#install-a-specific-version)
- [Install a version by supplying a semver range](#install-a-version-by-supplying-a-semver-range)
- [Python version](#python-version)
- [Validate checksum](#validate-checksum)
- [Enable Caching](#enable-caching)
- [Cache dependency glob](#cache-dependency-glob)
- [Local cache path](#local-cache-path)
- [Disable cache pruning](#disable-cache-pruning)
- [Ignore nothing to cache](#ignore-nothing-to-cache)
- [GitHub authentication token](#github-authentication-token)
- [UV_TOOL_DIR](#uv_tool_dir)
- [UV_TOOL_BIN_DIR](#uv_tool_bin_dir)
- [Tilde Expansion](#tilde-expansion)
- [How it works](#how-it-works)
- [FAQ](#faq)
## Usage
Example workflow in a real world project can be found [here](https://github.com/eifinger/hass-weenect/blob/main/.github/workflows/ci.yml)
### Install specific version
You can also specify a specific version of uv
### Install the latest version (default)
```yaml
- name: Install a specific version
uses: eifinger/setup-uv@v1
- name: Install the latest version of uv
uses: astral-sh/setup-uv@v4
with:
version: '0.3.0'
version: "latest"
```
### Install latest version
For an example workflow, see
[here](https://github.com/charliermarsh/autobot/blob/e42c66659bf97b90ca9ff305a19cc99952d0d43f/.github/workflows/ci.yaml).
By default this action installs the version defined as `default` in `action.yml`.
This gets automatically updated in a new release of this action when a new version of uv is released.
If you don't want to wait for a new release of this action you can use use `version: latest`.
> [!WARNING]
> Using the `latest` version means that the uv executable gets downloaded every single time instead of loaded from the tools cache.
> This can take up to 20s depending on the download speed.
> This does not affect the uv cache.
### Install a specific version
```yaml
- name: Install a specific version
uses: eifinger/setup-uv@v1
- name: Install a specific version of uv
uses: astral-sh/setup-uv@v4
with:
version: 'latest'
version: "0.4.4"
```
### Install a version by supplying a semver range
You can specify a [semver range](https://github.com/npm/node-semver?tab=readme-ov-file#ranges)
to install the latest version that satisfies the range.
```yaml
- name: Install a semver range of uv
uses: astral-sh/setup-uv@v4
with:
version: ">=0.4.0"
```
```yaml
- name: Pinning a minor version of uv
uses: astral-sh/setup-uv@v4
with:
version: "0.4.x"
```
### Python version
You can use the input `python-version` to set the environment variable `UV_PYTHON` for the rest
of your workflow.
This will override any python version specifications in `pyproject.toml` and `.python-version`
```yaml
- name: Install the latest version of uv and set the python version to 3.12
uses: astral-sh/setup-uv@v4
with:
python-version: "3.12"
```
You can combine this with a matrix to test multiple python versions:
```yaml
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.9", "3.10", "3.11", "3.12"]
steps:
- uses: actions/checkout@v4
- name: Install the latest version of uv and set the python version
uses: astral-sh/setup-uv@v4
with:
python-version: ${{ matrix.python-version }}
- name: Test with python ${{ matrix.python-version }}
run: uv run --frozen pytest
```
### Validate checksum
You can also specify a checksum to validate the downloaded file.
Checksums up to the default version are automatically verified by this action.
The sha265 hashes can be found on the [releases page](https://github.com/astral-sh/uv/releases)
of the uv repo.
You can specify a checksum to validate the downloaded executable. Checksums up to the default version
are automatically verified by this action. The sha256 hashes can be found on the
[releases page](https://github.com/astral-sh/uv/releases) of the uv repo.
```yaml
- name: Install a specific version and validate the checksum
uses: eifinger/setup-uv@v1
uses: astral-sh/setup-uv@v4
with:
version: '0.3.1'
checksum: 'e11b01402ab645392c7ad6044db63d37e4fd1e745e015306993b07695ea5f9f8'
version: "0.3.1"
checksum: "e11b01402ab645392c7ad6044db63d37e4fd1e745e015306993b07695ea5f9f8"
```
### Enable caching
If you enable caching the [uv cache](https://docs.astral.sh/uv/concepts/cache/) will
be cached to the GitHub Actions Cache. This can speed up runs which can reuse the cache
by several minutes. The cache will always be reused on self-hosted runners.
If you enable caching, the [uv cache](https://docs.astral.sh/uv/concepts/cache/) will be uploaded to
the GitHub Actions cache. This can speed up runs that reuse the cache by several minutes.
> [!TIP]
>
> On self-hosted runners this is usually not needed since the cache generated by uv on the runner's
> filesystem is not removed after a run. For more details see [Local cache path](#local-cache-path).
You can optionally define a custom cache key suffix.
```yaml
- name: Enable caching and define a custom cache key suffix
id: setup-uv
uses: eifinger/setup-uv@v1
uses: astral-sh/setup-uv@v4
with:
enable-cache: true
cache-suffix: 'optional-suffix'
cache-suffix: "optional-suffix"
```
When the cache was successfully restored the output `cache-hit` will be set to `true` and you can use it in subsequent steps.
For the example above you can use it like this:
When the cache was successfully restored, the output `cache-hit` will be set to `true` and you can
use it in subsequent steps. For example, to use the cache in the above case:
```yaml
- name: Do something if the cache was restored
@@ -95,82 +146,207 @@ For the example above you can use it like this:
run: echo "Cache was restored"
```
#### Local cache path
#### Cache dependency glob
If you want to save the cache to a local path other than the default path (`/tmp/setup-uv-cache`)
you can specify the path with the `cache-local-path` input.
If you want to control when the GitHub Actions cache is invalidated, specify a glob pattern with the
`cache-dependency-glob` input. The GitHub Actions cache will be invalidated if any file matching the glob pattern
changes. If you use relative paths, they are relative to the repository root.
> [!NOTE]
>
> The default is `**/uv.lock`.
```yaml
- name: Define a cache dependency glob
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@v4
with:
enable-cache: true
cache-dependency-glob: |
**/requirements*.txt
**/pyproject.toml
```
```yaml
- name: Define an absolute cache dependency glob
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@v4
with:
enable-cache: true
cache-dependency-glob: ""
```
### Local cache path
This action controls where uv stores its cache on the runner's filesystem by setting `UV_CACHE_DIR`.
It defaults to `setup-uv-cache` in the `TMP` dir, `D:\a\_temp\uv-tool-dir` on Windows and
`/tmp/setup-uv-cache` on Linux/macOS. You can change the default by specifying the path with the
`cache-local-path` input.
```yaml
- name: Define a custom uv cache path
uses: eifinger/setup-uv@v1
uses: astral-sh/setup-uv@v4
with:
enable-cache: true
cache-local-path: '/path/to/cache'
cache-local-path: "/path/to/cache"
```
#### Cache dependency glob
### Disable cache pruning
If you want to control when the cache is invalidated you can specify a glob pattern with the `cache-dependency-glob` input.
The cache will be invalidated if any file matching the glob pattern changes.
The glob matches files relative to the repository root.
By default, the uv cache is pruned after every run, removing pre-built wheels, but retaining any
wheels that were built from source. On GitHub-hosted runners, it's typically faster to omit those
pre-built wheels from the cache (and instead re-download them from the registry on each run).
However, on self-hosted or local runners, preserving the cache may be more efficient. See
the [documentation](https://docs.astral.sh/uv/concepts/cache/#caching-in-continuous-integration) for
more information.
If you want to persist the entire cache across runs, disable cache pruning with the `prune-cache`
input.
```yaml
- name: Define a cache dependency glob
uses: eifinger/setup-uv@v1
- name: Don't prune the cache before saving it
uses: astral-sh/setup-uv@v4
with:
enable-cache: true
cache-dependency-glob: 'uv.lock'
prune-cache: false
```
### Ignore nothing to cache
By default, the action will fail if caching is enabled but there is nothing to upload (the uv cache directory does not exist).
If you want to ignore this, set the `ignore-nothing-to-cache` input to `true`.
```yaml
- name: Define a cache dependency glob
uses: eifinger/setup-uv@v1
- name: Ignore nothing to cache
uses: astral-sh/setup-uv@v4
with:
enable-cache: true
cache-dependency-glob: '**requirements*.txt'
ignore-nothing-to-cache: true
```
### API rate limit
### GitHub authentication token
To avoid hitting the error `API rate limit exceeded` you can supply a GitHub token with the `github-token` input.
This action uses the GitHub API to fetch the uv release artifacts. To avoid hitting the GitHub API
rate limit too quickly, an authentication token can be provided via the `github-token` input. By
default, the `GITHUB_TOKEN` secret is used, which is automatically provided by GitHub Actions.
If the default
[permissions for the GitHub token](https://docs.github.com/en/actions/security-for-github-actions/security-guides/automatic-token-authentication#permissions-for-the-github_token)
are not sufficient, you can provide a custom GitHub token with the necessary permissions.
```yaml
- name: Install uv and supply a GitHub token
uses: eifinger/setup-uv@v1
- name: Install the latest version of uv with a custom GitHub token
uses: astral-sh/setup-uv@v4
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
github-token: ${{ secrets.CUSTOM_GITHUB_TOKEN }}
```
### UV_TOOL_DIR
On Windows `UV_TOOL_DIR` is set to `uv-tool-dir` in the `TMP` dir (e.g. `D:\a\_temp\uv-tool-dir`).
On GitHub hosted runners this is on the much faster `D:` drive.
On all other platforms the tool environments are placed in the
[default location](https://docs.astral.sh/uv/concepts/tools/#tools-directory).
If you want to change this behaviour (especially on self-hosted runners) you can use the `tool-dir`
input:
```yaml
- name: Install the latest version of uv with a custom tool dir
uses: astral-sh/setup-uv@v4
with:
tool-dir: "/path/to/tool/dir"
```
### UV_TOOL_BIN_DIR
On Windows `UV_TOOL_BIN_DIR` is set to `uv-tool-bin-dir` in the `TMP` dir (e.g.
`D:\a\_temp\uv-tool-bin-dir`). On GitHub hosted runners this is on the much faster `D:` drive. This
path is also automatically added to the PATH.
On all other platforms the tool binaries get installed to the
[default location](https://docs.astral.sh/uv/concepts/tools/#the-bin-directory).
If you want to change this behaviour (especially on self-hosted runners) you can use the
`tool-bin-dir` input:
```yaml
- name: Install the latest version of uv with a custom tool bin dir
uses: astral-sh/setup-uv@v4
with:
tool-bin-dir: "/path/to/tool-bin/dir"
```
### Tilde Expansion
This action supports expanding the `~` character to the user's home directory for the following inputs:
- `cache-local-path`
- `tool-dir`
- `tool-bin-dir`
- `cache-dependency-glob`
```yaml
- name: Expand the tilde character
uses: astral-sh/setup-uv@v4
with:
cache-local-path: "~/path/to/cache"
tool-dir: "~/path/to/tool/dir"
tool-bin-dir: "~/path/to/tool-bin/dir"
cache-dependency-glob: "~/my-cache-buster"
```
## How it works
This action downloads uv from the releases of the [uv repo](https://github.com/astral-sh/uv) and uses the [GitHub Actions Toolkit](https://github.com/actions/toolkit) to cache it as a tool to speed up consecutive runs on self-hosted runners.
This action downloads uv from the uv repo's official
[GitHub Releases](https://github.com/astral-sh/uv) and uses the
[GitHub Actions Toolkit](https://github.com/actions/toolkit) to cache it as a tool to speed up
consecutive runs on self-hosted runners.
The installed version of uv is then added to the runner path so other steps can just use it by calling `uv`.
The installed version of uv is then added to the runner PATH, enabling subsequent steps to invoke it
by name (`uv`).
## FAQ
### Do I still need actions/setup-python when using this action?
### Do I still need `actions/setup-python` alongside `setup-uv`?
No! This action was modelled as a drop-in replacement for `actions/setup-python` when using uv.
No. This action is modelled as a drop-in replacement for `actions/setup-python` when using uv. With
`setup-uv`, you can install a specific version of Python using `uv python install` rather than
relying on `actions/setup-python`.
A simple example workflow could look like this:
For example:
```yaml
- name: Checkout the repository
uses: actions/checkout@main
- name: Install the latest version of uv
uses: eifinger/setup-uv@v1
uses: astral-sh/setup-uv@v4
with:
enable-cache: true
- name: Test
run: uv run --frozen pytest
```
If you want to have a specific python version installed you can use the command [`uv python install`](https://docs.astral.sh/uv/guides/install-python/):
To install a specific version of Python, use
[`uv python install`](https://docs.astral.sh/uv/guides/install-python/):
```yaml
- name: Install the latest version of uv
uses: eifinger/setup-uv@v1
uses: astral-sh/setup-uv@v4
with:
enable-cache: true
- name: Install Python 3.12
@@ -179,22 +355,34 @@ If you want to have a specific python version installed you can use the command
### What is the default version?
By default this action installs the version defined as `default` in `action.yml`.
When a new release of uv is published this triggers an automatic release of this action with the new version as `default`.
By default, this action installs the latest version of uv.
If you have to know the version installed for other steps of your workflow you can use the `uv-version` output:
If you require the installed version in subsequent steps of your workflow, use the `uv-version`
output:
```yaml
- name: Checkout the repository
uses: actions/checkout@main
- name: Install the default version of uv
id: setup-uv
uses: eifinger/setup-uv@v1
uses: astral-sh/setup-uv@v4
- name: Print the installed version
run: echo "Installed uv version is ${{ steps.setup-uv.outputs.uv-version }}"
```
---
## Acknowledgements
[<img src="https://raw.githubusercontent.com/eifinger/setup-uv/main/docs/images/bmc-button.svg" width=150 height=40 style="margin: 5px"/>](https://www.buymeacoffee.com/eifinger)
[<img src="https://raw.githubusercontent.com/eifinger/setup-uv/main/docs/images/paypal-button.svg" width=150 height=40 style="margin: 5px"/>](https://paypal.me/kevinstillhammer)
`setup-uv` was initially written and published by [Kevin Stillhammer](https://github.com/eifinger)
before moving under the official [Astral](https://github.com/astral-sh) GitHub organization. You can
support Kevin's work in open source on [Buy me a coffee](https://www.buymeacoffee.com/eifinger) or
[PayPal](https://paypal.me/kevinstillhammer).
## License
MIT
<div align="center">
<a target="_blank" href="https://astral.sh" style="background:none">
<img src="https://raw.githubusercontent.com/astral-sh/uv/main/assets/svg/Astral.svg" alt="Made by Astral">
</a>
</div>

View File

@@ -1,37 +0,0 @@
import {expect, test, it} from '@jest/globals'
import {
isknownVersion,
validateChecksum
} from '../../../src/download/checksum/checksum'
test('checksum should match', async () => {
const validChecksum =
'f3da96ec7e995debee7f5d52ecd034dfb7074309a1da42f76429ecb814d813a3'
const filePath = '__tests__/fixtures/checksumfile'
// string params don't matter only test the checksum mechanism, not known checksums
await validateChecksum(
validChecksum,
filePath,
'aarch64',
'pc-windows-msvc',
'1.2.3'
)
})
type KnownVersionFixture = {version: string; known: boolean}
it.each<KnownVersionFixture>([
{
version: '0.3.0',
known: true
},
{
version: '0.0.15',
known: false
}
])(
'isknownVersion should return $known for version $version',
({version, known}) => {
expect(isknownVersion(version)).toBe(known)
}
)

View File

@@ -0,0 +1,37 @@
import { expect, test, it } from "@jest/globals";
import {
isknownVersion,
validateChecksum,
} from "../../../src/download/checksum/checksum";
test("checksum should match", async () => {
const validChecksum =
"f3da96ec7e995debee7f5d52ecd034dfb7074309a1da42f76429ecb814d813a3";
const filePath = "__tests__/fixtures/checksumfile";
// string params don't matter only test the checksum mechanism, not known checksums
await validateChecksum(
validChecksum,
filePath,
"aarch64",
"pc-windows-msvc",
"1.2.3",
);
});
type KnownVersionFixture = { version: string; known: boolean };
it.each<KnownVersionFixture>([
{
version: "0.3.0",
known: true,
},
{
version: "0.0.15",
known: false,
},
])(
"isknownVersion should return $known for version $version",
({ version, known }) => {
expect(isknownVersion(version)).toBe(known);
},
);

View File

@@ -1,38 +1,59 @@
name: 'Python setup uv'
description: 'Set up your GitHub Actions workflow with a specific version of uv'
author: 'eifinger'
name: "astral-sh/setup-uv"
description:
"Set up your GitHub Actions workflow with a specific version of uv."
author: "astral-sh"
inputs:
version:
description: 'The version of uv to install'
default: '0.4.0'
version:
description: "The version of uv to install"
default: "latest"
python-version:
description: "The version of Python to set UV_PYTHON to"
required: false
checksum:
description: 'The checksum of the uv version to install'
description: "The checksum of the uv version to install"
required: false
github-token:
description: 'Used to increase the rate limit when retrieving versions and downloading uv.'
description:
"Used to increase the rate limit when retrieving versions and downloading
uv."
required: false
default: ${{ github.token }}
enable-cache:
description: 'Enable caching of the uv cache'
default: 'false'
description: "Enable caching of the uv cache"
default: "false"
cache-dependency-glob:
description: 'Glob pattern to match files relative to the repository root to control the cache. e.g. "uv.lock"'
required: false
description:
"Glob pattern to match files relative to the repository root to control
the cache."
default: "**/uv.lock"
cache-suffix:
description: 'Suffix for the cache key'
description: "Suffix for the cache key"
required: false
cache-local-path:
description: 'Local path to store the cache.'
default: '/tmp/setup-uv-cache'
description: "Local path to store the cache."
default: ""
prune-cache:
description: "Prune cache before saving."
default: "true"
ignore-nothing-to-cache:
description: "Ignore when nothing is found to cache."
default: "false"
tool-dir:
description: "Custom path to set UV_TOOL_DIR to."
required: false
tool-bin-dir:
description: "Custom path to set UV_TOOL_BIN_DIR to."
required: false
outputs:
uv-version:
description: "The installed uv version. Useful when using latest."
cache-hit:
description: "A boolean value to indicate a cache entry was found"
runs:
using: 'node20'
main: 'dist/setup/index.js'
post: 'dist/save-cache/index.js'
using: "node20"
main: "dist/setup/index.js"
post: "dist/save-cache/index.js"
post-if: success()
branding:
icon: 'package'
color: 'blue'
icon: "package"
color: "black"

31
biome.json Normal file
View File

@@ -0,0 +1,31 @@
{
"$schema": "https://biomejs.dev/schemas/1.9.2/schema.json",
"vcs": {
"enabled": true,
"clientKind": "git",
"useIgnoreFile": false
},
"files": {
"ignoreUnknown": false,
"ignore": ["dist", "lib", "node_modules"]
},
"formatter": {
"enabled": true,
"indentStyle": "space"
},
"organizeImports": {
"enabled": true
},
"linter": {
"enabled": true,
"rules": {
"recommended": true
}
},
"javascript": {
"formatter": {
"quoteStyle": "double",
"trailingCommas": "all"
}
}
}

4210
dist/save-cache/index.js generated vendored

File diff suppressed because one or more lines are too long

1
dist/save-cache/index.js.map generated vendored

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

453
dist/setup/37.index.js generated vendored
View File

@@ -1,453 +0,0 @@
"use strict";
exports.id = 37;
exports.ids = [37];
exports.modules = {
/***/ 4037:
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */ "toFormData": () => (/* binding */ toFormData)
/* harmony export */ });
/* harmony import */ var fetch_blob_from_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2777);
/* harmony import */ var formdata_polyfill_esm_min_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(8010);
let s = 0;
const S = {
START_BOUNDARY: s++,
HEADER_FIELD_START: s++,
HEADER_FIELD: s++,
HEADER_VALUE_START: s++,
HEADER_VALUE: s++,
HEADER_VALUE_ALMOST_DONE: s++,
HEADERS_ALMOST_DONE: s++,
PART_DATA_START: s++,
PART_DATA: s++,
END: s++
};
let f = 1;
const F = {
PART_BOUNDARY: f,
LAST_BOUNDARY: f *= 2
};
const LF = 10;
const CR = 13;
const SPACE = 32;
const HYPHEN = 45;
const COLON = 58;
const A = 97;
const Z = 122;
const lower = c => c | 0x20;
const noop = () => {};
class MultipartParser {
/**
* @param {string} boundary
*/
constructor(boundary) {
this.index = 0;
this.flags = 0;
this.onHeaderEnd = noop;
this.onHeaderField = noop;
this.onHeadersEnd = noop;
this.onHeaderValue = noop;
this.onPartBegin = noop;
this.onPartData = noop;
this.onPartEnd = noop;
this.boundaryChars = {};
boundary = '\r\n--' + boundary;
const ui8a = new Uint8Array(boundary.length);
for (let i = 0; i < boundary.length; i++) {
ui8a[i] = boundary.charCodeAt(i);
this.boundaryChars[ui8a[i]] = true;
}
this.boundary = ui8a;
this.lookbehind = new Uint8Array(this.boundary.length + 8);
this.state = S.START_BOUNDARY;
}
/**
* @param {Uint8Array} data
*/
write(data) {
let i = 0;
const length_ = data.length;
let previousIndex = this.index;
let {lookbehind, boundary, boundaryChars, index, state, flags} = this;
const boundaryLength = this.boundary.length;
const boundaryEnd = boundaryLength - 1;
const bufferLength = data.length;
let c;
let cl;
const mark = name => {
this[name + 'Mark'] = i;
};
const clear = name => {
delete this[name + 'Mark'];
};
const callback = (callbackSymbol, start, end, ui8a) => {
if (start === undefined || start !== end) {
this[callbackSymbol](ui8a && ui8a.subarray(start, end));
}
};
const dataCallback = (name, clear) => {
const markSymbol = name + 'Mark';
if (!(markSymbol in this)) {
return;
}
if (clear) {
callback(name, this[markSymbol], i, data);
delete this[markSymbol];
} else {
callback(name, this[markSymbol], data.length, data);
this[markSymbol] = 0;
}
};
for (i = 0; i < length_; i++) {
c = data[i];
switch (state) {
case S.START_BOUNDARY:
if (index === boundary.length - 2) {
if (c === HYPHEN) {
flags |= F.LAST_BOUNDARY;
} else if (c !== CR) {
return;
}
index++;
break;
} else if (index - 1 === boundary.length - 2) {
if (flags & F.LAST_BOUNDARY && c === HYPHEN) {
state = S.END;
flags = 0;
} else if (!(flags & F.LAST_BOUNDARY) && c === LF) {
index = 0;
callback('onPartBegin');
state = S.HEADER_FIELD_START;
} else {
return;
}
break;
}
if (c !== boundary[index + 2]) {
index = -2;
}
if (c === boundary[index + 2]) {
index++;
}
break;
case S.HEADER_FIELD_START:
state = S.HEADER_FIELD;
mark('onHeaderField');
index = 0;
// falls through
case S.HEADER_FIELD:
if (c === CR) {
clear('onHeaderField');
state = S.HEADERS_ALMOST_DONE;
break;
}
index++;
if (c === HYPHEN) {
break;
}
if (c === COLON) {
if (index === 1) {
// empty header field
return;
}
dataCallback('onHeaderField', true);
state = S.HEADER_VALUE_START;
break;
}
cl = lower(c);
if (cl < A || cl > Z) {
return;
}
break;
case S.HEADER_VALUE_START:
if (c === SPACE) {
break;
}
mark('onHeaderValue');
state = S.HEADER_VALUE;
// falls through
case S.HEADER_VALUE:
if (c === CR) {
dataCallback('onHeaderValue', true);
callback('onHeaderEnd');
state = S.HEADER_VALUE_ALMOST_DONE;
}
break;
case S.HEADER_VALUE_ALMOST_DONE:
if (c !== LF) {
return;
}
state = S.HEADER_FIELD_START;
break;
case S.HEADERS_ALMOST_DONE:
if (c !== LF) {
return;
}
callback('onHeadersEnd');
state = S.PART_DATA_START;
break;
case S.PART_DATA_START:
state = S.PART_DATA;
mark('onPartData');
// falls through
case S.PART_DATA:
previousIndex = index;
if (index === 0) {
// boyer-moore derrived algorithm to safely skip non-boundary data
i += boundaryEnd;
while (i < bufferLength && !(data[i] in boundaryChars)) {
i += boundaryLength;
}
i -= boundaryEnd;
c = data[i];
}
if (index < boundary.length) {
if (boundary[index] === c) {
if (index === 0) {
dataCallback('onPartData', true);
}
index++;
} else {
index = 0;
}
} else if (index === boundary.length) {
index++;
if (c === CR) {
// CR = part boundary
flags |= F.PART_BOUNDARY;
} else if (c === HYPHEN) {
// HYPHEN = end boundary
flags |= F.LAST_BOUNDARY;
} else {
index = 0;
}
} else if (index - 1 === boundary.length) {
if (flags & F.PART_BOUNDARY) {
index = 0;
if (c === LF) {
// unset the PART_BOUNDARY flag
flags &= ~F.PART_BOUNDARY;
callback('onPartEnd');
callback('onPartBegin');
state = S.HEADER_FIELD_START;
break;
}
} else if (flags & F.LAST_BOUNDARY) {
if (c === HYPHEN) {
callback('onPartEnd');
state = S.END;
flags = 0;
} else {
index = 0;
}
} else {
index = 0;
}
}
if (index > 0) {
// when matching a possible boundary, keep a lookbehind reference
// in case it turns out to be a false lead
lookbehind[index - 1] = c;
} else if (previousIndex > 0) {
// if our boundary turned out to be rubbish, the captured lookbehind
// belongs to partData
const _lookbehind = new Uint8Array(lookbehind.buffer, lookbehind.byteOffset, lookbehind.byteLength);
callback('onPartData', 0, previousIndex, _lookbehind);
previousIndex = 0;
mark('onPartData');
// reconsider the current character even so it interrupted the sequence
// it could be the beginning of a new sequence
i--;
}
break;
case S.END:
break;
default:
throw new Error(`Unexpected state entered: ${state}`);
}
}
dataCallback('onHeaderField');
dataCallback('onHeaderValue');
dataCallback('onPartData');
// Update properties for the next call
this.index = index;
this.state = state;
this.flags = flags;
}
end() {
if ((this.state === S.HEADER_FIELD_START && this.index === 0) ||
(this.state === S.PART_DATA && this.index === this.boundary.length)) {
this.onPartEnd();
} else if (this.state !== S.END) {
throw new Error('MultipartParser.end(): stream ended unexpectedly');
}
}
}
function _fileName(headerValue) {
// matches either a quoted-string or a token (RFC 2616 section 19.5.1)
const m = headerValue.match(/\bfilename=("(.*?)"|([^()<>@,;:\\"/[\]?={}\s\t]+))($|;\s)/i);
if (!m) {
return;
}
const match = m[2] || m[3] || '';
let filename = match.slice(match.lastIndexOf('\\') + 1);
filename = filename.replace(/%22/g, '"');
filename = filename.replace(/&#(\d{4});/g, (m, code) => {
return String.fromCharCode(code);
});
return filename;
}
async function toFormData(Body, ct) {
if (!/multipart/i.test(ct)) {
throw new TypeError('Failed to fetch');
}
const m = ct.match(/boundary=(?:"([^"]+)"|([^;]+))/i);
if (!m) {
throw new TypeError('no or bad content-type header, no multipart boundary');
}
const parser = new MultipartParser(m[1] || m[2]);
let headerField;
let headerValue;
let entryValue;
let entryName;
let contentType;
let filename;
const entryChunks = [];
const formData = new formdata_polyfill_esm_min_js__WEBPACK_IMPORTED_MODULE_1__/* .FormData */ .Ct();
const onPartData = ui8a => {
entryValue += decoder.decode(ui8a, {stream: true});
};
const appendToFile = ui8a => {
entryChunks.push(ui8a);
};
const appendFileToFormData = () => {
const file = new fetch_blob_from_js__WEBPACK_IMPORTED_MODULE_0__/* .File */ .$B(entryChunks, filename, {type: contentType});
formData.append(entryName, file);
};
const appendEntryToFormData = () => {
formData.append(entryName, entryValue);
};
const decoder = new TextDecoder('utf-8');
decoder.decode();
parser.onPartBegin = function () {
parser.onPartData = onPartData;
parser.onPartEnd = appendEntryToFormData;
headerField = '';
headerValue = '';
entryValue = '';
entryName = '';
contentType = '';
filename = null;
entryChunks.length = 0;
};
parser.onHeaderField = function (ui8a) {
headerField += decoder.decode(ui8a, {stream: true});
};
parser.onHeaderValue = function (ui8a) {
headerValue += decoder.decode(ui8a, {stream: true});
};
parser.onHeaderEnd = function () {
headerValue += decoder.decode();
headerField = headerField.toLowerCase();
if (headerField === 'content-disposition') {
// matches either a quoted-string or a token (RFC 2616 section 19.5.1)
const m = headerValue.match(/\bname=("([^"]*)"|([^()<>@,;:\\"/[\]?={}\s\t]+))/i);
if (m) {
entryName = m[2] || m[3] || '';
}
filename = _fileName(headerValue);
if (filename) {
parser.onPartData = appendToFile;
parser.onPartEnd = appendFileToFormData;
}
} else if (headerField === 'content-type') {
contentType = headerValue;
}
headerValue = '';
headerField = '';
};
for await (const chunk of Body) {
parser.write(chunk);
}
parser.end();
return formData;
}
/***/ })
};
;
//# sourceMappingURL=37.index.js.map

1
dist/setup/37.index.js.map generated vendored

File diff suppressed because one or more lines are too long

12244
dist/setup/index.js generated vendored

File diff suppressed because one or more lines are too long

1
dist/setup/index.js.map generated vendored

File diff suppressed because one or more lines are too long

1056
dist/setup/licenses.txt generated vendored

File diff suppressed because it is too large Load Diff

1
dist/setup/sourcemap-register.js generated vendored

File diff suppressed because one or more lines are too long

35031
dist/update-checksums/index.js generated vendored

File diff suppressed because one or more lines are too long

1
dist/update-checksums/index.js.map generated vendored

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

Before

Width:  |  Height:  |  Size: 36 KiB

View File

@@ -1,15 +0,0 @@
<svg id="Layer_1" data-name="Layer 1" xmlns="http://www.w3.org/2000/svg" width="545" height="153" viewBox="0 0 545 153">
<defs>
<style>
.cls-1{fill:#009ee3;}.cls-1,.cls-2,.cls-3{fill-rule:evenodd;}.cls-2{fill:#113984;}.cls-3{fill:#172c70;}</style>
</defs>
<title>paypal-seeklogo.com</title>
<path transform="scale(1, 1)" d="M0 24.48C0 10.9601 10.9601 0 24.48 0H520.2C533.72 0 544.68 10.9601 544.68 24.48V128.52C544.68 142.04 533.72 153 520.2 153H24.48C10.9601 153 0 142.04 0 128.52V24.48Z" fill="#ebf2ff"/>
<g transform="scale(0.8, 0.8) translate(45, 25)">
<path class="cls-1" d="M192.95,386.87h38.74c20.8,0,28.63,10.53,27.42,26-2,25.54-17.44,39.67-37.92,39.67H210.85c-2.81,0-4.7,1.86-5.46,6.9L201,488.74c-0.29,1.9-1.29,3-2.79,3.15H173.87c-2.29,0-3.1-1.75-2.5-5.54l14.84-93.93C186.79,388.66,188.85,386.87,192.95,386.87Z" transform="translate(-143.48 -354.54)"/>
<path class="cls-2" d="M361.14,385.13c13.07,0,25.13,7.09,23.48,24.76-2,21-13.25,32.62-31,32.67H338.11c-2.23,0-3.31,1.82-3.89,5.55l-3,19.07c-0.45,2.88-1.93,4.3-4.11,4.3H312.68c-2.3,0-3.1-1.47-2.59-4.76L322,390.29c0.59-3.76,2-5.16,4.57-5.16h34.54Zm-23.5,40.92h11.75c7.35-.28,12.23-5.37,12.72-14.55,0.3-5.67-3.53-9.73-9.62-9.7l-11.06.05-3.79,24.2h0Zm86.21,39.58c1.32-1.2,2.66-1.82,2.47-.34l-0.47,3.54c-0.24,1.85.49,2.83,2.21,2.83h12.82c2.16,0,3.21-.87,3.74-4.21l7.9-49.58c0.4-2.49-.21-3.71-2.1-3.71H436.32c-1.27,0-1.89.71-2.22,2.65l-0.52,3.05c-0.27,1.59-1,1.87-1.68.27-2.39-5.66-8.49-8.2-17-8-19.77.41-33.1,15.42-34.53,34.66-1.1,14.88,9.56,26.57,23.62,26.57,10.2,0,14.76-3,19.9-7.7h0ZM413.11,458c-8.51,0-14.44-6.79-13.21-15.11s9.19-15.11,17.7-15.11,14.44,6.79,13.21,15.11S421.63,458,413.11,458h0Zm64.5-44h-13c-2.68,0-3.77,2-2.92,4.46l16.14,47.26L462,488.21c-1.33,1.88-.3,3.59,1.57,3.59h14.61a4.47,4.47,0,0,0,4.34-2.13l49.64-71.2c1.53-2.19.81-4.49-1.7-4.49H516.63c-2.37,0-3.32.94-4.68,2.91l-20.7,30L482,416.82C481.46,415,480.11,414,477.62,414Z" transform="translate(-143.48 -354.54)"/>
<path class="cls-1" d="M583.8,385.13c13.07,0,25.13,7.09,23.48,24.76-2,21-13.25,32.62-31,32.67H560.78c-2.23,0-3.31,1.82-3.89,5.55l-3,19.07c-0.45,2.88-1.93,4.3-4.11,4.3H535.35c-2.3,0-3.1-1.47-2.59-4.76l11.93-76.45c0.59-3.76,2-5.16,4.57-5.16H583.8Zm-23.5,40.92h11.75c7.35-.28,12.23-5.37,12.72-14.55,0.3-5.67-3.53-9.73-9.62-9.7l-11.06.05-3.79,24.2h0Zm86.21,39.58c1.32-1.2,2.66-1.82,2.47-.34l-0.47,3.54c-0.24,1.85.49,2.83,2.21,2.83h12.82c2.16,0,3.21-.87,3.74-4.21l7.9-49.58c0.4-2.49-.21-3.71-2.1-3.71H659c-1.27,0-1.89.71-2.22,2.65l-0.52,3.05c-0.27,1.59-1,1.87-1.68.27-2.39-5.66-8.49-8.2-17-8-19.77.41-33.1,15.42-34.53,34.66-1.1,14.88,9.56,26.57,23.62,26.57,10.2,0,14.76-3,19.9-7.7h0ZM635.78,458c-8.51,0-14.44-6.79-13.21-15.11s9.19-15.11,17.7-15.11,14.44,6.79,13.21,15.11S644.29,458,635.78,458h0Zm59.13,13.74h-14.8a1.75,1.75,0,0,1-1.81-2l13-82.36a2.55,2.55,0,0,1,2.46-2h14.8a1.75,1.75,0,0,1,1.81,2l-13,82.36A2.55,2.55,0,0,1,694.91,471.76Z" transform="translate(-143.48 -354.54)"/>
<path class="cls-2" d="M168.72,354.54h38.78c10.92,0,23.88.35,32.54,8,5.79,5.11,8.83,13.24,8.13,22-2.38,29.61-20.09,46.2-43.85,46.2H185.2c-3.26,0-5.41,2.16-6.33,8l-5.34,34c-0.35,2.2-1.3,3.5-3,3.66H146.6c-2.65,0-3.59-2-2.9-6.42L160.9,361C161.59,356.62,164,354.54,168.72,354.54Z" transform="translate(-143.48 -354.54)"/>
<path class="cls-3" d="M179.43,435.29l6.77-42.87c0.59-3.76,2.65-5.56,6.75-5.56h38.74c6.41,0,11.6,1,15.66,2.85-3.89,26.36-20.94,41-43.26,41H185C182.44,430.72,180.56,432,179.43,435.29Z" transform="translate(-143.48 -354.54)"/>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 3.4 KiB

View File

@@ -1,9 +1,9 @@
module.exports = {
clearMocks: true,
moduleFileExtensions: ['js', 'ts'],
testMatch: ['**/*.test.ts'],
moduleFileExtensions: ["js", "ts"],
testMatch: ["**/*.test.ts"],
transform: {
'^.+\\.ts$': 'ts-jest'
"^.+\\.ts$": "ts-jest",
},
verbose: true
}
verbose: true,
};

5839
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@@ -6,52 +6,40 @@
"main": "dist/index.js",
"scripts": {
"build": "tsc",
"format": "prettier --write '**/*.ts'",
"format-check": "prettier --check '**/*.ts'",
"lint": "eslint src/**/*.ts --fix",
"package": "ncc build -o dist/setup src/setup-uv.ts && ncc build -o dist/save-cache src/save-cache.ts && ncc build -o dist/update-default-version src/update-default-version.ts",
"format": "biome format --fix",
"format-check": "biome format",
"lint": "biome lint --fix",
"package": "ncc build -o dist/setup src/setup-uv.ts && ncc build -o dist/save-cache src/save-cache.ts && ncc build -o dist/update-known-checksums src/update-known-checksums.ts",
"test": "jest",
"act": "act pull_request -W .github/workflows/test.yml --container-architecture linux/amd64 -s GITHUB_TOKEN=\"$(gh auth token)\"",
"update-default-version": "node dist/update-default-version/index.js src/download/checksum/known-checksums.ts action.yml \"$(gh auth token)\"",
"update-known-checksums": "RUNNER_TEMP=known_checksums node dist/update-known-checksums/index.js src/download/checksum/known-checksums.ts \"$(gh auth token)\"",
"all": "npm run build && npm run format && npm run lint && npm run package && npm test"
},
"repository": {
"type": "git",
"url": "git+https://github.com/eifinger/setup-uv.git"
"url": "git+https://github.com/astral-sh/setup-uv.git"
},
"keywords": [
"actions",
"python",
"setup",
"uv"
],
"keywords": ["actions", "python", "setup", "uv"],
"author": "@eifinger",
"license": "MIT",
"dependencies": {
"@actions/cache": "^3.2.4",
"@actions/core": "^1.10.1",
"@actions/cache": "^3.3.0",
"@actions/core": "^1.11.1",
"@actions/exec": "^1.1.1",
"@actions/github": "^6.0.0",
"@actions/glob": "^0.4.0",
"@actions/glob": "^0.5.0",
"@actions/io": "^1.1.3",
"@actions/tool-cache": "^2.0.1",
"@octokit/rest": "^21.0.2"
},
"devDependencies": {
"@types/node": "^20.14.9",
"@biomejs/biome": "1.9.4",
"@types/node": "^22.9.1",
"@types/semver": "^7.5.8",
"@typescript-eslint/eslint-plugin": "^7.15.0",
"@typescript-eslint/parser": "^7.15.0",
"@vercel/ncc": "^0.38.1",
"eslint": "^8.57.0",
"eslint-plugin-github": "^5.0.1",
"eslint-plugin-import": "^2.29.1",
"eslint-plugin-jest": "^28.6.0",
"eslint-plugin-prettier": "^5.2.1",
"@vercel/ncc": "^0.38.3",
"jest": "^29.7.0",
"js-yaml": "^4.1.0",
"prettier": "^3.3.3",
"ts-jest": "^29.2.5",
"typescript": "^5.4.5"
"typescript": "^5.6.3"
}
}

View File

@@ -1,65 +1,70 @@
import * as cache from '@actions/cache'
import * as glob from '@actions/glob'
import * as core from '@actions/core'
import path from 'path'
import {cacheDependencyGlob, cacheLocalPath, cacheSuffix} from '../utils/inputs'
import {getArch, getPlatform} from '../utils/platforms'
import * as cache from "@actions/cache";
import * as core from "@actions/core";
import {
cacheDependencyGlob,
cacheLocalPath,
cacheSuffix,
} from "../utils/inputs";
import { getArch, getPlatform } from "../utils/platforms";
import { hashFiles } from "../hash/hash-files";
export const STATE_CACHE_KEY = 'cache-key'
export const STATE_CACHE_MATCHED_KEY = 'cache-matched-key'
const CACHE_VERSION = '1'
export const STATE_CACHE_KEY = "cache-key";
export const STATE_CACHE_MATCHED_KEY = "cache-matched-key";
const CACHE_VERSION = "1";
export async function restoreCache(version: string): Promise<void> {
const cacheKey = await computeKeys(version)
const cacheKey = await computeKeys(version);
let matchedKey: string | undefined
let matchedKey: string | undefined;
core.info(
`Trying to restore uv cache from GitHub Actions cache with key: ${cacheKey}`
)
`Trying to restore uv cache from GitHub Actions cache with key: ${cacheKey}`,
);
try {
matchedKey = await cache.restoreCache([cacheLocalPath], cacheKey)
matchedKey = await cache.restoreCache([cacheLocalPath], cacheKey);
} catch (err) {
const message = (err as Error).message
core.warning(message)
core.setOutput('cache-hit', false)
return
const message = (err as Error).message;
core.warning(message);
core.setOutput("cache-hit", false);
return;
}
core.saveState(STATE_CACHE_KEY, cacheKey)
core.saveState(STATE_CACHE_KEY, cacheKey);
handleMatchResult(matchedKey, cacheKey)
handleMatchResult(matchedKey, cacheKey);
}
async function computeKeys(version: string): Promise<string> {
let cacheDependencyPathHash = '-'
if (cacheDependencyGlob !== '') {
const fullCacheDependencyGlob = `${process.env['GITHUB_WORKSPACE']}${path.sep}${cacheDependencyGlob}`
cacheDependencyPathHash += await glob.hashFiles(fullCacheDependencyGlob)
if (cacheDependencyPathHash === '-') {
let cacheDependencyPathHash = "-";
if (cacheDependencyGlob !== "") {
core.info(
`Searching files using cache dependency glob: ${cacheDependencyGlob.split("\n").join(",")}`,
);
cacheDependencyPathHash += await hashFiles(cacheDependencyGlob, true);
if (cacheDependencyPathHash === "-") {
throw new Error(
`No file in ${process.cwd()} matched to [${cacheDependencyGlob}], make sure you have checked out the target repository`
)
`No file matched to [${cacheDependencyGlob.split("\n").join(",")}], make sure you have checked out the target repository`,
);
}
} else {
cacheDependencyPathHash += 'no-dependency-glob'
cacheDependencyPathHash += "no-dependency-glob";
}
const suffix = cacheSuffix ? `-${cacheSuffix}` : ''
return `setup-uv-${CACHE_VERSION}-${getArch()}-${getPlatform()}-${version}${cacheDependencyPathHash}${suffix}`
const suffix = cacheSuffix ? `-${cacheSuffix}` : "";
return `setup-uv-${CACHE_VERSION}-${getArch()}-${getPlatform()}-${version}${cacheDependencyPathHash}${suffix}`;
}
function handleMatchResult(
matchedKey: string | undefined,
primaryKey: string
primaryKey: string,
): void {
if (!matchedKey) {
core.info(`No GitHub Actions cache found for key: ${primaryKey}`)
core.setOutput('cache-hit', false)
return
core.info(`No GitHub Actions cache found for key: ${primaryKey}`);
core.setOutput("cache-hit", false);
return;
}
core.saveState(STATE_CACHE_MATCHED_KEY, matchedKey)
core.saveState(STATE_CACHE_MATCHED_KEY, matchedKey);
core.info(
`uv cache restored from GitHub Actions cache with key: ${matchedKey}`
)
core.setOutput('cache-hit', true)
`uv cache restored from GitHub Actions cache with key: ${matchedKey}`,
);
core.setOutput("cache-hit", true);
}

View File

@@ -1,55 +1,57 @@
import * as fs from 'fs'
import * as crypto from 'crypto'
import * as fs from "node:fs";
import * as crypto from "node:crypto";
import * as core from '@actions/core'
import {KNOWN_CHECKSUMS} from './known-checksums'
import {Architecture, Platform} from '../../utils/platforms'
import * as core from "@actions/core";
import { KNOWN_CHECKSUMS } from "./known-checksums";
import type { Architecture, Platform } from "../../utils/platforms";
export async function validateChecksum(
checkSum: string | undefined,
downloadPath: string,
arch: Architecture,
platform: Platform,
version: string
version: string,
): Promise<void> {
let isValid = true
if (checkSum !== undefined && checkSum !== '') {
isValid = await validateFileCheckSum(downloadPath, checkSum)
let isValid: boolean | undefined = undefined;
if (checkSum !== undefined && checkSum !== "") {
isValid = await validateFileCheckSum(downloadPath, checkSum);
} else {
core.debug(`Checksum not provided. Checking known checksums.`)
const key = `${arch}-${platform}-${version}`
core.debug("Checksum not provided. Checking known checksums.");
const key = `${arch}-${platform}-${version}`;
if (key in KNOWN_CHECKSUMS) {
const knownChecksum = KNOWN_CHECKSUMS[`${arch}-${platform}-${version}`]
core.debug(`Checking checksum for ${arch}-${platform}-${version}.`)
isValid = await validateFileCheckSum(downloadPath, knownChecksum)
const knownChecksum = KNOWN_CHECKSUMS[`${arch}-${platform}-${version}`];
core.debug(`Checking checksum for ${arch}-${platform}-${version}.`);
isValid = await validateFileCheckSum(downloadPath, knownChecksum);
} else {
core.debug(`No known checksum found for ${key}.`)
core.debug(`No known checksum found for ${key}.`);
}
}
if (!isValid) {
throw new Error(`Checksum for ${downloadPath} did not match ${checkSum}.`)
if (isValid === false) {
throw new Error(`Checksum for ${downloadPath} did not match ${checkSum}.`);
}
if (isValid === true) {
core.debug(`Checksum for ${downloadPath} is valid.`);
}
core.debug(`Checksum for ${downloadPath} is valid.`)
}
async function validateFileCheckSum(
filePath: string,
expected: string
expected: string,
): Promise<boolean> {
return new Promise((resolve, reject) => {
const hash = crypto.createHash('sha256')
const stream = fs.createReadStream(filePath)
stream.on('error', err => reject(err))
stream.on('data', chunk => hash.update(chunk))
stream.on('end', () => {
const actual = hash.digest('hex')
resolve(actual === expected)
})
})
const hash = crypto.createHash("sha256");
const stream = fs.createReadStream(filePath);
stream.on("error", (err) => reject(err));
stream.on("data", (chunk) => hash.update(chunk));
stream.on("end", () => {
const actual = hash.digest("hex");
resolve(actual === expected);
});
});
}
export function isknownVersion(version: string): boolean {
const pattern = new RegExp(`^.*-.*-${version}$`)
return Object.keys(KNOWN_CHECKSUMS).some(key => pattern.test(key))
const pattern = new RegExp(`^.*-.*-${version}$`);
return Object.keys(KNOWN_CHECKSUMS).some((key) => pattern.test(key));
}

File diff suppressed because it is too large Load Diff

View File

@@ -1,39 +1,59 @@
import {promises as fs} from 'fs'
import * as tc from '@actions/tool-cache'
import { promises as fs } from "node:fs";
import * as tc from "@actions/tool-cache";
import { KNOWN_CHECKSUMS } from "./known-checksums";
export async function updateChecksums(
filePath: string,
downloadUrls: string[]
downloadUrls: string[],
): Promise<void> {
await fs.rm(filePath)
await fs.rm(filePath);
await fs.appendFile(
filePath,
'// AUTOGENERATED_DO_NOT_EDIT\nexport const KNOWN_CHECKSUMS: {[key: string]: string} = {\n'
)
let firstLine = true
"// AUTOGENERATED_DO_NOT_EDIT\nexport const KNOWN_CHECKSUMS: { [key: string]: string } = {\n",
);
let firstLine = true;
for (const downloadUrl of downloadUrls) {
const content = await downloadAssetContent(downloadUrl)
const checksum = content.split(' ')[0].trim()
const key = getKey(downloadUrl)
if (!firstLine) {
await fs.appendFile(filePath, ',\n')
const key = getKey(downloadUrl);
if (key === undefined) {
continue;
}
await fs.appendFile(filePath, ` '${key}':\n '${checksum}'`)
firstLine = false
const checksum = await getOrDownloadChecksum(key, downloadUrl);
if (!firstLine) {
await fs.appendFile(filePath, ",\n");
}
await fs.appendFile(filePath, ` "${key}":\n "${checksum}"`);
firstLine = false;
}
await fs.appendFile(filePath, '}\n')
await fs.appendFile(filePath, ",\n};\n");
}
function getKey(downloadUrl: string): string {
function getKey(downloadUrl: string): string | undefined {
// https://github.com/astral-sh/uv/releases/download/0.3.2/uv-aarch64-apple-darwin.tar.gz.sha256
const parts = downloadUrl.split('/')
const fileName = parts[parts.length - 1]
const name = fileName.split('.')[0].split('uv-')[1]
const version = parts[parts.length - 2]
return `${name}-${version}`
const parts = downloadUrl.split("/");
const fileName = parts[parts.length - 1];
if (fileName.startsWith("source")) {
return undefined;
}
const name = fileName.split(".")[0].split("uv-")[1];
const version = parts[parts.length - 2];
return `${name}-${version}`;
}
async function getOrDownloadChecksum(
key: string,
downloadUrl: string,
): Promise<string> {
let checksum = "";
if (key in KNOWN_CHECKSUMS) {
checksum = KNOWN_CHECKSUMS[key];
} else {
const content = await downloadAssetContent(downloadUrl);
checksum = content.split(" ")[0].trim();
}
return checksum;
}
async function downloadAssetContent(downloadUrl: string): Promise<string> {
const downloadPath = await tc.downloadTool(downloadUrl)
const content = await fs.readFile(downloadPath, 'utf8')
return content
const downloadPath = await tc.downloadTool(downloadUrl);
const content = await fs.readFile(downloadPath, "utf8");
return content;
}

View File

@@ -1,66 +0,0 @@
import * as core from '@actions/core'
import * as tc from '@actions/tool-cache'
import * as exec from '@actions/exec'
import * as path from 'path'
import {Architecture, Platform} from '../utils/platforms'
import {validateChecksum} from './checksum/checksum'
import {OWNER, REPO, TOOL_CACHE_NAME} from '../utils/utils'
export async function downloadLatest(
platform: Platform,
arch: Architecture,
checkSum: string | undefined,
githubToken: string | undefined
): Promise<{cachedToolDir: string; version: string}> {
const artifact = `uv-${arch}-${platform}`
let downloadUrl = `https://github.com/${OWNER}/${REPO}/releases/latest/download/${artifact}`
if (platform === 'pc-windows-msvc') {
downloadUrl += '.zip'
} else {
downloadUrl += '.tar.gz'
}
core.info(`Downloading uv from "${downloadUrl}" ...`)
const downloadPath = await tc.downloadTool(
downloadUrl,
undefined,
githubToken
)
let uvExecutablePath: string
let uvDir: string
if (platform === 'pc-windows-msvc') {
uvDir = await tc.extractZip(downloadPath)
// On windows extracting the zip does not create an intermediate directory
uvExecutablePath = path.join(uvDir, 'uv.exe')
} else {
const extractedDir = await tc.extractTar(downloadPath)
uvDir = path.join(extractedDir, artifact)
uvExecutablePath = path.join(uvDir, 'uv')
}
const version = await getVersion(uvExecutablePath)
await validateChecksum(checkSum, downloadPath, arch, platform, version)
const cachedToolDir = await tc.cacheDir(uvDir, TOOL_CACHE_NAME, version, arch)
return {cachedToolDir, version}
}
async function getVersion(uvExecutablePath: string): Promise<string> {
// Parse the output of `uv --version` to get the version
// The output looks like
// uv 0.3.1 (be17d132a 2024-08-21)
const options: exec.ExecOptions = {
silent: !core.isDebug()
}
const execArgs = ['--version']
let output = ''
options.listeners = {
stdout: (data: Buffer) => {
output += data.toString()
}
}
await exec.exec(uvExecutablePath, execArgs, options)
const parts = output.split(' ')
return parts[1]
}

View File

@@ -1,18 +1,25 @@
import * as core from '@actions/core'
import * as tc from '@actions/tool-cache'
import * as path from 'path'
import {OWNER, REPO, TOOL_CACHE_NAME} from '../utils/utils'
import {Architecture, Platform} from '../utils/platforms'
import {validateChecksum} from './checksum/checksum'
import * as core from "@actions/core";
import * as tc from "@actions/tool-cache";
import * as path from "node:path";
import { promises as fs } from "node:fs";
import { OWNER, REPO, TOOL_CACHE_NAME } from "../utils/constants";
import type { Architecture, Platform } from "../utils/platforms";
import { validateChecksum } from "./checksum/checksum";
import * as github from "@actions/github";
export function tryGetFromToolCache(
arch: Architecture,
version: string
): string | undefined {
core.debug(`Trying to get uv from tool cache for ${version}...`)
const cachedVersions = tc.findAllVersions(TOOL_CACHE_NAME, arch)
core.debug(`Cached versions: ${cachedVersions}`)
return tc.find(TOOL_CACHE_NAME, version, arch)
version: string,
): { version: string; installedPath: string | undefined } {
core.debug(`Trying to get uv from tool cache for ${version}...`);
const cachedVersions = tc.findAllVersions(TOOL_CACHE_NAME, arch);
core.debug(`Cached versions: ${cachedVersions}`);
let resolvedVersion = tc.evaluateVersions(cachedVersions, version);
if (resolvedVersion === "") {
resolvedVersion = version;
}
const installedPath = tc.find(TOOL_CACHE_NAME, resolvedVersion, arch);
return { version: resolvedVersion, installedPath };
}
export async function downloadVersion(
@@ -20,32 +27,89 @@ export async function downloadVersion(
arch: Architecture,
version: string,
checkSum: string | undefined,
githubToken: string | undefined
): Promise<string> {
const artifact = `uv-${arch}-${platform}`
let downloadUrl = `https://github.com/${OWNER}/${REPO}/releases/download/${version}/${artifact}`
if (platform === 'pc-windows-msvc') {
downloadUrl += '.zip'
} else {
downloadUrl += '.tar.gz'
githubToken: string,
): Promise<{ version: string; cachedToolDir: string }> {
const resolvedVersion = await resolveVersion(version, githubToken);
const artifact = `uv-${arch}-${platform}`;
let extension = ".tar.gz";
if (platform === "pc-windows-msvc") {
extension = ".zip";
}
core.info(`Downloading uv from "${downloadUrl}" ...`)
const downloadUrl = `https://github.com/${OWNER}/${REPO}/releases/download/${resolvedVersion}/${artifact}${extension}`;
core.info(`Downloading uv from "${downloadUrl}" ...`);
const downloadPath = await tc.downloadTool(
downloadUrl,
undefined,
githubToken
)
await validateChecksum(checkSum, downloadPath, arch, platform, version)
githubToken,
);
await validateChecksum(
checkSum,
downloadPath,
arch,
platform,
resolvedVersion,
);
let uvDir: string
if (platform === 'pc-windows-msvc') {
uvDir = await tc.extractZip(downloadPath)
let uvDir: string;
if (platform === "pc-windows-msvc") {
const fullPathWithExtension = `${downloadPath}${extension}`;
await fs.copyFile(downloadPath, fullPathWithExtension);
uvDir = await tc.extractZip(fullPathWithExtension);
// On windows extracting the zip does not create an intermediate directory
} else {
const extractedDir = await tc.extractTar(downloadPath)
uvDir = path.join(extractedDir, artifact)
const extractedDir = await tc.extractTar(downloadPath);
uvDir = path.join(extractedDir, artifact);
}
return await tc.cacheDir(uvDir, TOOL_CACHE_NAME, version, arch)
const cachedToolDir = await tc.cacheDir(
uvDir,
TOOL_CACHE_NAME,
resolvedVersion,
arch,
);
return { version: resolvedVersion, cachedToolDir };
}
export async function resolveVersion(
versionInput: string,
githubToken: string,
): Promise<string> {
const version =
versionInput === "latest"
? await getLatestVersion(githubToken)
: versionInput;
if (tc.isExplicitVersion(version)) {
core.debug(`Version ${version} is an explicit version.`);
return version;
}
const availableVersions = await getAvailableVersions(githubToken);
const resolvedVersion = tc.evaluateVersions(availableVersions, version);
if (resolvedVersion === "") {
throw new Error(`No version found for ${version}`);
}
return resolvedVersion;
}
async function getAvailableVersions(githubToken: string): Promise<string[]> {
const octokit = github.getOctokit(githubToken);
const response = await octokit.paginate(octokit.rest.repos.listReleases, {
owner: OWNER,
repo: REPO,
});
return response.map((release) => release.tag_name);
}
async function getLatestVersion(githubToken: string) {
const octokit = github.getOctokit(githubToken);
const { data: latestRelease } = await octokit.rest.repos.getLatestRelease({
owner: OWNER,
repo: REPO,
});
if (!latestRelease) {
throw new Error("Could not determine latest release.");
}
return latestRelease.tag_name;
}

48
src/hash/hash-files.ts Normal file
View File

@@ -0,0 +1,48 @@
import * as crypto from "node:crypto";
import * as core from "@actions/core";
import * as fs from "node:fs";
import * as stream from "node:stream";
import * as util from "node:util";
import { create } from "@actions/glob";
/**
* Hashes files matching the given glob pattern.
*
* Copied from https://github.com/actions/toolkit/blob/20ed2908f19538e9dfb66d8083f1171c0a50a87c/packages/glob/src/internal-hash-files.ts#L9-L49
* But supports hashing files outside the GITHUB_WORKSPACE.
* @param pattern The glob pattern to match files.
* @param verbose Whether to log the files being hashed.
*/
export async function hashFiles(
pattern: string,
verbose = false,
): Promise<string> {
const globber = await create(pattern);
let hasMatch = false;
const writeDelegate = verbose ? core.info : core.debug;
const result = crypto.createHash("sha256");
let count = 0;
for await (const file of globber.globGenerator()) {
writeDelegate(file);
if (fs.statSync(file).isDirectory()) {
writeDelegate(`Skip directory '${file}'.`);
continue;
}
const hash = crypto.createHash("sha256");
const pipeline = util.promisify(stream.pipeline);
await pipeline(fs.createReadStream(file), hash);
result.write(hash.digest());
count++;
if (!hasMatch) {
hasMatch = true;
}
}
result.end();
if (hasMatch) {
writeDelegate(`Found ${count} files to hash.`);
return result.digest("hex");
}
writeDelegate("No matches found for glob");
return "";
}

View File

@@ -1,49 +1,84 @@
import * as cache from '@actions/cache'
import * as core from '@actions/core'
import * as exec from '@actions/exec'
import {STATE_CACHE_MATCHED_KEY, STATE_CACHE_KEY} from './cache/restore-cache'
import {cacheLocalPath, enableCache} from './utils/inputs'
import * as cache from "@actions/cache";
import * as core from "@actions/core";
import * as exec from "@actions/exec";
import * as fs from "node:fs";
import {
STATE_CACHE_MATCHED_KEY,
STATE_CACHE_KEY,
} from "./cache/restore-cache";
import {
cacheLocalPath,
enableCache,
ignoreNothingToCache,
pruneCache as shouldPruneCache,
} from "./utils/inputs";
export async function run(): Promise<void> {
try {
if (enableCache) {
await saveCache()
await saveCache();
// node will stay alive if any promises are not resolved,
// which is a possibility if HTTP requests are dangling
// due to retries or timeouts. We know that if we got here
// that all promises that we care about have successfully
// resolved, so simply exit with success.
process.exit(0);
}
} catch (error) {
const err = error as Error
core.setFailed(err.message)
const err = error as Error;
core.setFailed(err.message);
}
process.exit(0)
}
async function saveCache(): Promise<void> {
const cacheKey = core.getState(STATE_CACHE_KEY)
const matchedKey = core.getState(STATE_CACHE_MATCHED_KEY)
const cacheKey = core.getState(STATE_CACHE_KEY);
const matchedKey = core.getState(STATE_CACHE_MATCHED_KEY);
if (!cacheKey) {
core.warning('Error retrieving cache key from state.')
return
} else if (matchedKey === cacheKey) {
core.info(`Cache hit occurred on key ${cacheKey}, not saving cache.`)
return
core.warning("Error retrieving cache key from state.");
return;
}
if (matchedKey === cacheKey) {
core.info(`Cache hit occurred on key ${cacheKey}, not saving cache.`);
return;
}
await pruneCache()
if (shouldPruneCache) {
await pruneCache();
}
core.info(`Saving cache path: ${cacheLocalPath}`)
await cache.saveCache([cacheLocalPath], cacheKey)
core.info(`cache saved with the key: ${cacheKey}`)
core.info(`Saving cache path: ${cacheLocalPath}`);
if (!fs.existsSync(cacheLocalPath) && !ignoreNothingToCache) {
throw new Error(
`Cache path ${cacheLocalPath} does not exist on disk. This likely indicates that there are no dependencies to cache. Consider disabling the cache input if it is not needed.`,
);
}
try {
await cache.saveCache([cacheLocalPath], cacheKey);
core.info(`cache saved with the key: ${cacheKey}`);
} catch (e) {
if (
e instanceof Error &&
e.message ===
"Path Validation Error: Path(s) specified in the action for caching do(es) not exist, hence no cache is being saved."
) {
core.info(
"No cacheable paths were found. Ignoring because ignore-nothing-to-save is enabled.",
);
} else {
throw e;
}
}
}
async function pruneCache(): Promise<void> {
const options: exec.ExecOptions = {
silent: !core.isDebug()
}
const execArgs = ['cache', 'prune', '--ci']
silent: !core.isDebug(),
};
const execArgs = ["cache", "prune", "--ci"];
core.info('Pruning cache...')
await exec.exec('uv', execArgs, options)
core.info("Pruning cache...");
await exec.exec("uv", execArgs, options);
}
run()
run();

View File

@@ -1,51 +1,65 @@
import * as core from '@actions/core'
import * as path from 'path'
import {downloadVersion, tryGetFromToolCache} from './download/download-version'
import {restoreCache} from './cache/restore-cache'
import * as core from "@actions/core";
import * as path from "node:path";
import {
downloadVersion,
tryGetFromToolCache,
resolveVersion,
} from "./download/download-version";
import { restoreCache } from "./cache/restore-cache";
import {downloadLatest} from './download/download-latest'
import {Architecture, getArch, getPlatform, Platform} from './utils/platforms'
import {
type Architecture,
getArch,
getPlatform,
type Platform,
} from "./utils/platforms";
import {
cacheLocalPath,
checkSum,
enableCache,
githubToken,
version
} from './utils/inputs'
pythonVersion,
toolBinDir,
toolDir,
version,
} from "./utils/inputs";
async function run(): Promise<void> {
const platform = getPlatform()
const arch = getArch()
const platform = getPlatform();
const arch = getArch();
try {
if (platform === undefined) {
throw new Error(`Unsupported platform: ${process.platform}`)
throw new Error(`Unsupported platform: ${process.platform}`);
}
if (arch === undefined) {
throw new Error(`Unsupported architecture: ${process.arch}`)
throw new Error(`Unsupported architecture: ${process.arch}`);
}
const setupResult = await setupUv(
platform,
arch,
version,
checkSum,
githubToken
)
githubToken,
);
addUvToPath(setupResult.uvDir)
core.setOutput('uv-version', version)
core.info(`Successfully installed uv version ${version}`)
addUvToPath(setupResult.uvDir);
addToolBinToPath();
setToolDir();
setupPython();
addMatchers();
setCacheDir(cacheLocalPath);
addMatchers()
setCacheDir(cacheLocalPath)
core.setOutput("uv-version", setupResult.version);
core.info(`Successfully installed uv version ${setupResult.version}`);
if (enableCache) {
await restoreCache(setupResult.version)
await restoreCache(setupResult.version);
}
process.exit(0);
} catch (err) {
core.setFailed((err as Error).message)
core.setFailed((err as Error).message);
}
process.exit(0)
}
async function setupUv(
@@ -53,47 +67,79 @@ async function setupUv(
arch: Architecture,
versionInput: string,
checkSum: string | undefined,
githubToken: string | undefined
): Promise<{uvDir: string; version: string}> {
let installedPath: string | undefined
let cachedToolDir: string
let version: string
if (versionInput === 'latest') {
const result = await downloadLatest(platform, arch, checkSum, githubToken)
version = result.version
cachedToolDir = result.cachedToolDir
} else {
version = versionInput
installedPath = tryGetFromToolCache(arch, versionInput)
if (installedPath) {
core.info(`Found uv in tool-cache for ${versionInput}`)
return {uvDir: installedPath, version}
}
cachedToolDir = await downloadVersion(
platform,
arch,
versionInput,
checkSum,
githubToken
)
githubToken: string,
): Promise<{ uvDir: string; version: string }> {
const resolvedVersion = await resolveVersion(versionInput, githubToken);
const toolCacheResult = tryGetFromToolCache(arch, resolvedVersion);
if (toolCacheResult.installedPath) {
core.info(`Found uv in tool-cache for ${toolCacheResult.version}`);
return {
uvDir: toolCacheResult.installedPath,
version: toolCacheResult.version,
};
}
return {uvDir: cachedToolDir, version}
const downloadVersionResult = await downloadVersion(
platform,
arch,
resolvedVersion,
checkSum,
githubToken,
);
return {
uvDir: downloadVersionResult.cachedToolDir,
version: downloadVersionResult.version,
};
}
function addUvToPath(cachedPath: string): void {
core.addPath(cachedPath)
core.info(`Added ${cachedPath} to the path`)
core.addPath(cachedPath);
core.info(`Added ${cachedPath} to the path`);
}
function addToolBinToPath(): void {
if (toolBinDir !== undefined) {
core.exportVariable("UV_TOOL_BIN_DIR", toolBinDir);
core.info(`Set UV_TOOL_BIN_DIR to ${toolBinDir}`);
core.addPath(toolBinDir);
core.info(`Added ${toolBinDir} to the path`);
} else {
if (process.env.XDG_BIN_HOME !== undefined) {
core.addPath(process.env.XDG_BIN_HOME);
core.info(`Added ${process.env.XDG_BIN_HOME} to the path`);
} else if (process.env.XDG_DATA_HOME !== undefined) {
core.addPath(`${process.env.XDG_DATA_HOME}/../bin`);
core.info(`Added ${process.env.XDG_DATA_HOME}/../bin to the path`);
} else {
core.addPath(`${process.env.HOME}/.local/bin`);
core.info(`Added ${process.env.HOME}/.local/bin to the path`);
}
}
}
function setToolDir(): void {
if (toolDir !== undefined) {
core.exportVariable("UV_TOOL_DIR", toolDir);
core.info(`Set UV_TOOL_DIR to ${toolDir}`);
}
}
function setupPython(): void {
if (pythonVersion !== "") {
core.exportVariable("UV_PYTHON", pythonVersion);
core.info(`Set UV_PYTHON to ${pythonVersion}`);
}
}
function setCacheDir(cacheLocalPath: string): void {
core.exportVariable('UV_CACHE_DIR', cacheLocalPath)
core.info(`Set UV_CACHE_DIR to ${cacheLocalPath}`)
core.exportVariable("UV_CACHE_DIR", cacheLocalPath);
core.info(`Set UV_CACHE_DIR to ${cacheLocalPath}`);
}
function addMatchers(): void {
const matchersPath = path.join(__dirname, `..${path.sep}..`, '.github')
core.info(`##[add-matcher]${path.join(matchersPath, 'python.json')}`)
const matchersPath = path.join(__dirname, `..${path.sep}..`, ".github");
core.info(`##[add-matcher]${path.join(matchersPath, "python.json")}`);
}
run()
run();

View File

@@ -1,65 +0,0 @@
import * as github from '@actions/github'
import * as core from '@actions/core'
import {OWNER, REPO} from './utils/utils'
import {createReadStream, promises as fs} from 'fs'
import * as readline from 'readline'
import * as semver from 'semver'
import {updateChecksums} from './download/checksum/update-known-checksums'
async function run(): Promise<void> {
const checksumFilePath = process.argv.slice(2)[0]
const defaultVersionFilePath = process.argv.slice(2)[1]
const github_token = process.argv.slice(2)[2]
const octokit = github.getOctokit(github_token)
const response = await octokit.paginate(octokit.rest.repos.listReleases, {
owner: OWNER,
repo: REPO
})
const downloadUrls: string[] = response.flatMap(release =>
release.assets
.filter(asset => asset.name.endsWith('.sha256'))
.map(asset => asset.browser_download_url)
)
await updateChecksums(checksumFilePath, downloadUrls)
const latestVersion = response
.map(release => release.tag_name)
.sort(semver.rcompare)[0]
core.setOutput('latest-version', latestVersion)
await updateDefaultVersion(defaultVersionFilePath, latestVersion)
}
async function updateDefaultVersion(
filePath: string,
latestVersion: string
): Promise<void> {
const fileStream = createReadStream(filePath)
const rl = readline.createInterface({
input: fileStream
})
let foundDescription = false
const lines = []
for await (let line of rl) {
if (
!foundDescription &&
line.includes("description: 'The version of uv to install'")
) {
foundDescription = true
} else if (foundDescription && line.includes('default: ')) {
line = line.replace(/'[^']*'/, `'${latestVersion}'`)
foundDescription = false
}
lines.push(line)
}
await fs.writeFile(filePath, lines.join('\n'))
}
run()

View File

@@ -0,0 +1,32 @@
import * as github from "@actions/github";
import * as core from "@actions/core";
import { OWNER, REPO } from "./utils/constants";
import * as semver from "semver";
import { updateChecksums } from "./download/checksum/update-known-checksums";
async function run(): Promise<void> {
const checksumFilePath = process.argv.slice(2)[0];
const github_token = process.argv.slice(2)[1];
const octokit = github.getOctokit(github_token);
const response = await octokit.paginate(octokit.rest.repos.listReleases, {
owner: OWNER,
repo: REPO,
});
const downloadUrls: string[] = response.flatMap((release) =>
release.assets
.filter((asset) => asset.name.endsWith(".sha256"))
.map((asset) => asset.browser_download_url),
);
await updateChecksums(checksumFilePath, downloadUrls);
const latestVersion = response
.map((release) => release.tag_name)
.sort(semver.rcompare)[0];
core.setOutput("latest-version", latestVersion);
}
run();

3
src/utils/constants.ts Normal file
View File

@@ -0,0 +1,3 @@
export const REPO = "uv";
export const OWNER = "astral-sh";
export const TOOL_CACHE_NAME = "uv";

View File

@@ -1,9 +1,68 @@
import * as core from '@actions/core'
import * as core from "@actions/core";
import path from "node:path";
export const version = core.getInput('version')
export const checkSum = core.getInput('checksum')
export const enableCache = core.getInput('enable-cache') === 'true'
export const cacheSuffix = core.getInput('cache-suffix') || ''
export const cacheLocalPath = core.getInput('cache-local-path')
export const githubToken = core.getInput('github-token')
export const cacheDependencyGlob = core.getInput('cache-dependency-glob')
export const version = core.getInput("version");
export const pythonVersion = core.getInput("python-version");
export const checkSum = core.getInput("checksum");
export const enableCache = core.getInput("enable-cache") === "true";
export const cacheSuffix = core.getInput("cache-suffix") || "";
export const cacheLocalPath = getCacheLocalPath();
export const cacheDependencyGlob = core.getInput("cache-dependency-glob");
export const pruneCache = core.getInput("prune-cache") === "true";
export const ignoreNothingToCache =
core.getInput("ignore-nothing-to-cache") === "true";
export const toolBinDir = getToolBinDir();
export const toolDir = getToolDir();
export const githubToken = core.getInput("github-token");
function getToolBinDir(): string | undefined {
const toolBinDirInput = core.getInput("tool-bin-dir");
if (toolBinDirInput !== "") {
return expandTilde(toolBinDirInput);
}
if (process.platform === "win32") {
if (process.env.RUNNER_TEMP !== undefined) {
return `${process.env.RUNNER_TEMP}${path.sep}uv-tool-bin-dir`;
}
throw Error(
"Could not determine UV_TOOL_BIN_DIR. Please make sure RUNNER_TEMP is set or provide the tool-bin-dir input",
);
}
return undefined;
}
function getToolDir(): string | undefined {
const toolDirInput = core.getInput("tool-dir");
if (toolDirInput !== "") {
return expandTilde(toolDirInput);
}
if (process.platform === "win32") {
if (process.env.RUNNER_TEMP !== undefined) {
return `${process.env.RUNNER_TEMP}${path.sep}uv-tool-dir`;
}
throw Error(
"Could not determine UV_TOOL_DIR. Please make sure RUNNER_TEMP is set or provide the tool-dir input",
);
}
return undefined;
}
function getCacheLocalPath(): string {
const cacheLocalPathInput = core.getInput("cache-local-path");
if (cacheLocalPathInput !== "") {
return expandTilde(cacheLocalPathInput);
}
if (process.env.RUNNER_TEMP !== undefined) {
return `${process.env.RUNNER_TEMP}${path.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",
);
}
function expandTilde(input: string): string {
if (input.startsWith("~")) {
return `${process.env.HOME}${input.substring(1)}`;
}
return input;
}

View File

@@ -1,33 +1,33 @@
export type Platform =
| 'unknown-linux-gnu'
| 'unknown-linux-musl'
| 'unknown-linux-musleabihf'
| 'apple-darwin'
| 'pc-windows-msvc'
export type Architecture = 'i686' | 'x86_64' | 'aarch64'
| "unknown-linux-gnu"
| "unknown-linux-musl"
| "unknown-linux-musleabihf"
| "apple-darwin"
| "pc-windows-msvc";
export type Architecture = "i686" | "x86_64" | "aarch64";
export function getArch(): Architecture | undefined {
const arch = process.arch
const archMapping: {[key: string]: Architecture} = {
ia32: 'i686',
x64: 'x86_64',
arm64: 'aarch64'
}
const arch = process.arch;
const archMapping: { [key: string]: Architecture } = {
ia32: "i686",
x64: "x86_64",
arm64: "aarch64",
};
if (arch in archMapping) {
return archMapping[arch]
return archMapping[arch];
}
}
export function getPlatform(): Platform | undefined {
const platform = process.platform
const platformMapping: {[key: string]: Platform} = {
linux: 'unknown-linux-gnu',
darwin: 'apple-darwin',
win32: 'pc-windows-msvc'
}
const platform = process.platform;
const platformMapping: { [key: string]: Platform } = {
linux: "unknown-linux-gnu",
darwin: "apple-darwin",
win32: "pc-windows-msvc",
};
if (platform in platformMapping) {
return platformMapping[platform]
return platformMapping[platform];
}
}

View File

@@ -1,3 +0,0 @@
export const REPO = 'uv'
export const OWNER = 'astral-sh'
export const TOOL_CACHE_NAME = 'uv'

View File

@@ -1,12 +1,12 @@
{
"compilerOptions": {
"target": "es6", /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017', 'ES2018', 'ES2019' or 'ESNEXT'. */
"module": "commonjs", /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', or 'ESNext'. */
"outDir": "./lib", /* Redirect output structure to the directory. */
"rootDir": "./src", /* Specify the root directory of input files. Use to control the output directory structure with --outDir. */
"strict": true, /* Enable all strict type-checking options. */
"noImplicitAny": true, /* Raise error on expressions and declarations with an implied 'any' type. */
"esModuleInterop": true /* Enables emit interoperability between CommonJS and ES Modules via creation of namespace objects for all imports. Implies 'allowSyntheticDefaultImports'. */
"target": "es6" /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017', 'ES2018', 'ES2019' or 'ESNEXT'. */,
"module": "commonjs" /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', or 'ESNext'. */,
"outDir": "./lib" /* Redirect output structure to the directory. */,
"rootDir": "./src" /* Specify the root directory of input files. Use to control the output directory structure with --outDir. */,
"strict": true /* Enable all strict type-checking options. */,
"noImplicitAny": true /* Raise error on expressions and declarations with an implied 'any' type. */,
"esModuleInterop": true /* Enables emit interoperability between CommonJS and ES Modules via creation of namespace objects for all imports. Implies 'allowSyntheticDefaultImports'. */
},
"exclude": ["node_modules", "**/*.test.ts"]
}