Added stage mechanism

Script can continue from different stages now
This commit is contained in:
Aaron Viehl 2022-02-06 11:31:49 +01:00
parent 4959f74e88
commit 10b44b561d
2 changed files with 108 additions and 27 deletions

View file

@ -23,13 +23,21 @@ By using `-UseSetupRemoval` the Office365 setup method will be used.
## Parameter
| Parameter | Usage |
|-------------------|-------------------------------------------------------------------------|
| -InstallOffice365 | The script will try to install the newest Office365 build after removal |
| -SuppressReboot | No reboot will be executed after script is done |
| -UseSetupRemoval | Will use the official Office365 setup instead of SaRA |
| -Force | Non-interactive - No user interaction required |
| Parameter | Usage |
|------------------------|-------------------------------------------------------------------------|
| -InstallOffice365 | The script will try to install the newest Office365 build after removal |
| -SuppressReboot | No reboot will be executed after script is done |
| -UseSetupRemoval | Will use the official Office365 setup instead of SaRA |
| -RunAgain | Will skip the stage mechanism - whole script will run again |
| -Force | Non-interactive - No user interaction required |
| -SecondsToReboot [int] | Seconds until the computer will reboot |
### Example
``.\msoffice-removal-tool.ps1 -InstallOffice365 -SuppressReboot -Force``
### Stage mechanism
To make sure that the program will only do the necessary parts a _stage mechanism_ is builtin. After every stage a registry value will be written to ``HKLM:\Software\OEM\101\M365\Install\CurrentStage``
To overwrite all stages and restart the whole script use ``-RunAgain``