Repository navigation
feat: allow task caching to github #126
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
0a9943a
fe6e618
0967e73
95021e2
943c89c
6051865
0f61b1c
7b7d992
f4d4268
a12e69a
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -41,6 +41,14 @@ inputs: | |
| description: "Enable caching of project dependencies" | ||
| required: false | ||
| default: "false" | ||
| task-cache: | ||
| description: "Enable task caching via GitHub Actions. Restores node_modules/.vite/task-cache from a previous run and saves it again in the post action (see task-cache-save). Independent of cache." | ||
| required: false | ||
| default: "false" | ||
|
Comment on lines
+44
to
+47
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
The new input and output are absent from the public interface documentation: the Inputs table at Useful? React with 👍 / 👎. |
||
| task-cache-save: | ||
| description: "Whether to save the task cache in the post action. Has no effect when task-cache is false." | ||
| required: false | ||
| default: "true" | ||
| cache-save: | ||
| description: "Whether to save the dependency cache in the post action. Has no effect when cache is false." | ||
| required: false | ||
|
|
@@ -60,6 +68,8 @@ outputs: | |
| description: "The installed version of Vite+" | ||
| cache-hit: | ||
| description: "Boolean indicating if cache was restored" | ||
| task-cache-hit: | ||
| description: "Boolean indicating if task cache was restored" | ||
|
|
||
| runs: | ||
| using: node24 | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@KTrain5169 can you add a new test job for this new feature at https://github.com/voidzero-dev/setup-vp/blob/main/.github/workflows/test.yml ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure what I'm supposed to test here, is it just trying to save and restore using the setup-vp action vs the regualr cache action?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
At minimum, we need to verify cache hit, and then the cache stale logic after changes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Alright. I also notice that the normal cache has an option to not save to cache. Do we want the equivalent added to task cache?