Skip to content

Create dotnet.yml

Create dotnet.yml #1

Workflow file for this run

# This workflow will build a .NET project
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-net
name: .NET
on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]
jobs:
build:
name: Build and upload artifact.
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- 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 --no-restore
- name: Upload artifact
uses: actions/[email protected]
with:
name: cstojs-artifact
path: /bin/Debug/net8.0/
test:
needs: build
name: Run tests.
runs-on: ubuntu-latest
steps:
- uses: actions/[email protected]
- name: Download a Build Artifact
with:
name: cstojs-artifact
path: artifact
- name: Display structure of downloaded files
run: ls -R artifact