I was excited to see this script pop up the other day.
I suggest adding this to the header of the script:
#Requires -Version 7.2
# To use PWSH v7
# Open File > Options > Advanced > Dynamic Folder
# Set the path to "%ProgramFiles%\PowerShell\7\pwsh.exe"
$PSStyle.OutputRendering = 'PlainText' was introduced in v7.2.
Also, I am unable to get past the check for the bw executable.
If I run the following in my terminal it works fine, but setting that path in the Custom Property field it will error out.
$path = "$env:ONEDRIVECONSUMER\AppSync\RoyalTS\bw.exe"
if (!(Test-Path -Path "$($path)" -PathType Leaf)) {
Write-Error -Message "Bitwarden CLI utility not found at specified path. Please check CLI utility path in Custom Properties." -ErrorAction Stop
}
Further testing, I exported env: to a log file and it shows the correct values.
I was excited to see this script pop up the other day.
I suggest adding this to the header of the script:
$PSStyle.OutputRendering = 'PlainText'was introduced in v7.2.Also, I am unable to get past the check for the bw executable.
If I run the following in my terminal it works fine, but setting that path in the Custom Property field it will error out.
Further testing, I exported
env:to a log file and it shows the correct values.