From: Fabian Ebner <f.ebner@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [pve-devel] [PATCH storage 2/2] prune_backups CLI: print different message when there's no backups at all
Date: Thu, 20 Aug 2020 13:50:10 +0200 [thread overview]
Message-ID: <20200820115010.14106-2-f.ebner@proxmox.com> (raw)
In-Reply-To: <20200820115010.14106-1-f.ebner@proxmox.com>
Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
---
Otherwise it looks strange IMHO
PVE/CLI/pvesm.pm | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/PVE/CLI/pvesm.pm b/PVE/CLI/pvesm.pm
index 93ef977..caac51b 100755
--- a/PVE/CLI/pvesm.pm
+++ b/PVE/CLI/pvesm.pm
@@ -932,6 +932,11 @@ our $cmddef = {
return if !$dryrun;
+ if (!scalar(@{$list})) {
+ print "No backups found\n";
+ return;
+ }
+
print "NOTE: this is only a preview and might not be what a subsequent\n" .
"prune call does if backups are removed/added in the meantime.\n\n";
--
2.20.1
next prev parent reply other threads:[~2020-08-20 11:50 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-08-20 11:50 [pve-devel] [PATCH storage 1/2] prune_backups: fix message Fabian Ebner
2020-08-20 11:50 ` Fabian Ebner [this message]
2020-08-20 15:28 ` [pve-devel] applied-series: " Thomas Lamprecht
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200820115010.14106-2-f.ebner@proxmox.com \
--to=f.ebner@proxmox.com \
--cc=pve-devel@lists.proxmox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox