Event Opportunity (Remote): Blackley Academy, Manchester, Dream Big Day – Primary Careers Event (Fri 26 June) #2107
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: Issues | |
| on: | |
| issues: | |
| types: [opened] | |
| issue_comment: | |
| types: [created, edited] | |
| schedule: | |
| - cron: "0 9 * * *" # Every day at 9am UTC. | |
| workflow_dispatch: | |
| inputs: | |
| job: | |
| description: Select the job you want to run. | |
| required: true | |
| type: choice | |
| options: | |
| - body | |
| - inactive | |
| workflow_call: | |
| secrets: | |
| CFL_APP_PRIVATE_KEY: | |
| description: "The private key of CFL's GitHub App." | |
| required: false | |
| env: | |
| REPO_NAME: ${{ github.event.repository.name }} | |
| WORKFLOW_REF: ocadotechnology/codeforlife-workspace/.github/workflows/issues.yaml@refs/heads/main | |
| jobs: | |
| body: | |
| runs-on: ubuntu-22.04 | |
| if: | | |
| github.repository_owner_id == 2088731 && ( | |
| ( | |
| github.repository_id == 610732754 && ( | |
| github.event_name == 'schedule' || ( | |
| github.event_name == 'workflow_dispatch' && | |
| inputs.job == 'body' | |
| ) | |
| ) | |
| ) || ( | |
| github.event_name == 'issues' && | |
| github.event.action == 'opened' && | |
| !contains(github.event.issue.user.login, '[bot]') && | |
| !contains(github.event.issue.labels.*.name, ':robot:') | |
| ) | |
| ) | |
| env: | |
| ISSUE_REPO_NAME: "${{ github.event.repository.name }}" | |
| ISSUE_NUMBER: "${{ github.event.issue.number }}" | |
| steps: | |
| - name: 🤖 Set up CFL bot | |
| uses: ocadotechnology/codeforlife-workspace/.github/actions/bot/setup@main | |
| id: setup-bot | |
| with: | |
| cfl-app-private-key: ${{ secrets.CFL_APP_PRIVATE_KEY }} | |
| - name: 🏃 Download and Run Job Script | |
| uses: ocadotechnology/codeforlife-workspace/.github/actions/workspace/run-job-script@main | |
| env: | |
| GH_TOKEN: ${{ steps.setup-bot.outputs.token }} | |
| with: | |
| workflow: "${{ env.WORKFLOW_REF }}" | |
| job: "body" | |
| prompt: | |
| runs-on: ubuntu-22.04 | |
| if: | | |
| github.repository_owner_id == 2088731 && | |
| github.event_name == 'issue_comment' && | |
| !github.event.issue.pull_request && | |
| contains(fromJSON('["created", "edited"]'), github.event.action) && | |
| !contains(github.event.comment.user.login, '[bot]') && | |
| !contains(github.event.issue.labels.*.name, ':robot:') | |
| env: | |
| # String variables. | |
| ISSUE_REPO_NAME: "${{ github.event.repository.name }}" | |
| ISSUE_NUMBER: "${{ github.event.issue.number }}" | |
| ISSUE_NODE_ID: "${{ github.event.issue.node_id }}" | |
| ISSUE_ASSIGNEES_LENGTH: "${{ github.event.issue.assignees.length }}" | |
| COMMENT_ID: "${{ github.event.comment.id }}" | |
| USER_NODE_ID: "${{ github.event.comment.user.node_id }}" | |
| USER_LOGIN: "${{ github.event.comment.user.login }}" | |
| # Boolean variables. | |
| ISSUE_IS_OPEN: "${{ github.event.issue.state == 'open' }}" | |
| ISSUE_HAS_COMMENTER_ASSIGNED: "${{ contains(github.event.issue.assignees.*.id, github.event.comment.user.id) }}" | |
| steps: | |
| - name: 🤖 Set up CFL bot | |
| uses: ocadotechnology/codeforlife-workspace/.github/actions/bot/setup@main | |
| id: setup-bot | |
| with: | |
| cfl-app-private-key: ${{ secrets.CFL_APP_PRIVATE_KEY }} | |
| - name: 🏃 Download and Run Job Script | |
| uses: ocadotechnology/codeforlife-workspace/.github/actions/workspace/run-job-script@main | |
| env: | |
| GH_TOKEN: ${{ steps.setup-bot.outputs.token }} | |
| with: | |
| workflow: "${{ env.WORKFLOW_REF }}" | |
| job: "prompt" | |
| inactive: | |
| runs-on: ubuntu-22.04 | |
| if: | | |
| github.repository_owner_id == 2088731 && | |
| github.repository_id == 610732754 && ( | |
| github.event_name == 'schedule' || ( | |
| github.event_name == 'workflow_dispatch' && | |
| inputs.job == 'inactive' | |
| ) | |
| ) | |
| env: | |
| REPO_NAME: ${{ github.event.repository.name }} | |
| steps: | |
| - name: 🤖 Set up CFL bot | |
| uses: ocadotechnology/codeforlife-workspace/.github/actions/bot/setup@main | |
| id: setup-bot | |
| with: | |
| cfl-app-private-key: ${{ secrets.CFL_APP_PRIVATE_KEY }} | |
| - name: 🏃 Download and Run Job Script | |
| uses: ocadotechnology/codeforlife-workspace/.github/actions/workspace/run-job-script@main | |
| env: | |
| GH_TOKEN: ${{ steps.setup-bot.outputs.token }} | |
| with: | |
| workflow: "${{ env.WORKFLOW_REF }}" | |
| job: "inactive" |