PortValhalla/scripts/Windows/Software/WinSCP/Manage.ps1

21 lines
621 B
PowerShell

using namespace Microsoft.Win32;
param(
$Action,
[hashtable] $Arguments
)
. "$PSScriptRoot/../../Scripts/AppAssociations.ps1";
. "$PSScriptRoot/../../../Common/Scripts/Software.ps1";
. "$PSScriptRoot/../../../Common/Scripts/System.ps1";
Start-SoftwareInstaller @PSBoundParameters `
-Installer {
Install-ChocoPackage winscp;
} `
-Configurator {
Remove-DesktopIcon "WinSCP*";
Write-Host "Making WinSCP the default FTP program…";
Set-DefaultAppAssociation -Identifier "ftp" -ProgId "WinSCP.Url" -ApplicationName "WinSCP: SFTP, FTP, WebDAV, S3 and SCP client";
};