Current CLI help is difficult to read and inconsistent #9

Closed
opened 2026-03-04 08:50:00 +00:00 by kashish · 1 comment
Owner

The current help command and --help flag text for different commands is inconsistent and difficult to read.

Need to follow a consistent and readable format.

Example:

help command text

Kosh - Secure Password Manager

Usage:
kosh generate [options] <label> <user> - generate a strong password and store as credential
kosh help - show help information
kosh init - initialize vault with master password.
kosh list [--label <label>] [--user <user>] - list all credentials associated to a label or user
kosh search <label> <user> - fuzzy search a credential and copy the best match.
kosh delete <credential_id> - delete a stored credential.
kosh get <label> <user> - retrieve a stored credential
kosh update <id> - update existing credential
kosh add - add a new credential to vault

For more information, visit: https://git.plutolab.org/plutolab/kosh

update command help


Usage:
  kosh generate [options] <label> <user>

Description:
  Generate a strong random password and store it securely in the vault.
  The generated password is encrypted and copied to the clipboard.

Arguments:
  label        Identifier for the credential (must not match a command name)
  user         Username or account associated with the credential

Options:
  -length int
        Length of the generated password (default: 20)

  -upper
        Include uppercase letters (A-Z) (default: true)

  -lower
        Include lowercase letters (a-z) (default: true)

  -digit
        Include digits (0-9) (default: true)

  -symbol
        Include special symbols (!@#$%^&*()-_=+[]{}<>?/|) (default: true)

  -require string
        Enforce minimum character counts per group.
        Format: group=count[,group=count...]

        Valid groups:
          lower    lowercase letters
          upper    uppercase letters
          digit    digits
          symbol   special symbols

        Example:
          -require "upper=2,digit=3,symbol=1"

Behavior:
  • If required characters exceed the password length, you will be prompted
    to increase the length automatically.
  • If a credential with the same label and user exists, overwrite confirmation
    is required.
  • Master password verification is required to unlock the vault.

Examples:
  Generate a default password:
    kosh generate github alice

  Generate a 32-character password with strict requirements:
    kosh generate \
      -length 32 \
      -require "upper=2,lower=10,digit=5,symbol=3" \
      email alice

  Generate a password without symbols:
    kosh generate -symbol=false server root

list command help


List stored credentials with optional filtering

Options:
  --label <text>    Filter by label (partial match)
  --user <text>     Filter by username (partial match)
  -h, --help        Show this help

Examples:
  kosh list                                # List all credentials
  kosh list pluto                          # Search users containing 'pluto'
  kosh list --user pluto                   # Same as above
  kosh list --label github                 # Search labels containing 'github'
  kosh list --user pluto --label github    # Search users contating 'pluto' and labels containing 'github'
The current `help` command and `--help` flag text for different commands is inconsistent and difficult to read. Need to follow a consistent and readable format. Example: `help` command text ``` Kosh - Secure Password Manager Usage: kosh generate [options] <label> <user> - generate a strong password and store as credential kosh help - show help information kosh init - initialize vault with master password. kosh list [--label <label>] [--user <user>] - list all credentials associated to a label or user kosh search <label> <user> - fuzzy search a credential and copy the best match. kosh delete <credential_id> - delete a stored credential. kosh get <label> <user> - retrieve a stored credential kosh update <id> - update existing credential kosh add - add a new credential to vault For more information, visit: https://git.plutolab.org/plutolab/kosh ``` `update` command help ``` Usage: kosh generate [options] <label> <user> Description: Generate a strong random password and store it securely in the vault. The generated password is encrypted and copied to the clipboard. Arguments: label Identifier for the credential (must not match a command name) user Username or account associated with the credential Options: -length int Length of the generated password (default: 20) -upper Include uppercase letters (A-Z) (default: true) -lower Include lowercase letters (a-z) (default: true) -digit Include digits (0-9) (default: true) -symbol Include special symbols (!@#$%^&*()-_=+[]{}<>?/|) (default: true) -require string Enforce minimum character counts per group. Format: group=count[,group=count...] Valid groups: lower lowercase letters upper uppercase letters digit digits symbol special symbols Example: -require "upper=2,digit=3,symbol=1" Behavior: • If required characters exceed the password length, you will be prompted to increase the length automatically. • If a credential with the same label and user exists, overwrite confirmation is required. • Master password verification is required to unlock the vault. Examples: Generate a default password: kosh generate github alice Generate a 32-character password with strict requirements: kosh generate \ -length 32 \ -require "upper=2,lower=10,digit=5,symbol=3" \ email alice Generate a password without symbols: kosh generate -symbol=false server root ``` `list` command help ``` List stored credentials with optional filtering Options: --label <text> Filter by label (partial match) --user <text> Filter by username (partial match) -h, --help Show this help Examples: kosh list # List all credentials kosh list pluto # Search users containing 'pluto' kosh list --user pluto # Same as above kosh list --label github # Search labels containing 'github' kosh list --user pluto --label github # Search users contating 'pluto' and labels containing 'github' ```
kashish self-assigned this 2026-03-04 08:50:00 +00:00
Author
Owner

Fixed in release v0.2.0, by moving to Cobra CLI Framework.

Fixed in release v0.2.0, by moving to Cobra CLI Framework.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
plutolab/kosh#9
No description provided.