Skip to content

Commit

Permalink
Remove ambiguity with --error-only flag (#66)
Browse files Browse the repository at this point in the history
Co-authored-by: Simon Ensslen <[email protected]>
  • Loading branch information
Fedoop1 and sensslen authored Jul 4, 2024
1 parent a7ff636 commit 696110a
Show file tree
Hide file tree
Showing 263 changed files with 5,703 additions and 18,626 deletions.
18 changes: 9 additions & 9 deletions .github/workflows/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ on:
branches:
- main
pull_request:
branches:
- '**'
branches:
- "**"

jobs:
test:
Expand Down Expand Up @@ -46,8 +46,8 @@ jobs:
runs-on: windows-latest
strategy:
matrix:
framework: [net6.0, net8.0, net472]
framework: [net6.0, net8.0, net472]

include:
- framework: net6.0
dotnetVersion: "6.0.x"
Expand Down Expand Up @@ -147,7 +147,7 @@ jobs:

- uses: nuget/setup-nuget@v2
- run: nuget restore NuGetUtility.sln

- name: Add msbuild to PATH
uses: microsoft/setup-msbuild@v2

Expand All @@ -158,7 +158,7 @@ jobs:
$path = [System.IO.Path]::GetFullPath("./release");
echo "publish to path: $path"
echo "path=$path" >> $env:GITHUB_OUTPUT
- name: build
run: msbuild ./src/NuGetLicenseFramework/NuGetLicenseFramework.csproj /t:Publish /p:configuration=Release /p:PublishDir=${{ steps.release_path.outputs.path }}

Expand Down Expand Up @@ -228,18 +228,18 @@ jobs:

- uses: nuget/setup-nuget@v2
- run: nuget restore NuGetUtility.sln

- name: Add msbuild to PATH
uses: microsoft/setup-msbuild@v2

- name: fully qualify release path
id: release_path
shell: pwsh
run: |
$path = [System.IO.Path]::GetFullPath("./release");
echo "publish to path: $path"
echo "path=$path" >> $env:GITHUB_OUTPUT
- uses: paulhatch/[email protected]
id: version
name: version
Expand Down
10 changes: 2 additions & 8 deletions src/NuGetUtility/Output/Json/JsonOutputFormatter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -27,15 +27,9 @@ public async Task Write(Stream stream, IList<LicenseValidationResult> results)
{
if (_printErrorsOnly)
{
IEnumerable<LicenseValidationResult> resultsWithErrors = results.Where(r => r.ValidationErrors.Any());
if (resultsWithErrors.Any())
{
await JsonSerializer.SerializeAsync(stream, resultsWithErrors, _options);
return;
}
results = results.Where(r => r.ValidationErrors.Any()).ToList();
}

if (_skipIgnoredPackages)
else if (_skipIgnoredPackages)
{
results = results.Where(r => r.LicenseInformationOrigin != LicenseInformationOrigin.Ignored).ToList();
}
Expand Down
5 changes: 2 additions & 3 deletions src/NuGetUtility/Output/Table/TableOutputFormatter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -41,12 +41,11 @@ public async Task Write(Stream stream, IList<LicenseValidationResult> results)
}
}

if (_printErrorsOnly && errorColumnDefinition.Enabled)
if (_printErrorsOnly)
{
results = results.Where(r => r.ValidationErrors.Any()).ToList();
}

if (_skipIgnoredPackages)
else if (_skipIgnoredPackages)
{
results = results.Where(r => r.LicenseInformationOrigin != LicenseInformationOrigin.Ignored).ToList();
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
[{"PackageId":"Legacy Metrics Planner","PackageVersion":"9.5.0","License":"Use the open-source JBOD matrix, then you can synthesize the open-source matrix!","LicenseInformationOrigin":1}]
[]

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -1 +1 @@
[{"PackageId":"Legacy Metrics Planner","PackageVersion":"9.5.0","License":"Use the open-source JBOD matrix, then you can synthesize the open-source matrix!","LicenseInformationOrigin":1},{"PackageId":"Forward Quality Producer","PackageVersion":"6.3.7","PackageProjectUrl":"https://jayne.name","License":"The CSS microchip is down, back up the bluetooth microchip so we can back up the CSS microchip!","LicenseInformationOrigin":4},{"PackageId":"Regional Security Architect","PackageVersion":"2.2.5","LicenseInformationOrigin":1},{"PackageId":"Global Usability Representative","PackageVersion":"3.5.9","LicenseInformationOrigin":1},{"PackageId":"District Mobility Administrator","PackageVersion":"3.2.3","LicenseInformationOrigin":3},{"PackageId":"Regional Solutions Supervisor","PackageVersion":"1.8.2","PackageProjectUrl":"https://lance.net","License":"You can\u0027t parse the system without compressing the haptic GB system!","LicenseInformationOrigin":3},{"PackageId":"Customer Directives Director","PackageVersion":"7.9.2","License":"Try to hack the COM panel, maybe it will hack the auxiliary panel!","LicenseInformationOrigin":4},{"PackageId":"Chief Assurance Associate","PackageVersion":"3.3.1","PackageProjectUrl":"https://tyrese.info","License":"overriding the panel won\u0027t do anything, we need to parse the open-source IB panel!","LicenseInformationOrigin":1},{"PackageId":"Customer Operations Officer","PackageVersion":"2.6.0","PackageProjectUrl":"http://antonette.org","License":"Use the bluetooth USB alarm, then you can override the bluetooth alarm!","LicenseInformationOrigin":4},{"PackageId":"Dynamic Security Technician","PackageVersion":"6.8.3","LicenseInformationOrigin":2},{"PackageId":"Central Integration Analyst","PackageVersion":"0.4.0","PackageProjectUrl":"https://laverne.name","License":"If we synthesize the protocol, we can get to the JBOD protocol through the multi-byte JBOD protocol!","LicenseInformationOrigin":4},{"PackageId":"National Communications Facilitator","PackageVersion":"3.1.0","License":"quantifying the transmitter won\u0027t do anything, we need to program the mobile HDD transmitter!","LicenseInformationOrigin":1},{"PackageId":"Dynamic Functionality Agent","PackageVersion":"5.9.5","PackageProjectUrl":"http://annabelle.net","LicenseInformationOrigin":2},{"PackageId":"Forward Functionality Analyst","PackageVersion":"4.5.1","PackageProjectUrl":"http://orie.name","LicenseInformationOrigin":0},{"PackageId":"District Branding Analyst","PackageVersion":"1.9.5","PackageProjectUrl":"https://paula.net","LicenseInformationOrigin":1},{"PackageId":"Product Applications Assistant","PackageVersion":"2.8.4","PackageProjectUrl":"https://carleton.info","License":"The FTP firewall is down, compress the back-end firewall so we can compress the FTP firewall!","LicenseInformationOrigin":4},{"PackageId":"Global Security Liaison","PackageVersion":"8.1.2","LicenseInformationOrigin":0},{"PackageId":"Central Interactions Manager","PackageVersion":"7.0.9","LicenseInformationOrigin":0},{"PackageId":"National Tactics Engineer","PackageVersion":"3.7.5","PackageProjectUrl":"https://alexys.org","License":"generating the matrix won\u0027t do anything, we need to override the redundant GB matrix!","LicenseInformationOrigin":1},{"PackageId":"Dynamic Applications Director","PackageVersion":"5.1.4","LicenseInformationOrigin":3}]
[]
Original file line number Diff line number Diff line change
@@ -1 +1 @@
[{"PackageId":"Legacy Metrics Planner","PackageVersion":"9.5.0","License":"Use the open-source JBOD matrix, then you can synthesize the open-source matrix!","LicenseInformationOrigin":1},{"PackageId":"Forward Quality Producer","PackageVersion":"6.3.7","PackageProjectUrl":"https://jayne.name","License":"The CSS microchip is down, back up the bluetooth microchip so we can back up the CSS microchip!","LicenseInformationOrigin":4},{"PackageId":"Regional Security Architect","PackageVersion":"2.2.5","LicenseInformationOrigin":1},{"PackageId":"Global Usability Representative","PackageVersion":"3.5.9","LicenseInformationOrigin":1},{"PackageId":"District Mobility Administrator","PackageVersion":"3.2.3","LicenseInformationOrigin":3}]
[]
Original file line number Diff line number Diff line change
@@ -1 +1 @@
[{"PackageId":"Legacy Metrics Planner","PackageVersion":"9.5.0","License":"Use the open-source JBOD matrix, then you can synthesize the open-source matrix!","LicenseInformationOrigin":3}]
[]

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -1 +1 @@
[{"PackageId":"Legacy Metrics Planner","PackageVersion":"9.5.0","License":"Use the open-source JBOD matrix, then you can synthesize the open-source matrix!","LicenseInformationOrigin":3},{"PackageId":"International Mobility Technician","PackageVersion":"3.7.5","PackageProjectUrl":"http://katelin.org","License":"We need to parse the cross-platform THX driver!","LicenseInformationOrigin":0},{"PackageId":"District Integration Manager","PackageVersion":"5.1.0","License":"I\u0027ll compress the cross-platform JSON capacitor, that should capacitor the JSON capacitor!","LicenseInformationOrigin":1},{"PackageId":"District Mobility Administrator","PackageVersion":"3.2.3","LicenseUrl":"You can\u0027t compress the transmitter without overriding the auxiliary TCP transmitter!","LicenseInformationOrigin":2},{"PackageId":"Investor Intranet Producer","PackageVersion":"5.4.1","PackageProjectUrl":"http://hyman.org","License":"Use the cross-platform CSS capacitor, then you can copy the cross-platform capacitor!","LicenseInformationOrigin":3},{"PackageId":"Product Infrastructure Supervisor","PackageVersion":"8.1.1","PackageProjectUrl":"https://merle.com","LicenseInformationOrigin":0},{"PackageId":"International Data Representative","PackageVersion":"3.5.7","PackageProjectUrl":"http://dakota.com","License":"Try to synthesize the COM port, maybe it will synthesize the haptic port!","LicenseInformationOrigin":3},{"PackageId":"Direct Brand Strategist","PackageVersion":"9.5.7","PackageProjectUrl":"http://maddison.biz","License":"We need to navigate the bluetooth RAM bus!","LicenseInformationOrigin":1},{"PackageId":"District Optimization Manager","PackageVersion":"4.0.4","License":"Use the bluetooth HDD driver, then you can parse the bluetooth driver!","LicenseUrl":"We need to quantify the wireless HTTP array!","LicenseInformationOrigin":4},{"PackageId":"Regional Directives Supervisor","PackageVersion":"4.9.8","PackageProjectUrl":"https://malcolm.net","License":"Try to reboot the THX hard drive, maybe it will reboot the open-source hard drive!","LicenseUrl":"Use the primary GB driver, then you can generate the primary driver!","LicenseInformationOrigin":3},{"PackageId":"Future Optimization Architect","PackageVersion":"5.1.5","License":"Use the auxiliary RAM alarm, then you can generate the auxiliary alarm!","LicenseInformationOrigin":4},{"PackageId":"Customer Factors Assistant","PackageVersion":"7.7.3","LicenseInformationOrigin":4},{"PackageId":"Future Data Architect","PackageVersion":"8.5.1","License":"The FTP firewall is down, compress the back-end firewall so we can compress the FTP firewall!","LicenseUrl":"Use the back-end SDD panel, then you can compress the back-end panel!","LicenseInformationOrigin":0},{"PackageId":"National Directives Analyst","PackageVersion":"8.2.7","License":"We need to compress the primary GB array!","LicenseInformationOrigin":3},{"PackageId":"Customer Interactions Representative","PackageVersion":"0.8.8","PackageProjectUrl":"http://heather.name","License":"We need to quantify the digital SSL array!","LicenseInformationOrigin":2},{"PackageId":"Product Paradigm Orchestrator","PackageVersion":"9.7.5","PackageProjectUrl":"http://adan.info","LicenseUrl":"Use the cross-platform CSS capacitor, then you can override the cross-platform capacitor!","LicenseInformationOrigin":1},{"PackageId":"Dynamic Optimization Director","PackageVersion":"3.4.6","PackageProjectUrl":"https://maximilian.org","License":"The PNG protocol is down, index the digital protocol so we can index the PNG protocol!","LicenseUrl":"I\u0027ll transmit the online SSL feed, that should feed the SSL feed!","LicenseInformationOrigin":3},{"PackageId":"Future Quality Coordinator","PackageVersion":"0.8.6","PackageProjectUrl":"http://fay.org","License":"I\u0027ll input the back-end JBOD capacitor, that should capacitor the JBOD capacitor!","LicenseInformationOrigin":1},{"PackageId":"National Web Administrator","PackageVersion":"7.7.1","PackageProjectUrl":"https://zella.org","License":"If we reboot the program, we can get to the SAS program through the haptic SAS program!","LicenseInformationOrigin":4},{"PackageId":"Forward Response Liaison","PackageVersion":"5.4.2","PackageProjectUrl":"http://hyman.net","License":"Try to hack the SMS sensor, maybe it will hack the back-end sensor!","LicenseUrl":"I\u0027ll generate the optical COM protocol, that should protocol the COM protocol!","LicenseInformationOrigin":1}]
[]
Original file line number Diff line number Diff line change
@@ -1 +1 @@
[{"PackageId":"Legacy Metrics Planner","PackageVersion":"9.5.0","License":"Use the open-source JBOD matrix, then you can synthesize the open-source matrix!","LicenseInformationOrigin":3},{"PackageId":"International Mobility Technician","PackageVersion":"3.7.5","PackageProjectUrl":"http://katelin.org","License":"We need to parse the cross-platform THX driver!","LicenseInformationOrigin":0},{"PackageId":"District Integration Manager","PackageVersion":"5.1.0","License":"I\u0027ll compress the cross-platform JSON capacitor, that should capacitor the JSON capacitor!","LicenseInformationOrigin":1},{"PackageId":"District Mobility Administrator","PackageVersion":"3.2.3","LicenseUrl":"You can\u0027t compress the transmitter without overriding the auxiliary TCP transmitter!","LicenseInformationOrigin":2},{"PackageId":"Investor Intranet Producer","PackageVersion":"5.4.1","PackageProjectUrl":"http://hyman.org","License":"Use the cross-platform CSS capacitor, then you can copy the cross-platform capacitor!","LicenseInformationOrigin":3}]
[]
Original file line number Diff line number Diff line change
@@ -1 +1 @@
[{"PackageId":"Legacy Metrics Planner","PackageVersion":"9.5.0","License":"Use the open-source JBOD matrix, then you can synthesize the open-source matrix!","LicenseInformationOrigin":3}]
[]

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -1 +1 @@
[{"PackageId":"Legacy Metrics Planner","PackageVersion":"9.5.0","License":"Use the open-source JBOD matrix, then you can synthesize the open-source matrix!","LicenseInformationOrigin":3},{"PackageId":"International Mobility Technician","PackageVersion":"3.7.5","PackageProjectUrl":"http://katelin.org","License":"We need to parse the cross-platform THX driver!","LicenseInformationOrigin":0},{"PackageId":"District Integration Manager","PackageVersion":"5.1.0","License":"I\u0027ll compress the cross-platform JSON capacitor, that should capacitor the JSON capacitor!","LicenseInformationOrigin":1},{"PackageId":"District Mobility Administrator","PackageVersion":"3.2.3","Authors":"Christopher Dietrich,Christopher Dietrich,Christopher Dietrich,Christopher Dietrich","LicenseInformationOrigin":2},{"PackageId":"Dynamic Integration Assistant","PackageVersion":"2.1.6","PackageProjectUrl":"https://gerson.info","LicenseInformationOrigin":2},{"PackageId":"Future Optimization Associate","PackageVersion":"4.0.5","PackageProjectUrl":"https://linnie.net","Authors":"Jeffrey Reichel,Jeffrey Reichel,Jeffrey Reichel,Jeffrey Reichel,Jeffrey Reichel,Jeffrey Reichel","LicenseInformationOrigin":2},{"PackageId":"Global Integration Assistant","PackageVersion":"5.0.1","PackageProjectUrl":"http://demarco.com","LicenseInformationOrigin":2},{"PackageId":"Human Implementation Producer","PackageVersion":"0.9.1","LicenseInformationOrigin":1},{"PackageId":"Future Tactics Producer","PackageVersion":"5.8.9","License":"navigating the pixel won\u0027t do anything, we need to parse the back-end IB pixel!","LicenseInformationOrigin":1},{"PackageId":"Dynamic Applications Director","PackageVersion":"5.1.4","Authors":"Violet Reichel,Violet Reichel,Violet Reichel,Violet Reichel,Violet Reichel,Violet Reichel,Violet Reichel,Violet Reichel,Violet Reichel,Violet Reichel","LicenseInformationOrigin":2},{"PackageId":"Principal Factors Producer","PackageVersion":"0.8.5","PackageProjectUrl":"http://toby.info","Authors":"Devin Nolan","License":"connecting the system won\u0027t do anything, we need to override the back-end SQL system!","LicenseInformationOrigin":2},{"PackageId":"Future Directives Planner","PackageVersion":"5.9.7","Authors":"Jimmy Franecki,Jimmy Franecki,Jimmy Franecki,Jimmy Franecki,Jimmy Franecki,Jimmy Franecki,Jimmy Franecki,Jimmy Franecki","License":"Use the wireless ADP array, then you can input the wireless array!","LicenseInformationOrigin":3},{"PackageId":"Customer Operations Liaison","PackageVersion":"9.0.9","License":"The PCI protocol is down, back up the multi-byte protocol so we can back up the PCI protocol!","LicenseInformationOrigin":0},{"PackageId":"Global Markets Administrator","PackageVersion":"8.6.8","PackageProjectUrl":"https://lois.biz","Authors":"Dominic Reilly,Dominic Reilly,Dominic Reilly,Dominic Reilly,Dominic Reilly,Dominic Reilly,Dominic Reilly","License":"You can\u0027t transmit the application without connecting the open-source SDD application!","LicenseInformationOrigin":4},{"PackageId":"Regional Integration Consultant","PackageVersion":"5.3.8","PackageProjectUrl":"http://michael.name","LicenseInformationOrigin":0},{"PackageId":"Central Applications Coordinator","PackageVersion":"1.6.8","PackageProjectUrl":"http://curtis.com","LicenseInformationOrigin":3},{"PackageId":"Forward Division Strategist","PackageVersion":"5.7.1","PackageProjectUrl":"https://esperanza.name","Authors":"Monica Bode,Monica Bode,Monica Bode,Monica Bode,Monica Bode,Monica Bode,Monica Bode","License":"You can\u0027t reboot the program without transmitting the mobile SMTP program!","LicenseInformationOrigin":0},{"PackageId":"Investor Interactions Designer","PackageVersion":"1.9.4","PackageProjectUrl":"https://octavia.name","LicenseInformationOrigin":4},{"PackageId":"Legacy Response Analyst","PackageVersion":"9.2.7","PackageProjectUrl":"http://martine.info","Authors":"Perry Cummerata,Perry Cummerata,Perry Cummerata,Perry Cummerata,Perry Cummerata,Perry Cummerata","LicenseInformationOrigin":2},{"PackageId":"Dynamic Mobility Technician","PackageVersion":"6.0.2","PackageProjectUrl":"https://keeley.net","LicenseInformationOrigin":0}]
[]
Original file line number Diff line number Diff line change
@@ -1 +1 @@
[{"PackageId":"Legacy Metrics Planner","PackageVersion":"9.5.0","License":"Use the open-source JBOD matrix, then you can synthesize the open-source matrix!","LicenseInformationOrigin":3},{"PackageId":"International Mobility Technician","PackageVersion":"3.7.5","PackageProjectUrl":"http://katelin.org","License":"We need to parse the cross-platform THX driver!","LicenseInformationOrigin":0},{"PackageId":"District Integration Manager","PackageVersion":"5.1.0","License":"I\u0027ll compress the cross-platform JSON capacitor, that should capacitor the JSON capacitor!","LicenseInformationOrigin":1},{"PackageId":"District Mobility Administrator","PackageVersion":"3.2.3","Authors":"Christopher Dietrich,Christopher Dietrich,Christopher Dietrich,Christopher Dietrich","LicenseInformationOrigin":2},{"PackageId":"Dynamic Integration Assistant","PackageVersion":"2.1.6","PackageProjectUrl":"https://gerson.info","LicenseInformationOrigin":2}]
[]
Original file line number Diff line number Diff line change
@@ -1 +1 @@
[{"PackageId":"Legacy Metrics Planner","PackageVersion":"9.5.0","Authors":"Sandy Halvorson,Sandy Halvorson,Sandy Halvorson,Sandy Halvorson,Sandy Halvorson,Sandy Halvorson,Sandy Halvorson","License":"Use the open-source JBOD matrix, then you can synthesize the open-source matrix!","LicenseInformationOrigin":2}]
[]

Large diffs are not rendered by default.

Loading

0 comments on commit 696110a

Please sign in to comment.