fix: remove setup.py version bump that pushes to protected main #539
Workflow file for this run
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: Pull Request | |
| permissions: | |
| contents: read | |
| pages: write | |
| id-token: write | |
| pull-requests: write | |
| issues: write | |
| concurrency: | |
| group: "pr-${{ github.event.pull_request.number }}" | |
| cancel-in-progress: true | |
| on: | |
| pull_request: | |
| branches: [main, conda] | |
| types: [opened, synchronize, labeled] | |
| paths: | |
| - "projects/**" | |
| - "cli/**" | |
| - ".github/**" | |
| jobs: | |
| build-docs: | |
| name: Build PR Documentation | |
| uses: ./.github/workflows/build-docs-optimized.yml | |
| with: | |
| environment_name: ${{ github.head_ref }} | |
| deployment_type: pr | |
| permissions: | |
| contents: read | |
| pages: write | |
| id-token: write | |
| announce-url: | |
| name: Announce feature url | |
| runs-on: ubuntu-latest | |
| needs: build-docs | |
| steps: | |
| - name: Find Comment | |
| uses: peter-evans/find-comment@v2 | |
| id: fc | |
| with: | |
| issue-number: ${{ github.event.pull_request.number }} | |
| comment-author: "github-actions[bot]" | |
| body-includes: PR Documentation Deployed | |
| - name: Create or update comment | |
| uses: peter-evans/create-or-update-comment@v3 | |
| with: | |
| comment-id: ${{ steps.fc.outputs.comment-id }} | |
| issue-number: ${{ github.event.pull_request.number }} | |
| edit-mode: replace | |
| body: | | |
| ## 📚 PR Documentation Deployed | |
| Your PR documentation is available with enhanced build performance: | |
| **🔗 PR Documentation:** ${{ needs.build-docs.outputs.deploy-url }}${{ github.head_ref }}/ | |
| **🔗 Individual Projects:** Available at ${{ needs.build-docs.outputs.deploy-url }}${{ github.head_ref }}/[project-name]/ | |
| **✨ Performance Features:** | |
| - ⚡ Parallel builds (4x faster) | |
| - 💾 Intelligent caching | |
| - 🏗️ Optimized Sphinx configuration | |
| - 📊 Build statistics included | |
| **Version:** `${{ needs.build-docs.outputs.version }}` | |
| reactions: rocket | |
| notify-discord-pr: | |
| name: Notify Discord (open PR) | |
| runs-on: ubuntu-latest | |
| needs: [build-docs] | |
| if: github.event.action == 'opened' | |
| steps: | |
| - name: Check out repository | |
| uses: actions/checkout@v4 | |
| - name: Notify open PR | |
| env: | |
| CONTENT_TITLE: "Nýtt PR opnað" | |
| TITLE: ${{ github.event.pull_request.title }} | |
| COLOR: "2061822" | |
| DESCRIPTION: ${{ github.event.pull_request.body }} | |
| URL: ${{ github.event.pull_request.html_url }} | |
| AUTHOR_NAME: ${{ github.event.pull_request.user.login }} | |
| AUTHOR_URL: ${{ github.event.pull_request.user.html_url }} | |
| AUTHOR_AVATAR: ${{ github.event.pull_request.user.avatar_url }} | |
| BRANCH: ${{ github.head_ref }} | |
| DEPLOY_URL: ${{ needs.build-docs.outputs.deploy-url }} | |
| run: | | |
| payload="$(jq -n \ | |
| --arg ct "$CONTENT_TITLE" \ | |
| --arg title "$TITLE" \ | |
| --arg desc "$DESCRIPTION" \ | |
| --arg url "$URL" \ | |
| --arg author_name "$AUTHOR_NAME" \ | |
| --arg author_url "$AUTHOR_URL" \ | |
| --arg author_avatar "$AUTHOR_AVATAR" \ | |
| --arg branch "$BRANCH" \ | |
| --arg deploy_url "$DEPLOY_URL" \ | |
| --argjson color "$COLOR" \ | |
| '{ | |
| content: $ct, | |
| avatar_url: "https://www.shareicon.net/data/128x128/2015/08/28/92005_social-media_512x512.png", | |
| embeds: [ | |
| { | |
| title: $title, | |
| description: $desc, | |
| url: $url, | |
| color: $color, | |
| fields: [ | |
| { name: "Build Performance", value: "⚡ Parallel builds enabled" }, | |
| { name: "url", value: ("[Skoða á edbook](" + $deploy_url + $branch + ")") } | |
| ], | |
| author: { name: $author_name, url: $author_url, icon_url: $author_avatar } | |
| } | |
| ] | |
| }')" | |
| ./.github/discord.sh \ | |
| -w "${{ secrets.DISCORD_WEBHOOK }}" \ | |
| -c "$payload" |