all lists on lists.proxmox.com
 help / color / mirror / Atom feed
* [pbs-devel] [PATCH proxmox-backup] fix #6069: docs: prune simulator: allow values specifying both range and step size
@ 2025-01-14 12:10 Fiona Ebner
  2025-02-10 15:07 ` [pbs-devel] applied: " Thomas Lamprecht
  0 siblings, 1 reply; 2+ messages in thread
From: Fiona Ebner @ 2025-01-14 12:10 UTC (permalink / raw)
  To: pbs-devel

Signed-off-by: Fiona Ebner <f.ebner@proxmox.com>
---
 docs/prune-simulator/prune-simulator_source.js | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/docs/prune-simulator/prune-simulator_source.js b/docs/prune-simulator/prune-simulator_source.js
index 4bd31acd..841d183b 100644
--- a/docs/prune-simulator/prune-simulator_source.js
+++ b/docs/prune-simulator/prune-simulator_source.js
@@ -353,12 +353,17 @@ Ext.onReady(function() {
 		    specValues.forEach(function(value) {
 			if (value.includes('..')) {
 			    let [start, end] = value.split('..');
+			    let step = 1;
+			    if (end.includes('/')) {
+				[end, step] = end.split('/');
+				step = assertValid(step);
+			    }
 			    start = assertValid(start);
 			    end = assertValid(end);
 			    if (start > end) {
 				throw "interval start is bigger then interval end '" + start + " > " + end + "'";
 			    }
-			    for (let i = start; i <= end; i++) {
+			    for (let i = start; i <= end; i += step) {
 				matches[i] = 1;
 			    }
 			} else if (value.includes('/')) {
-- 
2.39.5



_______________________________________________
pbs-devel mailing list
pbs-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pbs-devel


^ permalink raw reply	[flat|nested] 2+ messages in thread

* [pbs-devel] applied: [PATCH proxmox-backup] fix #6069: docs: prune simulator: allow values specifying both range and step size
  2025-01-14 12:10 [pbs-devel] [PATCH proxmox-backup] fix #6069: docs: prune simulator: allow values specifying both range and step size Fiona Ebner
@ 2025-02-10 15:07 ` Thomas Lamprecht
  0 siblings, 0 replies; 2+ messages in thread
From: Thomas Lamprecht @ 2025-02-10 15:07 UTC (permalink / raw)
  To: Proxmox Backup Server development discussion, Fiona Ebner

Am 14.01.25 um 13:10 schrieb Fiona Ebner:
> Signed-off-by: Fiona Ebner <f.ebner@proxmox.com>
> ---
>  docs/prune-simulator/prune-simulator_source.js | 7 ++++++-
>  1 file changed, 6 insertions(+), 1 deletion(-)
> 
>

applied, thanks!

I amended the patch with some more context, partially copied from the
BZ report. Also added some reminder about hours:minutes being treated
as independent parts that have their own repetitions; that was added
mostly for myself though.


_______________________________________________
pbs-devel mailing list
pbs-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pbs-devel


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2025-02-10 15:07 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-01-14 12:10 [pbs-devel] [PATCH proxmox-backup] fix #6069: docs: prune simulator: allow values specifying both range and step size Fiona Ebner
2025-02-10 15:07 ` [pbs-devel] applied: " Thomas Lamprecht

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal