Create Milestone and Draft Release #824
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: Create Milestone and Draft Release | |
on: | |
push: | |
branches: | |
- master | |
paths-ignore: | |
- '**/*.md' | |
schedule: | |
- cron: '0 0 * * 4' | |
jobs: | |
create_milestone_and_draft_release: | |
permissions: | |
# write permission is required to create a github release | |
contents: write | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4.2.2 | |
with: | |
fetch-depth: 0 | |
- uses: actions/setup-dotnet@v4 | |
- name: Fetch all history for all tags and branches | |
run: git fetch --prune | |
- name: Install GitVersion | |
uses: gittools/actions/gitversion/setup@v3.0.0 | |
with: | |
versionSpec: '5.x' | |
- name: Use GitVersion | |
id: gitversion | |
uses: gittools/actions/gitversion/execute@v3.0.0 | |
- name: Create Milestone | |
uses: WyriHaximus/github-action-create-milestone@v1 | |
with: | |
title: v${{ steps.gitversion.outputs.majorMinorPatch }} | |
env: | |
GITHUB_TOKEN: '${{ secrets.GITHUB_TOKEN }}' | |
continue-on-error: true | |
- name: sync milestones | |
uses: RocketSurgeonsGuild/actions/sync-milestone@v0.3.3 | |
with: | |
default-label: 'mysterious' | |
github-token: ${{ secrets.GITHUB_TOKEN }} | |
- uses: ncipollo/release-action@v1 | |
with: | |
allowUpdates: true | |
generateReleaseNotes: true | |
draft: true | |
omitNameDuringUpdate: true | |
name: 'v${{ steps.gitversion.outputs.majorMinorPatch }}' | |
tag: 'v${{ steps.gitversion.outputs.majorMinorPatch }}' | |
token: ${{ secrets.GITHUB_TOKEN }} | |
commit: ${{ github.base_ref }} |