Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Sources/ContainerCommands/Container/ContainerDelete.swift
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ extension Application {
abstract: "Delete one or more containers",
aliases: ["rm"])

@Flag(name: .shortAndLong, help: "Remove all containers")
@Flag(name: .shortAndLong, help: "Delete all containers")
var all = false

@Flag(name: .shortAndLong, help: "Delete containers even if they are running")
Expand Down
2 changes: 1 addition & 1 deletion Sources/ContainerCommands/Container/ContainerInspect.swift
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ extension Application {
@OptionGroup
var global: Flags.Global

@Argument(help: "Container IDs")
@Argument(help: "Container IDs to inspect")
var containerIds: [String]

public func run() async throws {
Expand Down
4 changes: 2 additions & 2 deletions Sources/ContainerCommands/Container/ContainerKill.swift
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ extension Application {
throw ContainerizationError(.invalidArgument, message: "no containers specified and --all not supplied")
}
if containerIds.count > 0 && all {
throw ContainerizationError(.invalidArgument, message: "explicitly supplied container IDs conflicts with the --all flag")
throw ContainerizationError(.invalidArgument, message: "explicitly supplied container IDs conflict with the --all flag")
}
}

Expand Down Expand Up @@ -74,7 +74,7 @@ extension Application {
}
}
if failed.count > 0 {
throw ContainerizationError(.internalError, message: "kill failed for one or more containers")
throw ContainerizationError(.internalError, message: "kill failed for one or more containers \(failed.joined(separator: ","))")
}
}
}
Expand Down
4 changes: 2 additions & 2 deletions Sources/ContainerCommands/Container/ContainerStop.swift
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ extension Application {
@Flag(name: .shortAndLong, help: "Stop all running containers")
var all = false

@Option(name: .shortAndLong, help: "Signal to send the containers")
@Option(name: .shortAndLong, help: "Signal to send to the containers")
var signal: String = "SIGTERM"

@Option(name: .shortAndLong, help: "Seconds to wait before killing the containers")
Expand All @@ -49,7 +49,7 @@ extension Application {
}
if containerIds.count > 0 && all {
throw ContainerizationError(
.invalidArgument, message: "explicitly supplied container IDs conflicts with the --all flag")
.invalidArgument, message: "explicitly supplied container IDs conflict with the --all flag")
}
}

Expand Down
8 changes: 4 additions & 4 deletions Sources/ContainerCommands/Image/ImageDelete.swift
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ extension Application {
public struct RemoveImageOptions: ParsableArguments {
public init() {}

@Flag(name: .shortAndLong, help: "Remove all images")
@Flag(name: .shortAndLong, help: "Delete all images")
var all: Bool = false

@OptionGroup
Expand All @@ -37,7 +37,7 @@ extension Application {
struct DeleteImageImplementation {
static func validate(options: RemoveImageOptions) throws {
if options.images.count == 0 && !options.all {
throw ContainerizationError(.invalidArgument, message: "no image specified and --all not supplied")
throw ContainerizationError(.invalidArgument, message: "no images specified and --all not supplied")
}
if options.images.count > 0 && options.all {
throw ContainerizationError(.invalidArgument, message: "explicitly supplied images conflict with the --all flag")
Expand All @@ -64,7 +64,7 @@ extension Application {
print(image.reference)
didDeleteAnyImage = true
} catch {
log.error("failed to remove \(image.reference): \(error)")
log.error("failed to delete \(image.reference): \(error)")
failures.append(image.reference)
}
}
Expand All @@ -87,7 +87,7 @@ extension Application {

public static let configuration = CommandConfiguration(
commandName: "delete",
abstract: "Remove one or more images",
abstract: "Delete one or more images",
aliases: ["rm"])

public init() {}
Expand Down
4 changes: 2 additions & 2 deletions Sources/ContainerCommands/Image/ImageList.swift
Original file line number Diff line number Diff line change
Expand Up @@ -146,11 +146,11 @@ extension Application {

static func validate(options: ListImageOptions) throws {
if options.quiet && options.verbose {
throw ContainerizationError(.invalidArgument, message: "cannot use flag --quite and --verbose together")
throw ContainerizationError(.invalidArgument, message: "cannot use flag --quiet and --verbose together")
}
let modifier = options.quiet || options.verbose
if modifier && options.format == .json {
throw ContainerizationError(.invalidArgument, message: "cannot use flag --quite or --verbose along with --format json")
throw ContainerizationError(.invalidArgument, message: "cannot use flag --quiet or --verbose along with --format json")
}
}

Expand Down
2 changes: 1 addition & 1 deletion Sources/ContainerCommands/Image/ImagePush.swift
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ extension Application {
var progressFlags: Flags.Progress

@Option(
name: [.customLong("arch"), .customShort("a")],
name: .shortAndLong,
help: "Limit the push to the specified architecture"
)
var arch: String?
Expand Down
4 changes: 2 additions & 2 deletions Sources/ContainerCommands/Image/ImageSave.swift
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,11 @@ extension Application {
public init() {}
public static let configuration = CommandConfiguration(
commandName: "save",
abstract: "Save an image as an OCI compatible tar archive"
abstract: "Save one or more images as an OCI compatible tar archive"
)

@Option(
name: [.customLong("arch"), .customShort("a")],
name: .shortAndLong,
help: "Architecture for the saved image"
)
var arch: String?
Expand Down
4 changes: 2 additions & 2 deletions Sources/ContainerCommands/Image/ImageTag.swift
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,10 @@ extension Application {
commandName: "tag",
abstract: "Create a new reference for an existing image")

@Argument(help: "the existing image reference (format: image-name[:tag])")
@Argument(help: "The existing image reference (format: image-name[:tag])")
var source: String

@Argument(help: "the new image reference")
@Argument(help: "The new image reference")
var target: String

@OptionGroup
Expand Down
2 changes: 1 addition & 1 deletion Sources/ContainerCommands/Volume/VolumeCreate.swift
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ extension Application.VolumeCommand {
public struct VolumeCreate: AsyncParsableCommand {
public static let configuration = CommandConfiguration(
commandName: "create",
abstract: "Create a volume"
abstract: "Create a new volume"
)

@Option(name: .customLong("label"), help: "Set metadata for a volume")
Expand Down
2 changes: 1 addition & 1 deletion Sources/ContainerCommands/Volume/VolumeInspect.swift
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ extension Application.VolumeCommand {
@OptionGroup
var global: Flags.Global

@Argument(help: "Volume names")
@Argument(help: "Volumes to inspect")
var names: [String]

public init() {}
Expand Down
14 changes: 7 additions & 7 deletions docs/command-reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,7 @@ container stop [--all] [--signal <signal>] [--time <time>] [--debug] [<container
**Options**

* `-a, --all`: Stop all running containers
* `-s, --signal <signal>`: Signal to send the containers (default: SIGTERM)
* `-s, --signal <signal>`: Signal to send to the containers (default: SIGTERM)
* `-t, --time <time>`: Seconds to wait before killing the containers (default: 5)

### `container kill`
Expand All @@ -273,7 +273,7 @@ container kill [--all] [--signal <signal>] [--debug] [<container-ids> ...]

### `container delete (rm)`

Removes one or more containers. If the container is running, you may force deletion with `--force`. Without a container ID, nothing happens unless `--all` is supplied.
Deletes one or more containers. If the container is running, you may force deletion with `--force`. Without a container ID, nothing happens unless `--all` is supplied.

**Usage**

Expand All @@ -287,7 +287,7 @@ container delete [--all] [--force] [--debug] [<container-ids> ...]

**Options**

* `-a, --all`: Remove all containers
* `-a, --all`: Delete all containers
* `-f, --force`: Delete containers even if they are running

### `container list (ls)`
Expand Down Expand Up @@ -488,7 +488,7 @@ No options.

### `container image delete (rm)`

Removes one or more images. If no images are provided, `--all` can be used to remove all images. Images currently referenced by running containers cannot be deleted without first removing those containers.
Deletes one or more images. If no images are provided, `--all` can be used to delete all images. Images currently referenced by running containers cannot be deleted without first removing those containers.

**Usage**

Expand All @@ -502,7 +502,7 @@ container image delete [--all] [--debug] [<images> ...]

**Options**

* `-a, --all`: Remove all images
* `-a, --all`: Delete all images

### `container image prune`

Expand Down Expand Up @@ -586,7 +586,7 @@ No options.

### `container builder delete (rm)`

Removes the BuildKit builder container. It can optionally force deletion if the builder is still running.
Deletes the BuildKit builder container. It can optionally force deletion if the builder is still running.

**Usage**

Expand Down Expand Up @@ -715,7 +715,7 @@ container volume rm $VOL

### `container volume delete (rm)`

Removes one or more volumes by name. Volumes that are currently in use by containers (running or stopped) cannot be deleted.
Deletes one or more volumes by name. Volumes that are currently in use by containers (running or stopped) cannot be deleted.

**Usage**

Expand Down