https://github.com/yasu89/gocredits-action
GitHub Actions for gocredits
https://github.com/yasu89/gocredits-action
actions go
Last synced: about 2 months ago
JSON representation
GitHub Actions for gocredits
- Host: GitHub
- URL: https://github.com/yasu89/gocredits-action
- Owner: yasu89
- License: mit
- Created: 2025-05-03T10:51:21.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2025-05-26T02:02:54.000Z (about 1 year ago)
- Last Synced: 2025-07-05T01:38:46.243Z (12 months ago)
- Topics: actions, go
- Homepage:
- Size: 38.1 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
Awesome Lists containing this project
README
# gocredits-action
GitHub Action for [Songmu/gocredits](https://github.com/Songmu/gocredits)
# Usage
## Check credits file
Configuration to fail the Actions workflow if there are differences in the CREDITS file output by gocredits.
```yaml
# .github/workflows/gocredits.yml
name: gocredits
on:
push:
branches:
- main
pull_request:
jobs:
gocredits:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: actions/setup-go@0aaccfd150d50ccaeb58ebd88d36e91967a5f35b # v5.4.0
with:
go-version-file: go.mod
- name: Install dependencies
shell: bash
run: go mod tidy
- uses: yasu89/gocredits-action@73d842e143bb323deffee6af1773db3edc7a8ba4 # v1.1.0
```
## Update credits file
Configuration to update and commit the CREDITS file if there are differences in the CREDITS file output by gocredits.
```yaml
# .github/workflows/gocredits.yml
name: gocredits
on:
push:
branches:
- main
pull_request:
jobs:
gocredits:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: actions/setup-go@0aaccfd150d50ccaeb58ebd88d36e91967a5f35b # v5.4.0
with:
go-version-file: go.mod
- name: Install dependencies
shell: bash
run: go mod tidy
- uses: yasu89/gocredits-action@73d842e143bb323deffee6af1773db3edc7a8ba4 # v1.1.0
with:
mode: 'update'
```
See [action.yml](https://github.com/yasu89/gocredits-action/blob/main/action.yml) for more details on how to configure it.