mirror of
https://github.com/julia-actions/cache.git
synced 2026-02-12 09:26:53 +08:00
Documentation consistency fixes (#84)
* Consistent use of periods * Consistent casing of GitHub * Use 2-space indentation for YAML example * Add links to for further details
This commit is contained in:
12
README.md
12
README.md
@@ -47,8 +47,8 @@ However note that caching the registries may mean that the registry will not be
|
||||
- `cache-compiled` - Whether to cache `~/.julia/compiled/`. Defaults to `true`.
|
||||
- `cache-scratchspaces` - Whether to cache `~/.julia/scratchspaces/`. Defaults to `true`.
|
||||
- `cache-logs` - Whether to cache `~/.julia/logs/`. Defaults to `true`. Helps auto-`Pkg.gc()` keep the cache small.
|
||||
- `delete-old-caches` - Whether to delete old caches for the given key. Defaults to `true`
|
||||
- `token` - A github PAT. Defaults to `github.token`. Requires `repo` scope to enable the deletion of old caches.
|
||||
- `delete-old-caches` - Whether to delete old caches for the given key. Defaults to `true`.
|
||||
- `token` - A [GitHub PAT](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/managing-your-personal-access-tokens). Defaults to `github.token`. Requires `repo` scope to enable the deletion of old caches.
|
||||
|
||||
### Outputs
|
||||
|
||||
@@ -82,13 +82,13 @@ This action automatically deletes old caches that match the first 4 fields of th
|
||||
- All variables in the `matrix` (unless disabled via `include-matrix: 'false'`)
|
||||
- The `runner.os` (may be in the matrix too, but included for safety)
|
||||
|
||||
Which means your caches files will not grow needlessly. Github also deletes cache files after
|
||||
Which means your caches files will not grow needlessly. GitHub also deletes cache files after
|
||||
[90 days which can be increased in private repos to up to 400 days](https://docs.github.com/en/organizations/managing-organization-settings/configuring-the-retention-period-for-github-actions-artifacts-and-logs-in-your-organization)
|
||||
|
||||
> [!NOTE]
|
||||
> To allow deletion of caches you will likely need to grant the following to the default
|
||||
> `GITHUB_TOKEN` by adding this to your yml:
|
||||
> ```
|
||||
> To allow deletion of caches you will likely need to [grant the following permissions](https://docs.github.com/en/actions/using-jobs/assigning-permissions-to-jobs)
|
||||
> to the `GITHUB_TOKEN` by adding this to your GitHub actions workflow:
|
||||
> ```yaml
|
||||
> permissions:
|
||||
> actions: write
|
||||
> contents: read
|
||||
|
||||
18
action.yml
18
action.yml
@@ -11,31 +11,31 @@ inputs:
|
||||
description: 'The cache key prefix. Unless disabled the key body automatically includes matrix vars, and the OS. Include any other parameters/details in this prefix to ensure one unique cache key per concurrent job type.'
|
||||
default: 'julia-cache-${{ github.workflow }}-${{ github.job }}'
|
||||
include-matrix:
|
||||
description: 'Whether to include the matrix values when constructing the cache key'
|
||||
description: 'Whether to include the matrix values when constructing the cache key.'
|
||||
default: 'true'
|
||||
cache-artifacts:
|
||||
description: 'Whether to cache ~/.julia/artifacts/'
|
||||
description: 'Whether to cache ~/.julia/artifacts/.'
|
||||
default: 'true'
|
||||
cache-packages:
|
||||
description: 'Whether to cache ~/.julia/packages/'
|
||||
description: 'Whether to cache ~/.julia/packages/.'
|
||||
default: 'true'
|
||||
cache-registries:
|
||||
description: 'Whether to cache ~/.julia/registries/. This is off by default to ensure CI gets latest versions'
|
||||
description: 'Whether to cache ~/.julia/registries/. This is off by default to ensure CI gets latest versions.'
|
||||
default: 'false'
|
||||
cache-compiled:
|
||||
description: 'Whether to cache ~/.julia/compiled/'
|
||||
description: 'Whether to cache ~/.julia/compiled/.'
|
||||
default: 'true'
|
||||
cache-scratchspaces:
|
||||
description: 'Whether to cache ~/.julia/scratchspaces/'
|
||||
description: 'Whether to cache ~/.julia/scratchspaces/.'
|
||||
default: 'true'
|
||||
cache-logs:
|
||||
description: 'Whether to cache ~/.julia/logs/. This helps automatic Pkg.gc() keep the cache size down'
|
||||
description: 'Whether to cache ~/.julia/logs/. This helps automatic Pkg.gc() keep the cache size down.'
|
||||
default: 'true'
|
||||
delete-old-caches:
|
||||
description: 'Whether to delete old caches for the given key'
|
||||
description: 'Whether to delete old caches for the given key.'
|
||||
default: 'true'
|
||||
token:
|
||||
description: 'A github PAT. Requires `repo` scope to enable the deletion of old caches'
|
||||
description: 'A GitHub PAT. Requires `repo` scope to enable the deletion of old caches.'
|
||||
default: '${{ github.token }}'
|
||||
|
||||
outputs:
|
||||
|
||||
Reference in New Issue
Block a user