Skip to content

GitAuto: [FEATURE] Preserve version bump patterns in commit messages … #83

GitAuto: [FEATURE] Preserve version bump patterns in commit messages …

GitAuto: [FEATURE] Preserve version bump patterns in commit messages … #83

Workflow file for this run

name: Continuous Integration
on:
push:
branches:
- main
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
outputs:
fullSemVer: ${{ steps.gitversion.outputs.fullSemVer }}
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Install GitVersion
uses: gittools/actions/gitversion/setup@v3.0.0
with:
versionSpec: '5.x'
- name: Determine Version
id: gitversion
uses: gittools/actions/gitversion/execute@v3.0.0
with:
useConfigFile: true
updateAssemblyInfo: true
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: '8.0.x'
- name: Restore dependencies
run: dotnet restore
- name: Build
run: dotnet build -c Release --no-restore
- name: Run tests
run: dotnet test -c Release --no-restore --no-build --verbosity normal
- name: Pack
run: dotnet pack -c Release --no-restore --no-build -o ./nupkg -p:PackageVersion=${{ env.fullSemVer }} -p:IncludeSymbols=true -p:SymbolPackageFormat=snupkg
- name: Push to NuGet
run: dotnet nuget push ./nupkg/*.nupkg -k ${{ secrets.NUGET_API_KEY }} -s https://api.nuget.org/v3/index.json
create_release:
name: Create release
runs-on: ubuntu-latest
permissions:
contents: write
needs: build
env:
fullSemVer: ${{ needs.build.outputs.fullSemVer }}
steps:
- name: Create Release
uses: ncipollo/release-action@v1.14.0
with:
skipIfReleaseExists: true
allowUpdates: false
draft: false
makeLatest: true
tag: v${{ env.fullSemVer }}
name: Release v${{ env.fullSemVer }}
generateReleaseNotes: true
body: Release ${{ env.fullSemVer }} of ${{ github.repository }}