From d6c75ba2dc9039a2c9476e9520b32b83f514bc1e Mon Sep 17 00:00:00 2001 From: Michael Eischer Date: Wed, 17 Sep 2025 21:18:15 +0200 Subject: [PATCH] prune: drop unused parameter --- cmd/restic/cmd_forget.go | 2 +- cmd/restic/cmd_key_remove.go | 4 ++-- cmd/restic/cmd_prune.go | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/cmd/restic/cmd_forget.go b/cmd/restic/cmd_forget.go index 1c79cb2c0..8523b3b2d 100644 --- a/cmd/restic/cmd_forget.go +++ b/cmd/restic/cmd_forget.go @@ -347,7 +347,7 @@ func runForget(ctx context.Context, opts ForgetOptions, pruneOptions PruneOption printer.P("%d snapshots have been removed, running prune\n", len(removeSnIDs)) } pruneOptions.DryRun = opts.DryRun - return runPruneWithRepo(ctx, pruneOptions, gopts, repo, removeSnIDs, printer) + return runPruneWithRepo(ctx, pruneOptions, repo, removeSnIDs, printer) } return nil diff --git a/cmd/restic/cmd_key_remove.go b/cmd/restic/cmd_key_remove.go index e8d69074c..5adb97d80 100644 --- a/cmd/restic/cmd_key_remove.go +++ b/cmd/restic/cmd_key_remove.go @@ -51,10 +51,10 @@ func runKeyRemove(ctx context.Context, gopts GlobalOptions, args []string, term } defer unlock() - return deleteKey(ctx, repo, args[0], gopts, printer) + return deleteKey(ctx, repo, args[0], printer) } -func deleteKey(ctx context.Context, repo *repository.Repository, idPrefix string, gopts GlobalOptions, printer progress.Printer) error { +func deleteKey(ctx context.Context, repo *repository.Repository, idPrefix string, printer progress.Printer) error { id, err := restic.Find(ctx, repo, restic.KeyFile, idPrefix) if err != nil { return err diff --git a/cmd/restic/cmd_prune.go b/cmd/restic/cmd_prune.go index 64ffeea3a..479ad80af 100644 --- a/cmd/restic/cmd_prune.go +++ b/cmd/restic/cmd_prune.go @@ -183,10 +183,10 @@ func runPrune(ctx context.Context, opts PruneOptions, gopts GlobalOptions, term opts.unsafeRecovery = true } - return runPruneWithRepo(ctx, opts, gopts, repo, restic.NewIDSet(), printer) + return runPruneWithRepo(ctx, opts, repo, restic.NewIDSet(), printer) } -func runPruneWithRepo(ctx context.Context, opts PruneOptions, gopts GlobalOptions, repo *repository.Repository, ignoreSnapshots restic.IDSet, printer progress.Printer) error { +func runPruneWithRepo(ctx context.Context, opts PruneOptions, repo *repository.Repository, ignoreSnapshots restic.IDSet, printer progress.Printer) error { if repo.Cache() == nil { printer.S("warning: running prune without a cache, this may be very slow!") }