measure_workflows #594
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: measure_workflows | |
on: | |
push: | |
branches: | |
- main | |
schedule: | |
- cron: '0 0,6,12,18 * * *' | |
workflow_dispatch: | |
jobs: | |
measure_workflows: | |
runs-on: ubuntu-latest | |
permissions: | |
pages: write | |
id-token: write | |
actions: read | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.x' | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install requests numpy python-dxf | |
- name: Restore cache | |
uses: actions/cache@v4 | |
with: | |
path: cache | |
key: actions | |
- name: Execute script | |
run: | | |
mkdir -p cache | |
python scripts/measure_workflows.py --github_token ${{ github.token }} --github_actor ${{ github.actor }} | |
cp github_action_data.json public/ | |
- name: Upload Pages artifact | |
uses: actions/upload-pages-artifact@v3 | |
with: | |
path: public/ | |
- name: Publish | |
uses: actions/deploy-pages@v4 |