Skip to content

Commit 16388f8

Browse files
help fixes
1 parent 78bacf6 commit 16388f8

File tree

7 files changed

+10
-3
lines changed

7 files changed

+10
-3
lines changed

PSFramework/functions/data/Export-PSFPowerShellDataFile.ps1

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@
3838
3939
Takes all files and folders and converts the data into psd1-style data structures, then write that to "files.psd1" in the current path..
4040
#>
41+
[Diagnostics.CodeAnalysis.SuppressMessageAttribute("PSReviewUnusedParameter", "")]
4142
[CmdletBinding()]
4243
param (
4344
[Parameter(Mandatory = $true)]
@@ -68,7 +69,7 @@
6869
$converter.Config = $Configuration
6970
$converter.Cmdlet = $PSCmdlet
7071

71-
$writer = { Set-PSFFileContent -Path $filePath -Encoding $Encoding }.GetSteppablePipeline()
72+
$writer = { Set-PSFFileContent -Path $Path -Encoding $Encoding }.GetSteppablePipeline()
7273
$writer.Begin($true)
7374
}
7475
process {

PSFramework/functions/data/Get-PSFFileContent.ps1

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,7 @@
7979
8080
Reads the bytes from the specified certificate file.
8181
#>
82+
[Diagnostics.CodeAnalysis.SuppressMessageAttribute("PSUseOutputTypeCorrectly", "")]
8283
[CmdletBinding(DefaultParameterSetName = 'Text')]
8384
param (
8485
[Parameter(Position = 0, ValueFromPipeline = $true)]

PSFramework/functions/data/Import-PSFJson.ps1

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@
5656
begin {
5757
#region Functions
5858
function ConvertTo-Hashtable {
59+
[OutputType([hashtable])]
5960
[CmdletBinding()]
6061
param (
6162
[Parameter(ValueFromPipeline = $true)]
@@ -92,6 +93,7 @@
9293
}
9394
}
9495
function Convert-JsonData {
96+
[Diagnostics.CodeAnalysis.SuppressMessageAttribute("PSUseOutputTypeCorrectly", "")]
9597
[CmdletBinding()]
9698
param (
9799
[Parameter(ValueFromPipeline = $true)]
@@ -151,6 +153,7 @@
151153
}
152154
}
153155
function ConvertFrom-JsonArray {
156+
[Diagnostics.CodeAnalysis.SuppressMessageAttribute("PSUseOutputTypeCorrectly", "")]
154157
[CmdletBinding()]
155158
param (
156159
$Data

PSFramework/functions/data/Set-PSFFileContent.ps1

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@
5555
Writes the raw certificate information as a .cer file to disk.
5656
This will result in a perfectly valid public certificate.
5757
#>
58+
[Diagnostics.CodeAnalysis.SuppressMessageAttribute("PSUseShouldProcessForStateChangingFunctions", "")]
5859
[CmdletBinding()]
5960
param (
6061
[Parameter(Mandatory = $true)]

PSFramework/functions/tabexpansion/Remove-PSFTeppCompletion.ps1

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
2222
Removes the two listed drinks from the list of legal completions.
2323
#>
24+
[Diagnostics.CodeAnalysis.SuppressMessageAttribute("PSUseShouldProcessForStateChangingFunctions", "")]
2425
[CmdletBinding()]
2526
param (
2627
[PsfArgumentCompleter('PSFramework-tepp-scriptblockname')]

PSFramework/tests/functions/parameter/PsfFile.Parameter.Tests.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@
6666
}
6767

6868
$folder = New-PSFTempDirectory -ModuleName PSFTest -Name TempFolder
69-
$folder = (Resolve-Path -LiteralPath $folder).ProviderPath
69+
$folder = (Get-Item -LiteralPath (Resolve-Path -LiteralPath $folder).ProviderPath).FullName
7070
"Test" | Set-Content -Path "$folder\test1.txt"
7171
"Test" | Set-Content -Path "$folder\test2.txt"
7272
"Test" | Set-Content -Path "$folder\test3.txt"

PSFramework/tests/general/FileIntegrity.Exceptions.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ $global:MayContainCommand = @{
2020
"Write-Host" = @('Write-PSFHostColor.ps1')
2121
"Write-Verbose" = @()
2222
"Write-Warning" = @('assembly.ps1')
23-
"Write-Error" = @('Import-PSFPowerShellDataFile.ps1', 'Invoke-PSFCommand.ps1', 'Stop-PSFFunction.ps1')
23+
"Write-Error" = @('Import-PSFJson.ps1', 'Import-PSFPowerShellDataFile.ps1', 'Invoke-PSFCommand.ps1', 'Set-PSFFileContent.ps1', 'Stop-PSFFunction.ps1')
2424
"Write-Output" = @('filesystem.provider.ps1', 'gelf.provider.ps1', 'Import-PSFPowerShellDataFile.ps1', 'logfile.provider.ps1', 'input.ps1', 'teppCoreCode.ps1')
2525
"Write-Information" = @()
2626
"Write-Debug" = @()

0 commit comments

Comments
 (0)