Update Keygen Output #285
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
| name: Update Keygen Output | |
| on: | |
| schedule: | |
| - cron: '5 * * * *' | |
| workflow_dispatch: | |
| permissions: | |
| contents: write | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v3 | |
| with: | |
| ref: key-gen | |
| - name: Setup Node.js environment | |
| uses: actions/setup-node@v6.5.0 | |
| - name: Set up python | |
| id: setup-python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.11' | |
| - name: Install Poetry | |
| uses: snok/install-poetry@v1 | |
| with: | |
| virtualenvs-create: true | |
| virtualenvs-in-project: true | |
| installer-parallel: true | |
| - name: Poetry Install | |
| working-directory: scripts/keygen | |
| run: | | |
| poetry install | |
| - name: Keygen | |
| working-directory: scripts/keygen | |
| run: | | |
| poetry run python ./keygen.py | |
| - name: Commit generated JSON | |
| run: | | |
| git config --global user.name "github-actions" | |
| git config --global user.email "github-actions@github.com" | |
| git add scripts/keygen/keygen.json | |
| git commit -m "ci: update generated keygen.json" || exit 0 | |
| git push | |