Powershell: how can i do some command after restart?

Created on 16 Oct 2019  路  4Comments  路  Source: PowerShell/PowerShell

in the PowerShell 5 I could do that with workflow in PowerShell
but I don't know how to do that in PowerShell core.

Area-Maintainers-Documentation Issue-Question Resolution-Answered

Most helpful comment

@khoshroomahdi there are no plans to bring back PSWorkflow as workflow is not supported in .NET Core. However, the current suggested workaround is to leverage Task Scheduler to run a PowerShell script after a restart. I'll submit a PR to update that doc.

All 4 comments

@SteveL-MSFT The scenario is not addressed in docs https://docs.microsoft.com/en-us/powershell/scripting/whats-new/breaking-changes-ps6?view=powershell-6

In the future, we would like to enable native parallelism/concurrency in the PowerShell language without the need for PowerShell Workflow.

@iSazonov I think the question is about checkpoints in PowerShell workflow.
@khoshroomahdi IMO, Its never gonna come in core as is.

@kvprasoon Yes, my comment that the scenario could be in breaking change docs and maybe with a workaround.

@khoshroomahdi there are no plans to bring back PSWorkflow as workflow is not supported in .NET Core. However, the current suggested workaround is to leverage Task Scheduler to run a PowerShell script after a restart. I'll submit a PR to update that doc.

Was this page helpful?
0 / 5 - 0 ratings