carapace alternatives and similar packages
Based on the "Standard CLI" category.
Alternatively, view carapace alternatives based on common mentions on social networks and blogs.
-
urfave/cli
A simple, fast, and fun package for building command line apps in Go -
elvish
Elvish = Expressive Programming Language + Versatile Interactive Shell -
survey
A golang library for building interactive and accessible prompts with full support for windows and posix terminals. -
The Platinum Searcher
A code search tool similar to ack and the_silver_searcher(ag). It supports multi platforms and multi encodings. -
pflag
Drop-in replacement for Go's flag package, implementing POSIX/GNU-style --flags. -
readline
Readline is a pure go(golang) implementation for GNU-Readline kind library -
mitchellh/cli
A Go library for implementing command-line interfaces. -
complete
bash completion written in go + bash completion for go command -
flaggy
Idiomatic Go input parsing with subcommands, positional values, and flags at any position. No required project or package layout and no external dependencies. -
wmenu
An easy to use menu structure for cli applications that prompts users to make choices. -
commandeer
Automatically sets up command line flags based on struct fields and tags. -
flag
Flag is a simple but powerful command line option parsing library for Go support infinite level subcommand -
cmdr
POSIX-compliant command-line UI (CLI) parser and Hierarchical-configuration operations -
wlog
A simple logging interface that supports cross-platform color and concurrency. -
go-getoptions
Fully featured Go (golang) command line option parser with built-in auto-completion support. -
argv
A Go library to split command line string as arguments array using the bash syntax. -
Go-Console
GoConsole: the golang component that eases the creation of beautiful command line interfaces. -
command-chain
A go library for easy configure and run command chains. Such like pipelining in unix shells.
Collect and Analyze Billions of Data Points in Real Time
Do you think we are missing an alternative of carapace or a related project?
Popular Comparisons
README
carapace
Command argument completion generator for cobra. You can read more about it here: A pragmatic approach to shell completion.
Supported shells:
- Bash
- Elvish
- Fish
- Ion (experimental)
- Nushell (experimental)
- Oil
- Powershell
- Tcsh (experimental)
- Xonsh
- Zsh
Usage
Calling carapace.Gen
on the root command is sufficient to enable completion script generation using the hidden command.
import (
"github.com/rsteube/carapace"
)
carapace.Gen(rootCmd)
Standalone Mode
Carapace can also be used to provide completion for arbitrary commands as well (similar to aws_completer). See rsteube/carapace-bin for examples. There is also a binary to parse flags from gnu help pages at caraparse.
Example
An example implementation can be found in the [example](./example/) folder.
cd example
go build .
# bash
PATH=$PATH:$(pwd)
source <(example _carapace bash)
# elvish
paths=[$@paths (pwd)]
eval (example _carapace elvish | slurp)
# fish
set PATH $PATH (pwd)
example _carapace fish | source
# nushell [needs fork: https://github.com/rsteube/nushell]
example _carapace nushell | save example.nu ; nu -c 'source example.nu'
# oil
PATH=$PATH:$(pwd)
source <(example _carapace oil)
# powershell
Set-PSReadLineOption -Colors @{ "Selection" = "`e[7m" }
Set-PSReadlineKeyHandler -Key Tab -Function MenuComplete
$env:PATH += ":$pwd"
example _carapace powershell | out-string | Invoke-Expression
# tcsh
set autolist
eval `example _carapace tcsh`
# xonsh
$COMPLETION_QUERY_LIMIT = 500 # increase limit
$PATH.append($(pwd))
exec($(example _carapace xonsh))
# zsh
PATH=$PATH:$(pwd)
source <(example _carapace zsh)
example <TAB>
or use docker-compose:
docker-compose pull
docker-compose run --rm build
docker-compose run --rm [bash|elvish|fish|ion|nushell|oil|powershell|tcsh|xonsh|zsh]
example <TAB>
Projects
- carapace-bin multi-shell multi-command argument completer
- go-jira-cli simple jira command line client
- knoxite A data storage & backup system
- lab cli client for GitLab