Fetch new lexicons and regenerate code and docs #65
This file contains 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: Fetch new lexicons and regenerate code and docs | |
on: | |
workflow_dispatch: | |
schedule: | |
- cron: '0 12 * * 5' # at 12:00 on Friday day | |
permissions: | |
contents: read | |
jobs: | |
update_lexicons: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Run Cimon (eBPF). | |
uses: cycodelabs/cimon-action@v0 | |
with: | |
prevent: true | |
allowed-hosts: > | |
files.pythonhosted.org | |
install.python-poetry.org | |
pypi.org | |
- name: Checkout repository. | |
uses: actions/checkout@v4 | |
- name: Set up Python. | |
uses: actions/setup-python@v4 | |
with: | |
python-version: '3.8' | |
- name: Setup Poetry. | |
uses: snok/install-poetry@v1 | |
with: | |
version: 1.8.3 | |
- name: Install dependencies. | |
run: poetry install --no-interaction | |
- name: Update lexicons and regen. | |
run: | | |
source $(poetry env info -p)/bin/activate | |
echo "COMMIT_MESSAGE=$(python update_lexicons.py)" >> $GITHUB_ENV | |
- name: Create Pull Request. | |
uses: peter-evans/create-pull-request@v5 | |
with: | |
token: ${{ secrets.PAT }} | |
committer: Ilya (Marshal) <[email protected]> | |
author: Ilya (Marshal) <[email protected]> | |
commit-message: ${{ env.COMMIT_MESSAGE }} | |
body: This PR was automatically generated | |
base: main | |
branch: update-lexicons | |
title: ${{ env.COMMIT_MESSAGE }} | |
assignees: MarshalX |