Skip to content

Commit 3b6a556

Browse files
committed
cli/command: remove exported "RunPrune" functions
These are no longer used, and unlikely to be used externally. Signed-off-by: Sebastiaan van Stijn <[email protected]>
1 parent bf8cb43 commit 3b6a556

File tree

5 files changed

+0
-40
lines changed

5 files changed

+0
-40
lines changed

cli/command/builder/prune.go

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -117,13 +117,6 @@ type errNotImplemented struct{ error }
117117

118118
func (errNotImplemented) NotImplemented() {}
119119

120-
// CachePrune executes a prune command for build cache
121-
//
122-
// Deprecated: this function was only used internally and will be removed in the next release.
123-
func CachePrune(ctx context.Context, dockerCli command.Cli, all bool, filter opts.FilterOpt) (uint64, string, error) {
124-
return runPrune(ctx, dockerCli, pruneOptions{force: true, all: all, filter: filter})
125-
}
126-
127120
// pruneFn prunes the build cache for use in "docker system prune" and
128121
// returns the amount of space reclaimed and a detailed output string.
129122
func pruneFn(ctx context.Context, dockerCLI command.Cli, options pruner.PruneOptions) (uint64, string, error) {

cli/command/container/prune.go

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -93,14 +93,6 @@ type cancelledErr struct{ error }
9393

9494
func (cancelledErr) Cancelled() {}
9595

96-
// RunPrune calls the Container Prune API
97-
// This returns the amount of space reclaimed and a detailed output string
98-
//
99-
// Deprecated: this function was only used internally and will be removed in the next release.
100-
func RunPrune(ctx context.Context, dockerCli command.Cli, _ bool, filter opts.FilterOpt) (uint64, string, error) {
101-
return runPrune(ctx, dockerCli, pruneOptions{force: true, filter: filter})
102-
}
103-
10496
// pruneFn calls the Container Prune API for use in "docker system prune",
10597
// and returns the amount of space reclaimed and a detailed output string.
10698
func pruneFn(ctx context.Context, dockerCLI command.Cli, options pruner.PruneOptions) (uint64, string, error) {

cli/command/image/prune.go

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -117,14 +117,6 @@ type cancelledErr struct{ error }
117117

118118
func (cancelledErr) Cancelled() {}
119119

120-
// RunPrune calls the Image Prune API
121-
// This returns the amount of space reclaimed and a detailed output string
122-
//
123-
// Deprecated: this function was only used internally and will be removed in the next release.
124-
func RunPrune(ctx context.Context, dockerCli command.Cli, all bool, filter opts.FilterOpt) (uint64, string, error) {
125-
return runPrune(ctx, dockerCli, pruneOptions{force: true, all: all, filter: filter})
126-
}
127-
128120
// pruneFn calls the Image Prune API for use in "docker system prune",
129121
// and returns the amount of space reclaimed and a detailed output string.
130122
func pruneFn(ctx context.Context, dockerCLI command.Cli, options pruner.PruneOptions) (uint64, string, error) {

cli/command/network/prune.go

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -88,15 +88,6 @@ type cancelledErr struct{ error }
8888

8989
func (cancelledErr) Cancelled() {}
9090

91-
// RunPrune calls the Network Prune API
92-
// This returns the amount of space reclaimed and a detailed output string
93-
//
94-
// Deprecated: this function was only used internally and will be removed in the next release.
95-
func RunPrune(ctx context.Context, dockerCli command.Cli, _ bool, filter opts.FilterOpt) (uint64, string, error) {
96-
output, err := runPrune(ctx, dockerCli, pruneOptions{force: true, filter: filter})
97-
return 0, output, err
98-
}
99-
10091
// pruneFn calls the Network Prune API for use in "docker system prune"
10192
// and returns the amount of space reclaimed and a detailed output string.
10293
func pruneFn(ctx context.Context, dockerCLI command.Cli, options pruner.PruneOptions) (uint64, string, error) {

cli/command/volume/prune.go

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -118,14 +118,6 @@ type cancelledErr struct{ error }
118118

119119
func (cancelledErr) Cancelled() {}
120120

121-
// RunPrune calls the Volume Prune API
122-
// This returns the amount of space reclaimed and a detailed output string
123-
//
124-
// Deprecated: this function was only used internally and will be removed in the next release.
125-
func RunPrune(ctx context.Context, dockerCli command.Cli, _ bool, filter opts.FilterOpt) (uint64, string, error) {
126-
return runPrune(ctx, dockerCli, pruneOptions{force: true, filter: filter})
127-
}
128-
129121
// pruneFn calls the Volume Prune API for use in "docker system prune",
130122
// and returns the amount of space reclaimed and a detailed output string.
131123
func pruneFn(ctx context.Context, dockerCli command.Cli, options pruner.PruneOptions) (uint64, string, error) {

0 commit comments

Comments
 (0)