From 47c35f15eb16ca410ad99d8287954caf5ca7e9e1 Mon Sep 17 00:00:00 2001 From: Dawid Rutkowski Date: Mon, 25 Nov 2024 10:59:27 +0100 Subject: [PATCH] last commit --- .gitea/workflows/ci.yaml | 49 +++++++--------------------------------- 1 file changed, 8 insertions(+), 41 deletions(-) diff --git a/.gitea/workflows/ci.yaml b/.gitea/workflows/ci.yaml index df2a236..42f9b9b 100644 --- a/.gitea/workflows/ci.yaml +++ b/.gitea/workflows/ci.yaml @@ -1,49 +1,16 @@ name: First CI -on: - push: +on: [push] jobs: build: runs-on: ubuntu-latest + strategy: + matrix: + rid: ["win-x64", "linux-x64"] steps: - - name: Checkout repository - uses: actions/checkout@v4 - - - name: Setup .NET - uses: actions/setup-dotnet@v3 + - uses: actions/checkout@v4 + - uses: actions/setup-dotnet@v3 with: dotnet-version: '8.0.x' - - - name: Restore dependencies - run: dotnet restore - - - name: Build the project - run: dotnet build - - - name: Run tests - run: dotnet test - - - name: Publish application - run: dotnet publish -o app -r linux-x64 --sc /p:PublishSingleFile=true /p:AssemblyName=app - - - name: Create tarball - run: tar cf app.tar app/ - - - name: Upload artifact - uses: actions/upload-artifact@v3 - with: - name: app.tar - path: app.tar - - test: - steps: - - name: Download artifact - uses: actions/download-artifact@v3 - with: - name: app.tar - - - name: Extract tarball - run: tar xf app.tar - - - name: Run the application - run: ./app/app + - run: dotnet restore + - run: dotnet publish -o app -r ${{ matrix.rid }} --sc /p:PublishSingleFile=true \ No newline at end of file