Skip to content

Commit

Permalink
2.2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
Swatinem committed Nov 9, 2022
1 parent ecee04e commit 359a70e
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 4 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog

## 2.2.0

- Add new `save-if` option to always restore, but only conditionally save the cache.

## 2.1.0

- Only hash `Cargo.{lock,toml}` files in the configured workspace directories.
Expand Down
3 changes: 2 additions & 1 deletion dist/save/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -64922,7 +64922,8 @@ process.on("uncaughtException", (e) => {
}
});
async function run() {
if (!cache.isFeatureAvailable()) {
const save = core.getInput("save-if").toLowerCase() || "true";
if (!(cache.isFeatureAvailable() && save === "true")) {
return;
}
try {
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"private": true,
"name": "rust-cache",
"version": "2.1.0",
"version": "2.2.0",
"description": "A GitHub Action that implements smart caching for rust/cargo projects with sensible defaults.",
"keywords": [
"actions",
Expand Down

0 comments on commit 359a70e

Please sign in to comment.