Add log messages
This commit is contained in:
parent
066d1b50c7
commit
6aceec31ae
|
@ -12,13 +12,17 @@ $null = New-Module {
|
||||||
function Restore-TmNations([Context] $context) {
|
function Restore-TmNations([Context] $context) {
|
||||||
$feature = "DirectPlay";
|
$feature = "DirectPlay";
|
||||||
Write-Host "Restoring TrackMania Nations Forever";
|
Write-Host "Restoring TrackMania Nations Forever";
|
||||||
|
|
||||||
if (-not (Get-WindowsOptionalFeature -Online -FeatureName $feature).State) {
|
if (-not (Get-WindowsOptionalFeature -Online -FeatureName $feature).State) {
|
||||||
|
Write-Information "Enabling the ``$feature`` feature";
|
||||||
Enable-WindowsOptionalFeature -Online -FeatureName $feature;
|
Enable-WindowsOptionalFeature -Online -FeatureName $feature;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Write-Information "Installing TrackMania Nations Forever";
|
||||||
winget install -e --id Nadeo.TrackManiaNationsForever;
|
winget install -e --id Nadeo.TrackManiaNationsForever;
|
||||||
|
Write-Information "Removing Desktop Icon";
|
||||||
Remove-Item "$env:PUBLIC\Desktop\*TmNationsForever*";
|
Remove-Item "$env:PUBLIC\Desktop\*TmNationsForever*";
|
||||||
|
Write-Information "Restoring Files";
|
||||||
$context.Restore($context.SoftwareArchive($softwareName), $path);
|
$context.Restore($context.SoftwareArchive($softwareName), $path);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue