From 892aa46f12c6cc3c72c569c2f1909d66dff64e9f Mon Sep 17 00:00:00 2001 From: Manuel Thalmann Date: Wed, 26 Jul 2023 00:15:51 +0200 Subject: [PATCH] Install software before setting associations --- scripts/Windows/OS/Install.ps1 | 5 +++-- scripts/Windows/Software/Thunderbird/Install.ps1 | 1 + scripts/Windows/Software/WinSCP/Install.ps1 | 8 ++++++++ 3 files changed, 12 insertions(+), 2 deletions(-) create mode 100644 scripts/Windows/Software/WinSCP/Install.ps1 diff --git a/scripts/Windows/OS/Install.ps1 b/scripts/Windows/OS/Install.ps1 index d8501de2..a508868c 100644 --- a/scripts/Windows/OS/Install.ps1 +++ b/scripts/Windows/OS/Install.ps1 @@ -9,6 +9,7 @@ function Invoke-WindowsInstallation([Context] $context) { if (-not $context.Get("InitialConfiguration")) { $configPath = "$PSScriptRoot/../Config"; + $softwarePath = "$PSScriptRoot/../Software"; $null = Enable-WindowsOptionalFeature -Online -All -FeatureName "NetFx3"; @@ -16,8 +17,8 @@ function Invoke-WindowsInstallation([Context] $context) . "$configPath/Explorer/Install.ps1" $context; . "$configPath/OpenSSH/Install.ps1" $context; . "$configPath/chocolatey/Install.ps1"; - . "$configPath/WinSCP/Install.ps1" $context; - . "$configPath/Thunderbird/Install.ps1" $context; + . "$softwarePath/WinSCP/Install.ps1" $context; + . "$softwarePath/Thunderbird/Install.ps1" $context; $context.RemoveDesktopIcon("*Microsoft Edge*"); $context.Set("InitialConfiguration", 1, "DWord"); diff --git a/scripts/Windows/Software/Thunderbird/Install.ps1 b/scripts/Windows/Software/Thunderbird/Install.ps1 index a66fdc76..fcd039ba 100644 --- a/scripts/Windows/Software/Thunderbird/Install.ps1 +++ b/scripts/Windows/Software/Thunderbird/Install.ps1 @@ -5,3 +5,4 @@ param($context) [Context] $context = $context; choco install -y thunderbird --params "/NoTaskbarShortcut /NoDesktopShortcut"; +. "$PSScriptRoot/../../Config/Thunderbird/Install.ps1" $context; diff --git a/scripts/Windows/Software/WinSCP/Install.ps1 b/scripts/Windows/Software/WinSCP/Install.ps1 new file mode 100644 index 00000000..6fdac5ec --- /dev/null +++ b/scripts/Windows/Software/WinSCP/Install.ps1 @@ -0,0 +1,8 @@ +#!/bin/pwsh +param($context) + +. "$PSScriptRoot/../../Scripts/Context.ps1"; +[Context] $context = $context; + +choco install -y winscp; +. "$PSScriptRoot/../../Config/WinSCP/Install.ps1" $context;