You're viewing an older version of this GitHub Action. Do you want to see the latest version instead?
GitHub Action
cffconvert
1.1.1
GitHub action to check consistency of CITATION.cff
and .zenodo.json
citation metadata.
Description | Badge |
---|---|
Check consistency of the citation metadata | |
Verify that errors are generated for various incorrect cases |
-
Save the following snippet as
.github/workflows/cffconvert.yml
name: cffconvert on: push jobs: verify: name: "cffconvert" runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 name: Check out a copy of the repository - uses: citation-file-format/cffconvert-github-action@1.1.1 name: Check whether the citation metadata from CITATION.cff is equivalent to that in .zenodo.json
-
git add
,commit
andpush
to GitHub -
Check the Actions tab on your repository's page to check the action's output
DIFF_IGNORE_WHITESPACE
: Ignore all whitespace whendiff
'ing the expected.zenodo.json
contents with the actual.zenodo.json
contents.FAILURE_EXPECTED
: In testing, it can be useful to flip the exit codes for failure and success. Set to '1' for flipped definition; '0' or empty gives normal behavior.'WORKDIR
: The working directory thatchecks.sh
should change to before verifying whetherCITATION.cff
and.zenodo.json
are equivalent.
Example workflow file:
name: cffconvert
on: push
jobs:
verify:
name: "cffconvert"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
name: Check out a copy of the repository
- uses: citation-file-format/cffconvert-github-action@1.1.1
name: Check whether the citation metadata from CITATION.cff is equivalent to that in .zenodo.json
with:
WORKDIR: tests/zenodo-missing/
FAILURE_EXPECTED: true
DIFF_IGNORE_WHITESPACE: true