mirror of
https://github.com/rbalsleyMSFT/FFU.git
synced 2026-06-14 02:09:35 -06:00
update issue with downloading latest Windows CU
This commit is contained in:
@@ -2039,7 +2039,7 @@ if ($InstallApps) {
|
|||||||
#Update Latest Defender Platform and Definitions - these can't be serviced into the VHDX, will be saved to AppsPath
|
#Update Latest Defender Platform and Definitions - these can't be serviced into the VHDX, will be saved to AppsPath
|
||||||
if ($UpdateLatestDefender) {
|
if ($UpdateLatestDefender) {
|
||||||
WriteLog "`$UpdateLatestDefender is set to true, checking for latest Defender Platform and Definitions"
|
WriteLog "`$UpdateLatestDefender is set to true, checking for latest Defender Platform and Definitions"
|
||||||
$Name = 'Update for Microsoft Defender Antivirus antimalware platform'
|
$Name = "Update for Microsoft Defender Antivirus antimalware platform"
|
||||||
#Check if $DefenderPath exists, if not, create it
|
#Check if $DefenderPath exists, if not, create it
|
||||||
If (-not (Test-Path -Path $DefenderPath)) {
|
If (-not (Test-Path -Path $DefenderPath)) {
|
||||||
WriteLog "Creating $DefenderPath"
|
WriteLog "Creating $DefenderPath"
|
||||||
@@ -2104,7 +2104,7 @@ if ($InstallApps) {
|
|||||||
$OneDriveURL = 'https://go.microsoft.com/fwlink/?linkid=844652'
|
$OneDriveURL = 'https://go.microsoft.com/fwlink/?linkid=844652'
|
||||||
try {
|
try {
|
||||||
Start-BitsTransfer -Source $OneDriveURL -Destination "$OneDrivePath\OneDriveSetup.exe"
|
Start-BitsTransfer -Source $OneDriveURL -Destination "$OneDrivePath\OneDriveSetup.exe"
|
||||||
WriteLog "Defender Definitions downloaded to $OneDrivePath\OneDriveSetup.exe"
|
WriteLog "OneDrive client downloaded to $OneDrivePath\OneDriveSetup.exe"
|
||||||
}
|
}
|
||||||
catch {
|
catch {
|
||||||
Write-Host "Downloading OneDrive client Failed"
|
Write-Host "Downloading OneDrive client Failed"
|
||||||
@@ -2196,7 +2196,7 @@ try {
|
|||||||
#The Windows release info page is updated later than the MU Catalog
|
#The Windows release info page is updated later than the MU Catalog
|
||||||
if ($UpdateLatestCU) {
|
if ($UpdateLatestCU) {
|
||||||
Writelog "`$UpdateLatestCU is set to true, checking for latest CU"
|
Writelog "`$UpdateLatestCU is set to true, checking for latest CU"
|
||||||
$Name = "Cumulative update for Windows $WindowsRelease Version $WindowsVersion for $WindowsArch"
|
$Name = """Cumulative update for Windows $WindowsRelease Version $WindowsVersion for $WindowsArch"""
|
||||||
#Check if $KBPath exists, if not, create it
|
#Check if $KBPath exists, if not, create it
|
||||||
If (-not (Test-Path -Path $KBPath)) {
|
If (-not (Test-Path -Path $KBPath)) {
|
||||||
WriteLog "Creating $KBPath"
|
WriteLog "Creating $KBPath"
|
||||||
@@ -2211,7 +2211,7 @@ try {
|
|||||||
#Update Latest .NET Framework
|
#Update Latest .NET Framework
|
||||||
if ($UpdateLatestNet) {
|
if ($UpdateLatestNet) {
|
||||||
Writelog "`$UpdateLatestNet is set to true, checking for latest .NET Framework"
|
Writelog "`$UpdateLatestNet is set to true, checking for latest .NET Framework"
|
||||||
$Name = "Cumulative update for .net framework windows $WindowsRelease $WindowsVersion $WindowsArch"
|
$Name = "Cumulative update for .net framework windows $WindowsRelease $WindowsVersion $WindowsArch -preview"
|
||||||
#Check if $KBPath exists, if not, create it
|
#Check if $KBPath exists, if not, create it
|
||||||
If (-not (Test-Path -Path $KBPath)) {
|
If (-not (Test-Path -Path $KBPath)) {
|
||||||
WriteLog "Creating $KBPath"
|
WriteLog "Creating $KBPath"
|
||||||
|
|||||||
@@ -117,7 +117,7 @@ $LogFileName = 'ScriptLog.txt'
|
|||||||
$USBDrive = Get-USBDrive
|
$USBDrive = Get-USBDrive
|
||||||
New-item -Path $USBDrive -Name $LogFileName -ItemType "file" -Force | Out-Null
|
New-item -Path $USBDrive -Name $LogFileName -ItemType "file" -Force | Out-Null
|
||||||
$LogFile = $USBDrive + $LogFilename
|
$LogFile = $USBDrive + $LogFilename
|
||||||
$version = '2404.2'
|
$version = '2404.3'
|
||||||
WriteLog 'Begin Logging'
|
WriteLog 'Begin Logging'
|
||||||
WriteLog "Script version: $version"
|
WriteLog "Script version: $version"
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user