CrowdCode - Branch Visibility #7
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: CrowdCode - Branch Visibility | |
| on: | |
| push: | |
| branches: | |
| - 'crowdcode/feature-*' | |
| pull_request: | |
| types: [opened, closed, reopened] | |
| schedule: | |
| - cron: '0 0 * * 0' # Weekly on Sunday | |
| workflow_dispatch: | |
| permissions: | |
| contents: write | |
| jobs: | |
| update-dashboard: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 # Need all branches | |
| - name: Setup Python | |
| uses: actions/setup-python@v4 | |
| with: | |
| python-version: '3.11' | |
| - name: Install dependencies | |
| run: | | |
| pip install PyGithub pyyaml | |
| - name: Generate Feature Dashboard | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| GITHUB_REPOSITORY: ${{ github.repository }} | |
| run: | | |
| mkdir -p docs/features | |
| python scripts/generate-dashboard.py | |
| - name: Commit Dashboard Updates | |
| run: | | |
| git config user.name "github-actions[bot]" | |
| git config user.email "github-actions[bot]@users.noreply.github.com" | |
| git add docs/features/ | |
| if git diff --staged --quiet; then | |
| echo "No changes to commit" | |
| else | |
| git commit -m "Update feature dashboard [skip ci]" | |
| git push | |
| fi | |
| - name: Summary | |
| run: | | |
| echo "## CrowdCode Branch Visibility Summary" >> $GITHUB_STEP_SUMMARY | |
| echo "" >> $GITHUB_STEP_SUMMARY | |
| echo "Feature dashboard updated." >> $GITHUB_STEP_SUMMARY |