Skip to content

Release 0.7.0

Release 0.7.0 #316

Workflow file for this run

on:
push:
branches:
- main
tags:
- v*
pull_request:
jobs:
build:
runs-on: ubuntu-20.04
env:
Configuration: Release
TreatWarningsAsErrors: true
WarningsNotAsErrors: 1591
Deterministic: true
defaults:
run:
working-directory: src
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- run: dotnet tool install -g GitVersion.Tool --version 5.10.0
- name: Resolve version
id: version
run: |
dotnet-gitversion
dotnet-gitversion > version.json
version="$(jq -r '.SemVer' version.json)"
pr_version="$(jq -r '.MajorMinorPatch' version.json)-$(jq -r '.PreReleaseLabel' version.json).${{ github.run_number }}.${{ github.run_attempt }}"
if [ "${{ github.event_name }}" = "pull_request" ]; then version=$pr_version; fi
echo "Resolved version: $version"
echo "Version=${version}" >> "$GITHUB_ENV"
- run: dotnet restore --configfile nuget.config
- run: dotnet format --no-restore --verify-no-changes --severity info
- run: dotnet build --no-restore
- run: dotnet test --no-build
- uses: actions/checkout@v3
with:
repository: josefpihrt/wordb
path: wordb
- run: dotnet tool install -g Roslynator.DotNet.Cli --version 0.7.0
- run: |
roslynator spellcheck Orang.sln --dry-run --scope all --words \
spellcheck \
../wordb/data/en \
../wordb/data/en-us \
../wordb/data/names.txt \
../wordb/data/tech.names.txt \
../wordb/data/tech.acronyms.txt
- run: dotnet pack --no-build
- uses: actions/upload-artifact@v3
with:
name: nuget_packages
path: src/CommandLine/bin/Release/*.*nupkg
- uses: actions/upload-artifact@v3
with:
name: nuget_packages
path: src/Common/bin/Release/*nupkg
- uses: actions/upload-artifact@v3
with:
name: nuget_packages
path: src/FileSystem/bin/Release/*.*nupkg
publish:
runs-on: ubuntu-20.04
needs: [build]
if: github.ref_type == 'tag'
steps:
- uses: actions/download-artifact@v3
with:
name: nuget_packages
path: nuget_packages
- run: dotnet nuget push "*.nupkg" -k ${{ secrets.NUGET_API_KEY }} -s "https://api.nuget.org/v3/index.json" --skip-duplicate
working-directory: nuget_packages