Files
Test/.gitea/workflows/PreRelease.yaml
thx20001 e1fa753160
All checks were successful
Build and Release Prerelease / Publish with Dotnet 8.0.405 and Profile PublishLinuxX64 (push) Successful in 1m18s
Build and Release Prerelease / Publish with Dotnet 8.0.405 and Profile PublishWinX64 (push) Successful in 1m15s
sf18
2026-03-05 18:12:51 +01:00

48 lines
1.7 KiB
YAML

name: Build and Release Prerelease
run-name: Building and Releasing Prerelease Branch 🚀
on:
push:
tags:
- 'p**'
- '!r**'
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
dotnet: [ '8.0.405' ]
publishprofile: [ 'PublishLinuxX64', 'PublishWinX64' ]
name: Publish with Dotnet ${{ matrix.dotnet }} and Profile ${{ matrix.publishprofile }}
steps:
- name: Clone Project
uses: actions/checkout@master
with:
ref: prerelease
#&& echo "RELEASE_MESSAGE=${ git tag -l --format='%(contents:subject)' 'RELEASE_VERSION' }" >> $GITEA_ENV
- name: Test
run: echo "TAG_MESSAGE=$(git tag -l --format='%(contents:subject)'${GITEA_REF#refs/*/})" >> $GITEA_ENV
#- name: Test2
# run: echo "RELEASE_MESSAGE=${git tag -l --format='%(contents:subject)' $RELEASE_VERSION}" >> $GITEA_ENV
- name: Setup dotnet
uses: actions/setup-dotnet@v1
with:
dotnet-version: ${{ matrix.dotnet }}
- name: Build / Publish Project
run: dotnet publish GiteaTest.sln -p:PublishProfile=${{ matrix.publishprofile }}
- name: Pack Linux Release
if: ${{ matrix.publishprofile == 'PublishLinuxX64' }}
run: tar -cvzf ${{ matrix.publishprofile }}.tar.gz -C GiteaTest/publish .
- name: Pack Windows Release
if: ${{ matrix.publishprofile == 'PublishWinX64' }}
run: cd GiteaTest/publish/ && zip ../../${{ matrix.publishprofile }}.zip *
- name: Release Files
uses: akkuman/gitea-release-action@v1
with:
name: Release ${{ gitea.ref_name }}
body: $TAG_MESSAGE
prerelease: true
md5sum: true
files: |-
${{ matrix.publishprofile }}.*