added session key to other bw commands and commented out too

This commit is contained in:
2021-11-23 15:05:43 -05:00
parent 4c4037ba52
commit 03dac4bfa7

View File

@@ -22,10 +22,10 @@ bw export $password --output "$PSScriptRoot\Bitwarden User $username Export $dat
bw export $password --output "$PSScriptRoot\Bitwarden User $username Export $dateTime.json" --format json --session $sessionKey
Write-Host "Looking for Organizations..."
$organizations = $(convertfrom-json $(bw list organizations))
$organizations = $(convertfrom-json $(bw list organizations --session $sessionKey))
Write-Host "Found $(($organizations | measure).count) Organiztaions."
# (convertfrom-json $(bw list items)) | where attachments
# $itemsWithAttachments | % { $folder=$_.name; $itemID=$_.id; $_.attachments | % { bw get attachment $_.id --itemid $itemID --output "C:\Users\jgaunt\3D Objects\Bitwarden\$folder\$_.fileName"; sleep -Milliseconds 500 } }
# bw get attachment $attachmentID --itemid $itemID --output $file
# (convertfrom-json $(bw list items --session $sessionKey)) | where attachments
# $itemsWithAttachments | % { $folder=$_.name; $itemID=$_.id; $_.attachments | % { bw get attachment $_.id --itemid $itemID --output "C:\Users\jgaunt\3D Objects\Bitwarden\$folder\$_.fileName" --session $sessionKey; sleep -Milliseconds 500 } }
# bw get attachment $attachmentID --itemid $itemID --output $file --session $sessionKey