Skip to content

[Snyk] Security upgrade conventional-changelog-cli from 2.1.0 to 5.0.0 #153

[Snyk] Security upgrade conventional-changelog-cli from 2.1.0 to 5.0.0

[Snyk] Security upgrade conventional-changelog-cli from 2.1.0 to 5.0.0 #153

Workflow file for this run

name: Validate PR
on:
pull_request:
env:
ReportOutput: '${{github.workspace}}'
TestReportFileName: 'TestReport.${{github.run_number}}.md'
ACTIONS_ALLOW_UNSECURE_COMMANDS: true
# Dotnet Setup
DOTNET_VERSION: 3.1.401
# Stop wasting time caching packages
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: true
# Disable sending usage data to Microsoft
DOTNET_CLI_TELEMETRY_OPTOUT: true
# Solution Setup
CONFIG: 'Release'
# Nuget Setup
NUGET_VERSION: 'latest'
jobs:
build-and-test:
runs-on: windows-latest
steps:
- name: Checkout commit
uses: actions/checkout@v2
- name: Setup MSBuild
uses: microsoft/setup-msbuild@v1
- name: Setup .NET Core
uses: actions/setup-dotnet@v1
with:
dotnet-version: ${{ env.DOTNET_VERSION }}
- name: Configure NuGet
uses: nuget/setup-nuget@v1
with:
nuget-version: ${{ env.NUGET_VERSION }}
- name: NuGet Restore
shell: powershell
working-directory: ${{ github.workspace }}
run: |
$solutions = Get-ChildItem -Path . -Recurse -Include *.sln
foreach ($solutionFile in $solutions){
nuget restore "$solutionFile"
}
- name: Install Dependencies
shell: powershell
working-directory: ${{ github.workspace }}
run: |
$solutions = Get-ChildItem -Path . -Recurse -Include *.sln
foreach ($solutionFile in $solutions){
dotnet restore "$solutionFile"
}
- name: Build
shell: powershell
working-directory: ${{ github.workspace }}
run: |
$solutions = Get-ChildItem -Path . -Recurse -Include *.sln
foreach ($solutionFile in $solutions){
msbuild.exe "$solutionFile" `
/p:Configuration=${{ env.CONFIG }} `
/p:DeployOnBuild=false `
/p:SkipInvalidConfigurations=true `
/p:TransformWebConfigEnabled=False `
/p:AutoParameterizationWebConfigConnectionStrings=False `
/p:MarkWebConfigAssistFilesAsExclude=False
}
- name: Set PR build number
id: PRNUMBER
if: ${{ github.event_name == 'pull_request' }}
uses: kkak10/pr-number-action@v1.3
- name: Set Test Title
run: |
echo "::set-env name=title::Test Run for PR #${{ steps.PRNUMBER.outputs.pr }} (${{ github.run_number }})"
- name: Run Tests
run: dotnet test --no-restore --no-build --configuration ${{ env.CONFIG }} --logger:"liquid.md;LogFileName=${{ env.ReportOutput}}\${{ env.TestReportFileName }};Title=${{ env.Title }};"
- name: Upload test results
uses: actions/upload-artifact@v2
with:
name: results
path: ${{ env.ReportOutput}}\${{ env.TestReportFileName }}
commenting:
needs: build-and-test
runs-on: ubuntu-latest
steps:
- name: Checkout commit
uses: actions/checkout@v2
- uses: actions/download-artifact@v1
with:
name: results
- name: Comment PR
uses: machine-learning-apps/pr-comment@master
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
path: results/${{ env.TestReportFileName }}