Skip to content

fix: package.json & yarn.lock to reduce vulnerabilities #532

fix: package.json & yarn.lock to reduce vulnerabilities

fix: package.json & yarn.lock to reduce vulnerabilities #532

Workflow file for this run

name: CI Build
on:
push:
branches:
- '**'
tags-ignore:
- '**'
pull_request:
branches:
- '**'
workflow_call:
outputs:
version:
description: "Version"
value: ${{ jobs.build.outputs.version }}
version_MajorMinorPatch:
description: "Version (without prerelease tag)"
value: ${{ jobs.build.outputs.version_MajorMinorPatch }}
is_prerelease:
description: "Version prerelease ($true or $false)"
value: ${{ jobs.build.outputs.is_prerelease }}
jobs:
test:
name: Test
runs-on: windows-latest
permissions:
id-token: write
contents: read
checks: write
steps:
- uses: actions/setup-dotnet@v2
with:
dotnet-version: '7.0.x'
include-prerelease: true
- uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Run Tests
id: tests
run: ./build/02-test.ps1
- name: Test Report DotNet
uses: dorny/test-reporter@v1.5.0
if: success() || failure()
with:
name: TestsResults (dotnet)
path: "**/TestResults*.trx"
reporter: dotnet-trx
fail-on-error: true
- name: Test Report PowerShell v5
uses: dorny/test-reporter@v1.5.0
if: success() || failure()
with:
name: TestsResults (PowerShell v5)
path: ./testResults_PS5.xml
reporter: java-junit
fail-on-error: true
- name: Test Report PowerShell v7
uses: dorny/test-reporter@v1.5.0
if: success() || failure()
with:
name: TestsResults (PowerShell v7)
path: ./testResults_PS7.xml
reporter: java-junit
fail-on-error: true
build:
name: Build
runs-on: windows-latest
steps:
- uses: actions/setup-dotnet@v2
with:
dotnet-version: '7.0.x'
include-prerelease: true
- uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Install dependencies
run: choco install GitVersion.Portable --version 5.6.11 --confirm --no-progress; choco install il-repack --confirm --no-progress
- name: Update project version
run: gitversion /l console /output buildserver /updateAssemblyInfo /verbosity minimal
- name: Get project version
id: getversion
run: |
echo "version=$(gitversion /showvariable LegacySemVer)" >> "$env:GITHUB_OUTPUT"
echo "version_MajorMinorPatch=$(gitversion /showvariable MajorMinorPatch)" >> "$env:GITHUB_OUTPUT"
if ("$(gitversion /showvariable PreReleaseTag)" -eq "") {
echo "is_prerelease=0" >> "$env:GITHUB_OUTPUT"
} else {
echo "is_prerelease=1" >> "$env:GITHUB_OUTPUT"
}
get-content "$env:GITHUB_OUTPUT"
- name: Build
run: ./build/01-build.ps1
- name: Upload build artifacts
uses: actions/upload-artifact@v3
with:
name: Binaries
path: ./artifacts
outputs:
version: ${{ steps.getversion.outputs.version }}
version_MajorMinorPatch: ${{ steps.getversion.outputs.version_MajorMinorPatch }}
is_prerelease: ${{ steps.getversion.outputs.is_prerelease }}