Skip to content

Commit a4605a0

Browse files
committed
.github/workflows/Generate-TestWorkflows.ps1: Generate workflow files with no BOM
1 parent daa19d8 commit a4605a0

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

.github/workflows/Generate-TestWorkflows.ps1

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -362,7 +362,10 @@ jobs:
362362
Ensure-Directory-Exists $OutputDirectory
363363

364364
Write-Host "Generating workflow file: $FilePath"
365-
Out-File -filePath $FilePath -encoding UTF8 -inputObject $fileText
365+
366+
# Ensure the file does not get generated with a BOM
367+
$utf8NoBom = New-Object System.Text.UTF8Encoding($false)
368+
[System.IO.File]::WriteAllText($FilePath, $fileText, $utf8NoBom)
366369

367370
#Write-Host $fileText
368371
}

0 commit comments

Comments
 (0)