Skip to main content
powershell/PSAvoidTrailingWhitespace is a PSScriptAnalyzer diagnostic emitted by tally for PowerShell snippets embedded in Dockerfiles.

Description

Lines should not end with whitespace characters. This can cause problems with the line-continuation backtick, and also clutters up future commits to source control. This diagnostic can coexist with tally/no-trailing-spaces: PSScriptAnalyzer reports trailing whitespace in PowerShell snippets, while tally checks the Dockerfile as a whole. If both rules suggest the same edit, tally applies it once.

Source

This rule documentation is adapted from Microsoft’s PSScriptAnalyzer documentation for AvoidTrailingWhitespace, licensed under CC BY 4.0.