diff --git a/dell-command-configure/dell-command-configure.nuspec b/dell-command-configure/dell-command-configure.nuspec index cafaa30a..ca93312d 100644 --- a/dell-command-configure/dell-command-configure.nuspec +++ b/dell-command-configure/dell-command-configure.nuspec @@ -4,7 +4,7 @@ dell-command-configure - 4.12.0 + 4.12.0.20240918 https://github.com/flcdrg/au-packages/tree/master/dell-command-configure flcdrg Dell Command | Configure (Install) @@ -25,6 +25,12 @@ Dell Command | Configure supports the following Windows operating systems: - Windows 10 - Windows Preinstallation Environment (Windows PE) +#### Package parameters + +- '/RemoveDesktopShortcut' - Remove the desktop shortcut + +Example: `choco install dell-command-configure --params="'/RemoveDesktopShortcut'"` + #### Package updates There is not currently automatic updates for this package. Either leave a comment below, use the 'Contact Maintainer' link, or create an issue in the package source GitHub repository to notify the maintainer of new versions. diff --git a/dell-command-configure/tools/chocolateyinstall.ps1 b/dell-command-configure/tools/chocolateyinstall.ps1 index a519836a..e6637f96 100644 --- a/dell-command-configure/tools/chocolateyinstall.ps1 +++ b/dell-command-configure/tools/chocolateyinstall.ps1 @@ -18,3 +18,11 @@ $packageArgs = @{ } Install-ChocolateyPackage @packageArgs + +# Remove desktop shortcut (unfortunately there is no way to disable desktop icon in installer) +$pp = Get-PackageParameters + +if ($pp['RemoveDesktopShortcut']) { + $sharedDesktop = [System.Environment]::GetFolderPath([Environment+SpecialFolder]::CommonDesktopDirectory) + Remove-Item "$sharedDesktop\Dell Command Configure Wizard.lnk" -Force -ErrorAction SilentlyContinue +}