Skip to content
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

Remove UTF-8 BOM from text files #1567

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
5 changes: 5 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
root = true

[*]
charset = utf-8
insert_final_newline = true
2 changes: 1 addition & 1 deletion CHANGELOG.MD
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# CHANGELOG
# CHANGELOG

## [1.19.1](https://github.com/PowerShell/PSScriptAnalyzer/tree/1.19.1) - 2020-07-28

Expand Down
2 changes: 1 addition & 1 deletion Engine/Commands/GetScriptAnalyzerLoggerCommand.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//
//
// Copyright (c) Microsoft Corporation.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
Expand Down
2 changes: 1 addition & 1 deletion Engine/Commands/GetScriptAnalyzerRuleCommand.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using Microsoft.Windows.PowerShell.ScriptAnalyzer.Generic;
Expand Down
2 changes: 1 addition & 1 deletion Engine/Commands/InvokeScriptAnalyzerCommand.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using Microsoft.Windows.PowerShell.ScriptAnalyzer.Generic;
Expand Down
2 changes: 1 addition & 1 deletion Engine/EditableText.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using Microsoft.Windows.PowerShell.ScriptAnalyzer.Extensions;
Expand Down
2 changes: 1 addition & 1 deletion Engine/Engine.csproj
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<Project Sdk="Microsoft.NET.Sdk">
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<VersionPrefix>1.19.1</VersionPrefix>
Expand Down
2 changes: 1 addition & 1 deletion Engine/Extensions.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System;
Expand Down
2 changes: 1 addition & 1 deletion Engine/Generic/AvoidCmdletGeneric.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System;
Expand Down
2 changes: 1 addition & 1 deletion Engine/Generic/AvoidParameterGeneric.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System;
Expand Down
2 changes: 1 addition & 1 deletion Engine/Generic/ConfigurableRule.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System;
Expand Down
2 changes: 1 addition & 1 deletion Engine/Generic/ConfigurableRulePropertyAttribute.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System;
Expand Down
2 changes: 1 addition & 1 deletion Engine/Generic/ConsoleHostHelper.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System;
Expand Down
2 changes: 1 addition & 1 deletion Engine/Generic/CorrectionExtent.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System.Collections.Generic;
Expand Down
2 changes: 1 addition & 1 deletion Engine/Generic/DiagnosticRecord.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System.Collections.Generic;
Expand Down
2 changes: 1 addition & 1 deletion Engine/Generic/DiagnosticRecordHelper.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System;
Expand Down
2 changes: 1 addition & 1 deletion Engine/Generic/ExternalRule.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System.Globalization;
Expand Down
4 changes: 2 additions & 2 deletions Engine/Generic/IDSCResourceRule.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System.Collections.Generic;
Expand Down Expand Up @@ -32,4 +32,4 @@ public interface IDSCResourceRule : IRule
#endif

}
}
}
2 changes: 1 addition & 1 deletion Engine/Generic/IExternalRule.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

namespace Microsoft.Windows.PowerShell.ScriptAnalyzer.Generic
Expand Down
2 changes: 1 addition & 1 deletion Engine/Generic/ILogger.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System;
Expand Down
2 changes: 1 addition & 1 deletion Engine/Generic/IRule.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

namespace Microsoft.Windows.PowerShell.ScriptAnalyzer.Generic
Expand Down
2 changes: 1 addition & 1 deletion Engine/Generic/IScriptRule.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System.Collections.Generic;
Expand Down
2 changes: 1 addition & 1 deletion Engine/Generic/ITokenRule.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System.Collections.Generic;
Expand Down
2 changes: 1 addition & 1 deletion Engine/Generic/LoggerInfo.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System.Diagnostics.CodeAnalysis;
Expand Down
4 changes: 2 additions & 2 deletions Engine/Generic/ModuleDependencyHandler.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

#if !PSV3
Expand Down Expand Up @@ -523,4 +523,4 @@ public void Dispose()
#endregion Public Methods
}
}
#endif // !PSV3
#endif // !PSV3
2 changes: 1 addition & 1 deletion Engine/Generic/PathResolver.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

namespace Microsoft.Windows.PowerShell.ScriptAnalyzer.Generic
Expand Down
2 changes: 1 addition & 1 deletion Engine/Generic/RuleInfo.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System;
Expand Down
2 changes: 1 addition & 1 deletion Engine/Generic/RuleSeverity.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

namespace Microsoft.Windows.PowerShell.ScriptAnalyzer.Generic
Expand Down
2 changes: 1 addition & 1 deletion Engine/Generic/RuleSuppression.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System;
Expand Down
2 changes: 1 addition & 1 deletion Engine/Generic/SkipNamedBlock.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System;
Expand Down
2 changes: 1 addition & 1 deletion Engine/Generic/SkipTypeDefinition.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System.Collections.Generic;
Expand Down
2 changes: 1 addition & 1 deletion Engine/Generic/SourceType.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

namespace Microsoft.Windows.PowerShell.ScriptAnalyzer.Generic
Expand Down
2 changes: 1 addition & 1 deletion Engine/Generic/SuppressedRecord.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

namespace Microsoft.Windows.PowerShell.ScriptAnalyzer.Generic
Expand Down
2 changes: 1 addition & 1 deletion Engine/Helper.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using Microsoft.Windows.PowerShell.ScriptAnalyzer.Generic;
Expand Down
2 changes: 1 addition & 1 deletion Engine/IOutputWriter.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System.Management.Automation;
Expand Down
2 changes: 1 addition & 1 deletion Engine/Loggers/WriteObjectsLogger.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System;
Expand Down
2 changes: 1 addition & 1 deletion Engine/SafeDirectoryCatalog.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//
//
// Copyright (c) Microsoft Corporation.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
Expand Down
2 changes: 1 addition & 1 deletion Engine/ScriptAnalyzer.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System.Text.RegularExpressions;
Expand Down
4 changes: 2 additions & 2 deletions Engine/ScriptAnalyzer.format.ps1xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8" ?>
<?xml version="1.0" encoding="utf-8" ?>
<Configuration>
<ViewDefinitions>
<View>
Expand Down Expand Up @@ -153,4 +153,4 @@
</TableControl>
</View>
</ViewDefinitions>
</Configuration>
</Configuration>
4 changes: 2 additions & 2 deletions Engine/ScriptAnalyzer.types.ps1xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8" ?>
<?xml version="1.0" encoding="utf-8" ?>
<Types>
<Type>
<Name>Microsoft.Windows.PowerShell.ScriptAnalyzer.Generic.DiagnosticRecord</Name>
Expand Down Expand Up @@ -89,4 +89,4 @@
</MemberSet>
</Members>
</Type>
</Types>
</Types>
4 changes: 2 additions & 2 deletions Engine/Settings/CmdletDesign.psd1
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@{
@{
IncludeRules=@('PSUseApprovedVerbs',
'PSReservedCmdletChar',
'PSReservedParams',
Expand All @@ -7,4 +7,4 @@
'PSUseSingularNouns',
'PSMissingModuleManifestField',
'PSAvoidDefaultValueSwitchParameter')
}
}
4 changes: 2 additions & 2 deletions Engine/Settings/DSC.psd1
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
@{
@{
IncludeRules=@('PSDSC*')
}
}
4 changes: 2 additions & 2 deletions Engine/Settings/ScriptFunctions.psd1
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@{
@{
IncludeRules=@('PSAvoidUsingCmdletAliases',
'PSAvoidUsingWMICmdlet',
'PSAvoidUsingEmptyCatchBlock',
Expand All @@ -8,4 +8,4 @@
'PSAvoidGlobalVars',
'PSUseDeclaredVarsMoreThanAssignments',
'PSAvoidUsingInvokeExpression')
}
}
4 changes: 2 additions & 2 deletions Engine/Settings/ScriptSecurity.psd1
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
@{
@{
IncludeRules=@('PSAvoidUsingPlainTextForPassword',
'PSAvoidUsingComputerNameHardcoded',
'PSAvoidUsingConvertToSecureStringWithPlainText',
'PSUsePSCredentialType',
'PSAvoidUsingUserNameAndPasswordParams')
}
}
4 changes: 2 additions & 2 deletions Engine/Settings/ScriptingStyle.psd1
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@{
@{
IncludeRules=@('PSProvideCommentHelp',
'PSAvoidUsingWriteHost')
}
}
2 changes: 1 addition & 1 deletion Engine/Settings/desktop-2.0-windows.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
{
"Modules": [
{
"Name": "ADRMS",
Expand Down
2 changes: 1 addition & 1 deletion Engine/Settings/desktop-3.0-windows.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
{
"Modules": [
{
"Name": "AppLocker",
Expand Down
2 changes: 1 addition & 1 deletion Engine/Settings/desktop-4.0-windows.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
{
"Modules": [
{
"Name": "AppLocker",
Expand Down
2 changes: 1 addition & 1 deletion Engine/Strings.Designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions Engine/Strings.resx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Expand Down Expand Up @@ -324,4 +324,4 @@
<data name="TypeNotFoundParseErrorFound" xml:space="preserve">
<value>Ignoring 'TypeNotFound' parse error on type '{0}'. Check if the specified type is correct. This can also be due the type not being known at parse time due to types imported by 'using' statements.</value>
</data>
</root>
</root>
2 changes: 1 addition & 1 deletion Engine/TextEdit.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System;
Expand Down
2 changes: 1 addition & 1 deletion Engine/TokenOperations.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System;
Expand Down
2 changes: 1 addition & 1 deletion Engine/VariableAnalysis.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System;
Expand Down
2 changes: 1 addition & 1 deletion Engine/VariableAnalysisBase.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System;
Expand Down
2 changes: 1 addition & 1 deletion New-StronglyTypedCsFileForResx.ps1
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<#
<#
# This script can be used to update the *.Designer file if a *.resx ressource file has been updated.
# However, it is recommended to use Visual Studio instead for editing ressources instead since it takes of that automatically and prodcues cleaner diffs.
#>
Expand Down
2 changes: 1 addition & 1 deletion NuGet.Config
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<packageSources>
<clear />
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<Project Sdk="Microsoft.NET.Sdk">
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<VersionPrefix>1.19.1</VersionPrefix>
Expand Down