-
-
Notifications
You must be signed in to change notification settings - Fork 241
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Powershell linter throws error if the path it is analyzing has a space in it #1728
Comments
Have you already attempted to reproduce this issue by running PSScriptAnalyzer directly? |
I had not, but running these commands from that repo show it working/the same failure if there are no quotes around the file path.
I get the expected result, which is the output of failed rules. a file with no spaces works good as well/will not
If I ommit the quotes I get an error, which is the same when running as an action.
|
Sounds like we are most likely omitting quotes when calling PSScriptAnalyzer then. Thank you for narrowing it down. |
@brandonmcclure it should be ok now, please can you check with oxsecurity/megalinter:beta ? |
Describe the bug
When I configure the
POWERSHELL_POWERSHELL
linter via github CI and change a .ps1 file that has a space in it's file path, I get an error:To Reproduce
Steps to reproduce the behavior:
I created a repository that reproduces the behavior I am seeing. https://github.com/brandonmcclure/megalinter_repro/pulls
Expected behavior
The linter to run in the same way it does for modified ps1 files that do not have a space in their path. See this PR for an example of success: https://github.com/brandonmcclure/megalinter_repro/pull/2
The text was updated successfully, but these errors were encountered: