Bump Microsoft.AspNetCore.Components.WebAssembly.Server from 8.0.20 to 8.0.21 #103
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
# qqqq in development | |
# this script seperate major and minor but we do merge them into the same branch. | |
# having two steps allows us to easily turn off major changes in future and then script them to their own branch and pipeline. | |
name: auto-merge dependabot prs into collected branch | |
on: | |
pull_request: | |
# types: [opened, synchronize] | |
branches: [Automatic_version_update_dependabot] | |
permissions: | |
contents: write | |
pull-requests: write | |
checks: read | |
issues: write | |
jobs: | |
debug: | |
runs-on: ubuntu-latest | |
steps: | |
- name: debug info | |
run: | | |
echo "actor: ${{ github.actor }}" | |
echo "pr title: ${{ github.event.pull_request.title }}" | |
echo "github event_name: ${{ github.event_name }}" | |
echo "target branch: ${{ github.event.pull_request.base.ref }}" | |
echo "source branch: ${{ github.event.pull_request.head.ref }}" | |
echo "PR Number: ${{ github.event.pull_request.number }}" | |
echo "event type: ${{ github.event.pull_request.type || 'N/A' }}" | |
echo "Pull request user login: ${{ github.event.pull_request.user.login }}" | |
echo "Repository: ${{ github.repository }}" | |
echo "Event name: ${{ github.event_name }}" | |
echo "Event action: ${{ github.event.action }}" | |
# Branch rules ensure doesnt auto merge if shouldnt | |
auto-merge: | |
runs-on: ubuntu-latest | |
if: ${{ github.event.pull_request.user.login == 'dependabot[bot]' && github.repository == 'TechnologyEnhancedLearning/TELBlazor' }} | |
steps: | |
- name: Checkout the repository | |
uses: actions/checkout@v4 | |
- name: Set up GitHub CLI | |
run: | | |
# Install GitHub CLI (gh) | |
sudo apt-get update | |
sudo apt-get install gh | |
- name: extract update type | |
id: extract | |
env: | |
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
run: | | |
echo "get pr title" | |
pr_title="${{ github.event.pull_request.title }}" | |
echo "PR title: $pr_title" | |
if [[ "$pr_title" == *"(major)"* ]]; then | |
echo "update_type=major" >> $GITHUB_OUTPUT | |
echo "Detected major update" | |
else | |
echo "update_type=minor_or_patch" >> $GITHUB_OUTPUT | |
echo "Detected minor or patch update" | |
fi | |
- name: auto-merge minor and patch updates | |
if: steps.extract.outputs.update_type == 'minor_or_patch' | |
run: | | |
gh pr merge --auto --merge "${{ github.event.pull_request.number }}" | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
- name: auto-merge major updates | |
if: steps.extract.outputs.update_type == 'major' | |
run: | | |
gh pr merge --auto --merge "${{ github.event.pull_request.number }}" | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |