Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 27 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,13 @@ A GitHub Action to delete caches from Blacksmith's cache storage. This action al

## Inputs

| Input | Description | Required |
| --------- | --------------------------------------- | -------- |
| `key` | The cache key to delete | Yes |
| `version` | Specific version of the cache to delete | No |
| Input | Description | Required | Default |
| --------- | --------------------------------------- | -------- | ------- |
| `key` | The cache key to delete | No\* | - |
| `version` | Specific version of the cache to delete | No | - |
| `prefix` | Treat key as a prefix for bulk deletion | No | false |

\* Required unless `prefix` is true, in which case it can be empty to match all cache keys

## Examples

Expand All @@ -40,6 +43,26 @@ A GitHub Action to delete caches from Blacksmith's cache storage. This action al
version: v1.0
```

### Delete All Caches with a Prefix

```yaml
- name: Delete All npm Caches
uses: useblacksmith/cache-delete@v1
with:
key: npm-
prefix: true
```

### Delete All Caches

```yaml
- name: Delete All Caches
uses: useblacksmith/cache-delete@v1
with:
key: ""
prefix: true
```

## Error Handling

The action will:
Expand Down
Loading