Merge branch 'master' of github.com:JoshClose/CsvHelper #1
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
name: CI | |
on: [push, pull_request] | |
jobs: | |
build: | |
strategy: | |
matrix: | |
os: [windows-latest, ubuntu-latest, macos-latest] | |
runs-on: ${{ matrix.os }} | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Setup Git Semantic Version | |
id: gitversion | |
uses: PaulHatch/semantic-version@v5 | |
with: | |
tag_prefix: "" | |
- name: Set Version Environment Variables | |
run: | | |
echo "ASSEMBLY_VERSION=${{ steps.gitversion.outputs.major }}.0.0.0" >> "$GITHUB_ENV" | |
echo "FILE_VERSION=${{ steps.gitversion.outputs.version }}.${{ github.run_number }}" >> "$GITHUB_ENV" | |
- name: Setup .NET Core | |
uses: actions/setup-dotnet@v4 | |
- name: Display .NET Version | |
run: dotnet --version | |
- name: Restore | |
run: dotnet restore | |
- name: Build | |
run: dotnet build --no-restore --configuration Release -p:AssemblyVersion=${{ env.ASSEMBLY_VERSION }} -p:FileVersion=${{ env.FILE_VERSION }} | |
- name: Test | |
run: dotnet test --configuration Release --no-restore --verbosity normal |