To Bypass the Policy once in the PowerShell session:
Set-ExecutionPolicy -Scope Process -ExecutionPolicy Bypass
The above command sets the execution policy to bypass for the current PowerShell session. You need not to worry as once the current Powershell window will be closed, the next PowerShell session will open with the default execution policy. “Bypass” clears the blocked scripts with no warnings, prompts to be displayed.
Now try re-running the .ps1 Script and it must run successfully.
Thanks a ton for reading my above blog. If you have any comments, suggestions, or feedback please spare a second to post it.