XS ◾ ✏️ Update rule - Do you know how to speak up in meetings? (#9872) #1241
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: Trigger-Rules-Build | |
on: | |
workflow_dispatch: | |
push: | |
branches: | |
- main | |
jobs: | |
trigger-event: | |
runs-on: ubuntu-latest | |
if: github.repository_owner == 'SSWConsulting' | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
repository: SSWConsulting/SSW.Rules | |
- name: Find latest branch | |
id: find_branch | |
run: echo "branch_name=$(git ls-remote --heads origin | grep -oe 'refs/heads/release/.*' | sort -V | tail -n 1 | sed 's|refs/heads/||')" >> $GITHUB_OUTPUT | |
- name: Generate a token | |
id: generate-token | |
uses: actions/create-github-app-token@v1 | |
with: | |
app-id: ${{ vars.APP_ID }} | |
private-key: ${{ secrets.APP_PRIVATE_KEY }} | |
owner: SSWConsulting | |
repositories: SSW.Rules | |
- name: Build and deploy Rules | |
uses: benc-uk/workflow-dispatch@v1 | |
with: | |
workflow: build-deploy-production.yml | |
repo: SSWConsulting/SSW.Rules | |
ref: ${{ steps.find_branch.outputs.branch_name }} | |
token: "${{ steps.generate-token.outputs.token }}" |