Skip to content

Commit 27d341c

Browse files
committed
docs(cli): update commands descriptions
1 parent 91d32a2 commit 27d341c

File tree

7 files changed

+14
-23
lines changed

7 files changed

+14
-23
lines changed

internal/cli/commands/delete.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ func WithDeleteServer(server *config.Server) DeleteOption {
4141
func NewDeleteCmd() *cobra.Command {
4242
cmd := &cobra.Command{
4343
Use: "delete <branch-name>",
44-
Short: "Delete a database branch",
44+
Short: "Delete a branch",
4545
Args: cobra.ExactArgs(1),
4646
RunE: func(cmd *cobra.Command, args []string) error {
4747
return runDelete(args[0])

internal/cli/commands/init.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ func WithSkipBrowser(skip bool) InitOption {
2828
func NewInitCmd() *cobra.Command {
2929
return &cobra.Command{
3030
Use: "init <ip-address>",
31-
Short: "Init a new branchd server",
31+
Short: "Setup a new branchd server",
3232
Args: cobra.ExactArgs(1),
3333
RunE: runInit,
3434
}

internal/cli/commands/list.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ func NewListCmd() *cobra.Command {
5252
cmd := &cobra.Command{
5353
Use: "ls",
5454
Aliases: []string{"list"},
55-
Short: "List all branches",
55+
Short: "List branches",
5656
RunE: func(cmd *cobra.Command, args []string) error {
5757
return runList()
5858
},

internal/cli/commands/login.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ func NewLoginCmd() *cobra.Command {
5959

6060
cmd := &cobra.Command{
6161
Use: "login",
62-
Short: "Authenticate with a Branchd server",
62+
Short: "Login to a branchd server",
6363
RunE: func(cmd *cobra.Command, args []string) error {
6464
return runLogin(email, password)
6565
},

internal/cli/commands/select_server.go

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -13,16 +13,15 @@ import (
1313
func NewSelectServerCmd() *cobra.Command {
1414
cmd := &cobra.Command{
1515
Use: "select-server [ip-or-alias]",
16-
Short: "Select the default server to use for commands",
17-
Long: `Select the default server to use for commands.
16+
Short: "Select the server to use for commands",
17+
Long: `Select the server to use for commands.
1818
19-
If no IP or alias is provided, an interactive prompt will be shown.
20-
Otherwise, you can directly specify a server by its IP address or alias.
19+
If no param is provided, an interactive prompt will be shown.
2120
2221
Examples:
23-
branchd select-server # Interactive selection
24-
branchd select-server 192.168.1.1 # Select by IP
25-
branchd select-server production # Select by alias`,
22+
$ branchd select-server # Interactive selection
23+
$ branchd select-server 192.168.1.1 # Select by IP
24+
$ branchd select-server production # Select by alias`,
2625
Args: cobra.MaximumNArgs(1),
2726
RunE: func(cmd *cobra.Command, args []string) error {
2827
var ipOrAlias string

internal/cli/commands/update_server.go

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,7 @@ import (
1212
func NewUpdateServerCmd() *cobra.Command {
1313
cmd := &cobra.Command{
1414
Use: "update-server",
15-
Short: "Update the Branchd server to the latest version",
16-
Long: `Triggers a server update on all configured servers.
17-
18-
The server will download the latest release, stop services, install new binaries,
19-
and restart automatically. This takes approximately 1 minute.`,
15+
Short: "Update all branchd servers version",
2016
RunE: func(cmd *cobra.Command, args []string) error {
2117
return runUpdateServer()
2218
},

internal/cli/root.go

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,8 @@ import (
1212
var version = "dev" // Will be set during build
1313

1414
var rootCmd = &cobra.Command{
15-
Use: "branchd",
16-
Short: "Branchd - Database branching for PostgreSQL",
17-
Long: `Branchd CLI - Manage your database branches with ease.
18-
19-
Branchd uses ZFS copy-on-write snapshots to create instant database branches
20-
for development, testing, and PR environments.`,
15+
Use: "branchd",
16+
Short: "PostgreSQL database branching",
2117
SilenceUsage: true,
2218
SilenceErrors: true,
2319
PersistentPreRun: func(cmd *cobra.Command, args []string) {
@@ -35,7 +31,7 @@ func init() {
3531
// Add version command
3632
rootCmd.AddCommand(&cobra.Command{
3733
Use: "version",
38-
Short: "Print the version number",
34+
Short: "Show version",
3935
Run: func(cmd *cobra.Command, args []string) {
4036
fmt.Printf("branchd version %s\n", version)
4137
},

0 commit comments

Comments
 (0)