Skip to content

Deploy to GitHub Releases #1

Deploy to GitHub Releases

Deploy to GitHub Releases #1

Workflow file for this run

name: Deploy to GitHub Releases
on: workflow_dispatch
jobs:
deploy-to-github-releases:
runs-on: windows-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v4
- name: Get Version from Project File
id: get-version
shell: bash
run: echo "version=$(grep -oE '<Version>[^<]+' SketchNow/SketchNow.csproj | sed 's/<Version>//')" >> $GITHUB_OUTPUT
- name: Install .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 9.0.x
- name: Publish Application
if: ${{ github.event_name != 'pull_request' }}
run: dotnet publish --configuration Release --no-build -p:Version="${{ env.version }}" -p:PublishDir=${{ github.workspace }}/.build/publish -r win-x64 --self-contained true
- name: Create Velopack Release
run: |
dotnet tool install -g vpk
vpk download github --repoUrl https://github.com/SketchNow/SketchNow.WPF
vpk pack -u SketchNow -v ${{ steps.get-version.outputs.version }} -p publish
vpk upload github --repoUrl https://github.com/SketchNow/SketchNow.WPF --publish --releaseName "SketchNow ${{ steps.get-version.outputs.version }}" --tag v${{ steps.get-version.outputs.version }}
- name: Generate Release Notes
uses: yashanand1910/[email protected]
id: get_release_notes
with:
changelog_path: ./CHANGELOG.md
version: ${{ steps.get-version.outputs.version }}
body: ${{ steps.get_release_notes.outputs.release_notes }}