mirror of
https://hub.psychoinformatics.de/actions/cache-git-credential.git
synced 2026-10-06 17:06:18 +00:00
38 lines
1.2 KiB
Markdown
38 lines
1.2 KiB
Markdown
# Forgejo Action for caching a Git credential
|
|
|
|
Configures Git's credential cache with the supplied credentials, either
|
|
globally or for a specific repository.
|
|
|
|
The action is implemented such that it should also run on GitHub actions.
|
|
However, no attempt is made to verify this, and it is purely based on the
|
|
similarity of these two systems for the time being.
|
|
|
|
## Usage
|
|
|
|
```yaml
|
|
- name: Cache Git credential
|
|
uses: https://hub.psychoinformatics.de/actions/cache-git-credential@v1
|
|
```
|
|
|
|
## Parameters
|
|
|
|
The following optional parameters can be given via the `with` key. Example:
|
|
|
|
```yaml
|
|
- name: Cache Git credential
|
|
uses: https://hub.psychoinformatics.de/actions/cache-git-credential@v1
|
|
with:
|
|
repo: "aux/component1"
|
|
...
|
|
```
|
|
|
|
| Name | Default | Description |
|
|
|---|---|---|
|
|
| `username` | `${{ github.actor }}` | Username to store in Git's credential cache. |
|
|
| `password` | `${{ github.token }}` | Password or access token to store in Git's credential cache. |
|
|
| `url` | `${{ github.server_url }}` | Server URL associated with the credential. |
|
|
| `repo` | Empty | Path to the repository to configure locally. If omitted, the credential helper is configured globally. |
|
|
|
|
## License
|
|
|
|
MIT
|