From f6085a6782c38fa8441bed48e38645c139f65d5c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Zolt=C3=A1n=20Leh=C3=B3czky?= Date: Wed, 3 Jul 2024 20:21:07 +0200 Subject: [PATCH] Revert "Intentional analyzer violation" This reverts commit 7694bab87c117cbc71fee772e202d4e5c5349489. --- Lombiq.Analyzers.PowerShell/Invoke-Analyzer.ps1 | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Lombiq.Analyzers.PowerShell/Invoke-Analyzer.ps1 b/Lombiq.Analyzers.PowerShell/Invoke-Analyzer.ps1 index 5cfcb66..cb7d427 100644 --- a/Lombiq.Analyzers.PowerShell/Invoke-Analyzer.ps1 +++ b/Lombiq.Analyzers.PowerShell/Invoke-Analyzer.ps1 @@ -44,14 +44,13 @@ function Find-Recursively([string] $Path = '.', [string[]] $IncludeFile, [string function Write-FileError([string] $Message, [string] $Path, [int] $Line = 0, [int] $Column = 0) { - if ($Path) { $Path = Get-Item $Path } + if ($Path) { $Path = Get-Item $Path } if ($ForGitHubActions) { $Message = $Message -replace '\s*(\r?\n\s*)+', ' ' Write-Output "::error::$(if ($Path) { "$(Resolve-Path -Relative -Path $Path)($Line,$Column): " })$Message" } - elseif ($ForMsBuild) { if (-not $Message.Contains(':')) { $Message = ": $Message" }