From 344fe0d17064ecf9a1ec92c9245c6111008fdefd Mon Sep 17 00:00:00 2001 From: CodingWonders <101426328+CodingWonders@users.noreply.github.com> Date: Sat, 23 Mar 2024 09:54:09 +0100 Subject: [PATCH] Update files Force unattended answer file to use UTF-8 encoding --- functions/private/Invoke-MicroWin-Helper.ps1 | 2 +- winutil.ps1 | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/functions/private/Invoke-MicroWin-Helper.ps1 b/functions/private/Invoke-MicroWin-Helper.ps1 index 38544a9f4b..58acf58154 100644 --- a/functions/private/Invoke-MicroWin-Helper.ps1 +++ b/functions/private/Invoke-MicroWin-Helper.ps1 @@ -377,7 +377,7 @@ function New-Unattend { # Replace the placeholder text with the Specialize pass $unattend = $unattend.Replace("<#REPLACEME#>", $specPass).Trim() } - $unattend | Out-File -FilePath "$env:temp\unattend.xml" -Force + $unattend | Out-File -FilePath "$env:temp\unattend.xml" -Force -Encoding utf8 } function New-CheckInstall { diff --git a/winutil.ps1 b/winutil.ps1 index d95c33adb5..86a4b8d5c5 100644 --- a/winutil.ps1 +++ b/winutil.ps1 @@ -10,6 +10,7 @@ Author : Chris Titus @christitustech Runspace Author: @DeveloperDurp GitHub : https://github.com/ChrisTitusTech + Version : 24.03.23 #> param ( [switch]$Debug, @@ -46,7 +47,7 @@ Add-Type -AssemblyName System.Windows.Forms # Variable to sync between runspaces $sync = [Hashtable]::Synchronized(@{}) $sync.PSScriptRoot = $PSScriptRoot -$sync.version = "24.03.21" +$sync.version = "24.03.23" $sync.configs = @{} $sync.ProcessRunning = $false @@ -1109,7 +1110,7 @@ function New-Unattend { # Replace the placeholder text with the Specialize pass $unattend = $unattend.Replace("<#REPLACEME#>", $specPass).Trim() } - $unattend | Out-File -FilePath "$env:temp\unattend.xml" -Force + $unattend | Out-File -FilePath "$env:temp\unattend.xml" -Force -Encoding utf8 } function New-CheckInstall {