This repository has been archived by the owner on May 31, 2024. It is now read-only.
Update workflow triggers to use string literals instead of arrays #8
Workflow file for this run
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
# Dieser Workflow liest die Versionsnummer aus der Projektdatei und speichert sie für die folgenden Schritte. | |
name: Set Version | |
on: | |
push: | |
branches: | |
- '**' | |
jobs: | |
set-version: | |
runs-on: ubuntu-latest | |
env: | |
PROJECT_FILE: Templates.csproj | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup .NET Core | |
uses: actions/setup-dotnet@v4 | |
with: | |
dotnet-version: '8.0.x' | |
- name: Read Package Version from .csproj and Set as Env Var | |
run: | | |
version=$(grep '<PackageVersion>' ${{ env.PROJECT_FILE }} | sed -n -e 's/.*<PackageVersion>\(.*\)<\/PackageVersion>.*/\1/p') | |
echo "Base version is $version" | |
echo "BASE_VERSION=$version" >> $GITHUB_ENV |