Add backup support for ManiaPlanet
This commit is contained in:
parent
25a43268c9
commit
a51999007e
|
@ -3,13 +3,42 @@ param(
|
||||||
[hashtable] $Arguments
|
[hashtable] $Arguments
|
||||||
)
|
)
|
||||||
|
|
||||||
|
& {
|
||||||
|
param($Parameters)
|
||||||
|
. "$PSScriptRoot/../../Scripts/Restoration.ps1";
|
||||||
. "$PSScriptRoot/../../../Common/Scripts/Software.ps1";
|
. "$PSScriptRoot/../../../Common/Scripts/Software.ps1";
|
||||||
. "$PSScriptRoot/../../../Common/Scripts/System.ps1";
|
. "$PSScriptRoot/../../../Common/Scripts/System.ps1";
|
||||||
|
$path = "$HOME/Documents/ManiaPlanet";
|
||||||
|
|
||||||
Start-SoftwareInstaller @PSBoundParameters `
|
Start-SoftwareInstaller @Parameters `
|
||||||
-Installer {
|
-Installer {
|
||||||
Install-WingetPackage Nadeo.ManiaPlanet;
|
Install-WingetPackage Nadeo.ManiaPlanet;
|
||||||
Remove-DesktopIcon "ManiaPlanet*";
|
Remove-DesktopIcon "ManiaPlanet*";
|
||||||
};
|
} `
|
||||||
|
-UserBackup {
|
||||||
|
param(
|
||||||
|
[hashtable] $Arguments
|
||||||
|
)
|
||||||
|
|
||||||
# ToDo: Add restoration
|
Add-BackupArtifacts -User $Arguments.Name -Source $path -Path "ManiaPlanet" `
|
||||||
|
-Include @(
|
||||||
|
"Actions",
|
||||||
|
"Blocks",
|
||||||
|
"Items",
|
||||||
|
"Maps",
|
||||||
|
"Media",
|
||||||
|
"Modules",
|
||||||
|
"Packs",
|
||||||
|
"Replays",
|
||||||
|
"Scripts",
|
||||||
|
"Skins"
|
||||||
|
);
|
||||||
|
} `
|
||||||
|
-UserConfigurator {
|
||||||
|
param(
|
||||||
|
[hashtable] $Arguments
|
||||||
|
)
|
||||||
|
|
||||||
|
Expand-BackupArtifacts -User $Arguments.Name -Path "ManiaPlanet" -Target $path;
|
||||||
|
};
|
||||||
|
} $PSBoundParameters;
|
||||||
|
|
Loading…
Reference in a new issue