mirror of
https://github.com/apple/container.git
synced 2026-09-22 07:35:36 +00:00
UX: fix typos, grammar and consistency issues (#845)
Fixes several typos, grammatical errors, and consistency issues to make the UX smoother :)
This commit is contained in:
@@ -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")
|
||||
|
||||
@@ -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 {
|
||||
|
||||
@@ -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")
|
||||
}
|
||||
}
|
||||
|
||||
@@ -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: ","))")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -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")
|
||||
@@ -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")
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -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
|
||||
@@ -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")
|
||||
@@ -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)
|
||||
}
|
||||
}
|
||||
@@ -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() {}
|
||||
|
||||
@@ -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")
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -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?
|
||||
|
||||
@@ -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?
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -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")
|
||||
|
||||
@@ -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() {}
|
||||
|
||||
@@ -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`
|
||||
@@ -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**
|
||||
|
||||
@@ -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)`
|
||||
@@ -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**
|
||||
|
||||
@@ -502,7 +502,7 @@ container image delete [--all] [--debug] [<images> ...]
|
||||
|
||||
**Options**
|
||||
|
||||
* `-a, --all`: Remove all images
|
||||
* `-a, --all`: Delete all images
|
||||
|
||||
### `container image prune`
|
||||
|
||||
@@ -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**
|
||||
|
||||
@@ -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**
|
||||
|
||||
|
||||
Reference in New Issue
Block a user