From a3a66ef9722ce130aa93bdd13acf70e34eb865e8 Mon Sep 17 00:00:00 2001 From: decentral1se Date: Sun, 5 Sep 2021 01:21:16 +0200 Subject: [PATCH] docs: short aliases, short descriptions [ci skip] --- cli/app/app.go | 1 + cli/cli.go | 2 +- cli/recipe/recipe.go | 30 +++++++++++++++++++----------- cli/server/server.go | 3 ++- cli/version.go | 2 +- 5 files changed, 24 insertions(+), 14 deletions(-) diff --git a/cli/app/app.go b/cli/app/app.go index 99a0827f..d906879f 100644 --- a/cli/app/app.go +++ b/cli/app/app.go @@ -8,6 +8,7 @@ import ( var AppCommand = &cli.Command{ Name: "app", Usage: "Manage apps", + Aliases: []string{"a"}, ArgsUsage: "", Description: ` This command provides all the functionality you need to manage the life cycle diff --git a/cli/cli.go b/cli/cli.go index 97a20b1d..7e7ff450 100644 --- a/cli/cli.go +++ b/cli/cli.go @@ -39,7 +39,7 @@ var DebugFlag = &cli.BoolFlag{ // RunApp runs CLI abra app. func RunApp(version, commit string) { app := &cli.App{ - Name: "abra", + Name: "Abra", Usage: `The Co-op Cloud command-line utility belt 🎩🐇 ____ ____ _ _ diff --git a/cli/recipe/recipe.go b/cli/recipe/recipe.go index 9fd32484..6e180a8a 100644 --- a/cli/recipe/recipe.go +++ b/cli/recipe/recipe.go @@ -29,7 +29,7 @@ import ( var recipeListCommand = &cli.Command{ Name: "list", - Usage: "List all available recipes", + Usage: "List available recipes", Aliases: []string{"ls"}, Action: func(c *cli.Context) error { catl, err := catalogue.ReadRecipeCatalogue() @@ -52,7 +52,8 @@ var recipeListCommand = &cli.Command{ var recipeVersionCommand = &cli.Command{ Name: "versions", - Usage: "List available versions for ", + Usage: "List recipe versions", + Aliases: []string{"v"}, ArgsUsage: "", Action: func(c *cli.Context) error { recipe := c.Args().First() @@ -88,6 +89,7 @@ var recipeVersionCommand = &cli.Command{ var recipeCreateCommand = &cli.Command{ Name: "create", Usage: "Create a new recipe", + Aliases: []string{"c"}, ArgsUsage: "", Action: func(c *cli.Context) error { recipe := c.Args().First() @@ -154,8 +156,9 @@ var recipeCreateCommand = &cli.Command{ } var recipeUpgradeCommand = &cli.Command{ - Name: "upgrade", - Usage: "Upgrade recipe image tags", + Name: "upgrade", + Usage: "Upgrade recipe image tags", + Aliases: []string{"u"}, Description: ` This command reads and attempts to parse all image tags within the given configuration and prompt with more recent tags to upgrade to. It will @@ -286,8 +289,9 @@ This is step 1 of upgrading a recipe. Step 2 is running "abra recipe sync } var recipeSyncCommand = &cli.Command{ - Name: "sync", - Usage: "Generate recipe labels", + Name: "sync", + Usage: "Generate new recipe labels", + Aliases: []string{"s"}, Description: ` This command will generate labels for each service which correspond to the following format: @@ -355,7 +359,8 @@ the versioning metadata of up-and-running containers are. var recipeLintCommand = &cli.Command{ Name: "lint", - Usage: "Recipe configuration linter", + Usage: "Lint a recipe", + Aliases: []string{"l"}, ArgsUsage: "", Action: func(c *cli.Context) error { recipe := c.Args().First() @@ -447,11 +452,14 @@ var recipeLintCommand = &cli.Command{ // RecipeCommand defines the `abra recipe` command and ets subcommands var RecipeCommand = &cli.Command{ - Name: "recipe", - Usage: "Manage recipes", + Name: "recipe", + Usage: "Manage recipes", + ArgsUsage: "", + Aliases: []string{"r"}, Description: ` -A recipe is a blueprint for an app. It describes how to deploy and maintain an -app. +A recipe is a blueprint for an app. It is a bunch of configuration files which +describe how to deploy and maintain an app. Recipes are maintained by the Co-op +Cloud community and you can use Abra to read them and create apps for you. `, Subcommands: []*cli.Command{ recipeListCommand, diff --git a/cli/server/server.go b/cli/server/server.go index 3dc647fa..967d97b6 100644 --- a/cli/server/server.go +++ b/cli/server/server.go @@ -7,7 +7,8 @@ import ( // ServerCommand defines the `abra server` command and its subcommands var ServerCommand = &cli.Command{ Name: "server", - ArgsUsage: "", + ArgsUsage: "", + Aliases: []string{"s"}, Usage: "Manage servers", Description: ` Manage the lifecycle of a server. diff --git a/cli/version.go b/cli/version.go index 620d48c2..aff84c44 100644 --- a/cli/version.go +++ b/cli/version.go @@ -7,7 +7,7 @@ import ( // VersionCommand prints the version of abra. var VersionCommand = &cli.Command{ Name: "version", - Usage: "Print the version", + Usage: "Print version", Action: func(c *cli.Context) error { cli.VersionPrinter(c) return nil