From 405dce12502cefc16d89c1cd9bdee55a16a441b0 Mon Sep 17 00:00:00 2001 From: David Schroeder Date: Fri, 26 Jan 2024 16:43:32 -0600 Subject: [PATCH] Update get-snapshots.ps1 --- esxi-scripts/get-snapshots.ps1 | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/esxi-scripts/get-snapshots.ps1 b/esxi-scripts/get-snapshots.ps1 index 494efc06..2f97b4fa 100755 --- a/esxi-scripts/get-snapshots.ps1 +++ b/esxi-scripts/get-snapshots.ps1 @@ -4,13 +4,13 @@ Connect-VIServer -Server $VCENTERHOST -Protocol https -User $VCENTERUSER -Password $VCENTERPASS | Out-Null -write-host "\033[2K\e[0K\r" -NoNewline -write-host "Gathering Snapshots ..." +echo -en "\033[2K\e[0K\r" -NoNewline +echo -en "Gathering Snapshots ..." $snapshots = get-vm | get-snapshot | where {($_.vm -notlike '*_replica')} | select vm, name, description, created, sizegb # get-vm | get-snapshot | where {($_.vm -notlike '*_replica')} | select vm, name, description, created, sizegb | ConvertTo-Json -Depth 1 -WarningAction:SilentlyContinue -write-host "\033[2K\e[0K\r" -NoNewline -write-host $snapshots +echo -en "\033[2K\e[0K\r" +echo -e "$snapshots" Disconnect-VIServer -Server $VCENTERHOST -Force –Confirm:$false