Generate CITATION.cff after push by wannaphong #26
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # SPDX-FileCopyrightText: 2026 PyThaiNLP Project | |
| # SPDX-License-Identifier: Apache-2.0 | |
| # SPDX-FileType: SOURCE | |
| # Generate CITATION.cff from codemeta.json | |
| name: Generate CITATION.cff | |
| run-name: Generate CITATION.cff after ${{github.event_name}} by ${{github.actor}} | |
| on: | |
| push: | |
| paths: | |
| - "codemeta.json" | |
| workflow_dispatch: | |
| inputs: | |
| reason: | |
| description: "Reason for manual trigger" | |
| required: false | |
| default: "Manual trigger" | |
| jobs: | |
| generate-and-validate: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: write | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v7.0.0 | |
| - name: Generate CITATION.cff from codemeta.json | |
| uses: caltechlibrary/codemeta2cff@99ce10831c3037a067c3d9551d455638e0b438ac #v0.3.3 | |
| - name: Show generated CITATION.cff | |
| run: | | |
| printf '```yaml\n' >> $GITHUB_STEP_SUMMARY | |
| cat CITATION.cff >> $GITHUB_STEP_SUMMARY | |
| printf '\n```' >> $GITHUB_STEP_SUMMARY | |
| - name: Validate CITATION.cff | |
| uses: dieghernan/cff-validator@d8f85828214016ce6976e740b6e0504c0fdc4dbb #v5.1.1 | |
| - name: Commit and push updated CITATION.cff | |
| uses: EndBug/add-and-commit@290ea2c423ad77ca9c62ae0f5b224379612c0321 #v10.0.0 | |
| with: | |
| message: "Update CITATION.cff from codemeta.json" | |
| add: "CITATION.cff" |