A golang library for building interactive prompts with full support for windows and posix terminals.



Build Status GoDoc

A library for building interactive prompts on terminals supporting ANSI escape sequences.

package main

import (

// the questions to ask
var qs = []*survey.Question{
        Name:     "name",
        Prompt:   &survey.Input{Message: "What is your name?"},
        Validate: survey.Required,
        Transform: survey.Title,
        Name: "color",
        Prompt: &survey.Select{
            Message: "Choose a color:",
            Options: []string{"red", "blue", "green"},
            Default: "red",
        Name: "age",
        Prompt:   &survey.Input{Message: "How old are you?"},

func main() {
    // the answers will be written to this struct
    answers := struct {
        Name          string                  // survey will match the question and field names
        FavoriteColor string `survey:"color"` // or you can tag fields to match a specific name
        Age           int                     // if the types don't match, survey will convert it

    // perform the questions
    err := survey.Ask(qs, &answers)
    if err != nil {

    fmt.Printf("%s chose %s.", answers.Name, answers.FavoriteColor)

Table of Contents

  1. Examples
  2. Running the Prompts
  3. Prompts
    1. Input
      1. Suggestion Options
    2. Multiline
    3. Password
    4. Confirm
    5. Select
    6. MultiSelect
    7. Editor
  4. Filtering Options
  5. Validation
    1. Built-in Validators
  6. Help Text
    1. Changing the input rune
  7. Changing the Icons
  8. Custom Types
  9. Testing
  10. FAQ


Examples can be found in the examples/ directory. Run them to see basic behavior:

go get github.com/AlecAivazis/survey/v2

cd $GOPATH/src/github.com/AlecAivazis/survey

go run examples/simple.go
go run examples/validation.go

Running the Prompts

There are two primary ways to execute prompts and start collecting information from your users: Ask and AskOne. The primary difference is whether you are interested in collecting a single piece of information or if you have a list of questions to ask whose answers should be collected in a single struct. For most basic usecases, Ask should be enough. However, for surveys with complicated branching logic, we recommend that you break out your questions into multiple calls to both of these functions to fit your needs.

Configuring the Prompts

Most prompts take fine-grained configuration through fields on the structs you instantiate. It is also possible to change survey's default behaviors by passing AskOpts to either Ask or AskOne. Examples in this document will do both interchangeably:

prompt := &Select{
    Message: "Choose a color:",
    Options: []string{"red", "blue", "green"},
    // can pass a validator directly
    Validate: survey.Required,

// or define a default for the single call to `AskOne`
// the answer will get written to the color variable
survey.AskOne(prompt, &color, survey.WithValidator(survey.Required))

// or define a default for every entry in a list of questions
// the answer will get copied into the matching field of the struct as shown above
survey.Ask(questions, &answers, survey.WithValidator(survey.Required))



name := ""
prompt := &survey.Input{
    Message: "ping",
survey.AskOne(prompt, &name)

Suggestion Options

file := ""
prompt := &survey.Input{
    Message: "inform a file to save:",
    Suggest: func (toComplete string) []string {
        files, _ := filepath.Glob(toComplete + "*")
        return files
survey.AskOne(prompt, &file)


text := ""
prompt := &survey.Multiline{
    Message: "ping",
survey.AskOne(prompt, &text)


password := ""
prompt := &survey.Password{
    Message: "Please type your password",
survey.AskOne(prompt, &password)


name := false
prompt := &survey.Confirm{
    Message: "Do you like pie?",
survey.AskOne(prompt, &name)


color := ""
prompt := &survey.Select{
    Message: "Choose a color:",
    Options: []string{"red", "blue", "green"},
survey.AskOne(prompt, &color)

Fields and values that come from a Select prompt can be one of two different things. If you pass an int the field will have the value of the selected index. If you instead pass a string, the string value selected will be written to the field.

The user can also press esc to toggle the ability cycle through the options with the j and k keys to do down and up respectively.

By default, the select prompt is limited to showing 7 options at a time and will paginate lists of options longer than that. This can be changed a number of ways:

// as a field on a single select
prompt := &survey.MultiSelect{..., PageSize: 10}

// or as an option to Ask or AskOne
survey.AskOne(prompt, &days, survey.WithPageSize(10))



days := []string{}
prompt := &survey.MultiSelect{
    Message: "What days do you prefer:",
    Options: []string{"Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"},
survey.AskOne(prompt, &days)

Fields and values that come from a MultiSelect prompt can be one of two different things. If you pass an int the field will have a slice of the selected indices. If you instead pass a string, a slice of the string values selected will be written to the field.

The user can also press esc to toggle the ability cycle through the options with the j and k keys to do down and up respectively.

By default, the MultiSelect prompt is limited to showing 7 options at a time and will paginate lists of options longer than that. This can be changed a number of ways:

// as a field on a single select
prompt := &survey.MultiSelect{..., PageSize: 10}

// or as an option to Ask or AskOne
survey.AskOne(prompt, &days, survey.WithPageSize(10))


Launches the user's preferred editor (defined by the $VISUAL or $EDITOR environment variables) on a temporary file. Once the user exits their editor, the contents of the temporary file are read in as the result. If neither of those are present, notepad (on Windows) or vim (Linux or Mac) is used.

You can also specify a pattern for the name of the temporary file. This can be useful for ensuring syntax highlighting matches your usecase.

prompt := &survey.Editor{
    Message: "Shell code snippet",
    FileName: "*.sh",

survey.AskOne(prompt, &content)

Filtering Options

By default, the user can filter for options in Select and MultiSelects by typing while the prompt is active. This will filter out all options that don't contain the typed string anywhere in their name, ignoring case.

A custom filter function can also be provided to change this behavior:

func myFilter(filterValue string, optValue string, optIndex int) bool {
    // only include the option if it includes the filter and has length greater than 5
    return strings.Contains(optValue, filterValue) && len(optValue) >= 5

// configure it for a specific prompt
    Message: "Choose a color:",
    Options: []string{"red", "blue", "green"},
    Filter: myFilter,

// or define a default for all of the questions
survey.AskOne(prompt, &color, survey.WithFilter(myFilter))

Keeping the filter active

By default the filter will disappear if the user selects one of the filtered elements. Once the user selects one element the filter setting is gone.

However the user can prevent this from happening and keep the filter active for multiple selections in a e.g. MultiSelect:

// configure it for a specific prompt
    Message:    "Choose a color:",
    Options:    []string{"light-green", "green", "dark-green", "red"},
    KeepFilter: true,

// or define a default for all of the questions
survey.AskOne(prompt, &color, survey.WithKeepFilter(true))


Validating individual responses for a particular question can be done by defining a Validate field on the survey.Question to be validated. This function takes an interface{} type and returns an error to show to the user, prompting them for another response. Like usual, validators can be provided directly to the prompt or with survey.WithValidator:

q := &survey.Question{
    Prompt: &survey.Input{Message: "Hello world validation"},
    Validate: func (val interface{}) error {
        // since we are validating an Input, the assertion will always succeed
        if str, ok := val.(string) ; !ok || len(str) > 10 {
            return errors.New("This response cannot be longer than 10 characters.")
	return nil

color := ""
prompt := &survey.Input{ Message: "Whats your name?" }

// you can pass multiple validators here and survey will make sure each one passes
survey.AskOne(prompt, &color, survey.WithValidator(survey.Required))

Built-in Validators

survey comes prepackaged with a few validators to fit common situations. Currently these validators include:

name valid types description notes
Required any Rejects zero values of the response type Boolean values pass straight through since the zero value (false) is a valid response
MinLength(n) string Enforces that a response is at least the given length
MaxLength(n) string Enforces that a response is no longer than the given length

Help Text

All of the prompts have a Help field which can be defined to provide more information to your users:

    Message: "What is your phone number:",
    Help:    "Phone number should include the area code",

Changing the input rune

In some situations, ? is a perfectly valid response. To handle this, you can change the rune that survey looks for with WithHelpInput:

import (

number := ""
prompt := &survey.Input{
    Message: "If you have this need, please give me a reasonable message.",
    Help:    "I couldn't come up with one.",

survey.AskOne(prompt, &number, survey.WithHelpInput('^'))

Changing the Icons

Changing the icons and their color/format can be done by passing the WithIcons option. The format follows the patterns outlined here. For example:

import (

number := ""
prompt := &survey.Input{
    Message: "If you have this need, please give me a reasonable message.",
    Help:    "I couldn't come up with one.",

survey.AskOne(prompt, &number, survey.WithIcons(func(icons *survey.IconSet) {
    // you can set any icons
    icons.Question.Text = "⁇"
    // for more information on formatting the icons, see here: https://github.com/mgutz/ansi#style-format
    icons.Question.Format = "yellow+hb"

The icons and their default text and format are summarized below:

name text format description
Error X red Before an error
Help i cyan Before help text
Question ? green+hb Before the message of a prompt
SelectFocus > green Marks the current focus in Select and MultiSelect prompts
UnmarkedOption [ ] default+hb Marks an unselected option in a MultiSelect prompt
MarkedOption [x] cyan+b Marks a chosen selection in a MultiSelect prompt

Custom Types

survey will assign prompt answers to your custom types if they implement this interface:

type Settable interface {
    WriteAnswer(field string, value interface{}) error

Here is an example how to use them:

type MyValue struct {
    value string
func (my *MyValue) WriteAnswer(name string, value interface{}) error {
     my.value = value.(string)

myval := MyValue{}
        Message: "Enter something:",


You can test your program's interactive prompts using go-expect. The library can be used to expect a match on stdout and respond on stdin. Since os.Stdout in a go test process is not a TTY, if you are manipulating the cursor or using survey, you will need a way to interpret terminal / ANSI escape sequences for things like CursorLocation. vt10x.NewVT10XConsole will create a go-expect console that also multiplexes stdio to an in-memory virtual terminal.

For some examples, you can see any of the tests in this repo.


What kinds of IO are supported by survey?

survey aims to support most terminal emulators; it expects support for ANSI escape sequences. This means that reading from piped stdin or writing to piped stdout is not supported, and likely to break your application in these situations. See #337

Why isn't sending a SIGINT (aka. CTRL-C) signal working?

When you send an interrupt signal to the process, it only interrupts the current prompt instead of the entire process. This manifests in a github.com/AlecAivazis/survey/v2/terminal.InterruptErr being returned from Ask and AskOne. If you want to stop the process, handle the returned error in your code:

err := survey.AskOne(prompt, &myVar)
if err == terminal.InterruptErr {

} else if err != nil {
  • add filtering on multi-selects with lots of options

    add filtering on multi-selects with lots of options

    this fix allows a filter term to be typed which filters the list of options displayed. users can use the delete/backspace key to delete characters from the filter and use Ctrl+W / Ctrl+X to clear the filter

    fixes #61

    opened by jstrachan 20
  • use a common render function to write all the prompts

    use a common render function to write all the prompts

    Hey @AlecAivazis, the goal of this PR is to isolate the prompt rendering and subsequent refresh and cursor movement into a common routine. I did this by embedding a common renderer object into each prompt. I couldn't find another way that made any sense. Overall I think it is a simplification although Password became more complicated due to the way readline works. readline really wants to manage the prompt and tries to do a bunch of tricky cursor manipulation with no obvious ways to work around it. I spent a lot of time fighting with readline.

    This PR also merges the Question and Choice templates into a single template so that we can have common render logic for Select and MultiSelect.

    I migrated the tests to be more table driven, which simplifies them, I also started using github.com/stretchr/testify/assert which I have found to be very useful.

    Lastly I fixed a minor bug with the HideCursor, where if you ctrl-c the prompt the ShowCursor was not getting called. So I wrapped that in a defer to always call ShowCursor even if interrupted.

    Anyway, check it out and let me know if you have any questions or concerns. Thanks!

    opened by coryb 20
  • Remove Readline usage

    Remove Readline usage

    Due to complications and inconsistencies with Readline (that prevent autoplay from working reliably) I have removed Readline from the codebase. For the simple cases of Confirm and Input I have replaced with with bufio.Scanner. For the cases where we need to read a rune at at time I have implemented terminal.RuneReader with specializations for most Unix flavors along with Windows. I have tested it on Windows 10, Linux and OSX and it seems to work well.

    Future refactoring:

    • fold the OnChange functions into the Prompts. I left them as-is to reduce the changes.
    • Add Help to Password prompts. This should just work now that I no longer have to fight against Readline.
    opened by coryb 18
  • Refactor survey to use optionally specified stdio.

    Refactor survey to use optionally specified stdio.

    We wanted to refactor out survey's stdin/stdout to optionally use a different pair of files. The refactor was doing using the functional options pattern. The main purpose was to automate testing of interactive applications at Netflix, and one of which used this library. In order to demonstrate why having controllable stdio is useful, I've also included a full set of integration tests using https://github.com/Netflix/go-expect that leverages this refactor.


    • What is go-expect?
      • It's a library that can expect sequences from a output stream and send data into an input stream byte for byte, so that one can automate testing of an interactive application.
    • What is vt10x?
      • It's an in-memory terminal emulator fulfilling the VT10X specifications, so that it can respond to e.g. cursor position report of its in-memory cursor. go-expect can multiplex the escape sequence from survey to vt10x and multiplex the cursor position report back to survey.
    • Why modify CursorLocation?
      • Bytes sent in while the prompt is rendering and before the cursor position report is discarded due to the way that it was implemented. Unmatched bytes are saved to a BufferedReader which is used in RuneReader so that it will first read from this internal buffer before it's stdin. Before this change, if you send the character "R" before the cursor position report, it will hang indefinitely.
    • Why vendor?
      • If a golang project imports any packages that has a vendor directory, go doesn't allow using nested dependencies from your GOPATH. It's also important for the library to be pinned to a set of versions (that consumers not necessarily have to match exactly) to have reproducible tests and for vendoring programs (like dep) to solve dependency constraints.
    • Why not autoexpect or some other expect library?
      • Autoexpect isn't reliable, and Netflix/go-expect doesn't spawn processes to control them. It only interacts with the pty that it creates. This means that go-expect tests can be regular go _test.go files and can leverage golang's test features (race, coverage, parallelism).
    opened by hinshun 15
  • add Checkbox prompt

    add Checkbox prompt

    I have refactored some of the common code from Choice and Checkbox into multioptions.go. The event loop it mostly the same, but didnt see an obvious way to abstract it away since I need to handle the "space" key differently for Checkbox.

    One issue I not sure how to work around is that a Checkbox should return the slice of options checked, but we are limited by the Prompt() (string, error) interface which only allows a single string to be returned. My work-around is to just return the list joined by , character. Users will need to split the answer to get back to a useful result. Not sure if you have ideas there.

    opened by coryb 15
  • Stricter error handling in tests

    Stricter error handling in tests

    Currently, the test suite is flakey, impeding the merge of PRs due to intermittent failures of required jobs. Example: https://github.com/AlecAivazis/survey/runs/4952430024?check_suite_focus=true

    I'm trying to track down the cause of flakes, but it's not easy due to a lot of them being caused by test suite timeouts (and thus, no specific test in particular). So I made a pass of strengthening error handling, particularly when it comes to tests:

    • I've used golangci-lint tool locally to find and address violations, mostly those were it pointed out that errors are not handled. In cases when we want to explicitly ignore the error, I use the _ = foo() assignment.
    • Calls to expect.Console methods were never checked for error return values. I've made a light wrapper around expect.Console that transparently reports test failures for any error encountered. This is a step in ensuring that no test is broken and stuck on I/O until it times out.
    • I've added t.Helper() calls to test helper functions so that they are excluded from being reported as a source of a test failure. We're more interested in where the failure originates in the test itself.
    opened by mislav 14
  • fix(cursor): fix terminal cursor move display

    fix(cursor): fix terminal cursor move display

    fix terminal cursor move display

    I only completed the test on my terminal (iTerm2).

    2019-06-02 20 48 53

    In the test I found that Goland's terminal seems to have problems with emoji:

    Use the test string: 啊啊啊啊aaaa😀😀😀😀啊啊啊啊啊啊

    When the cursor is in the first position of emoji, the cursor appears to be abnormally jumped when trying to delete the letter a

    • Goland 2019-06-02 21 05 23

    • iTerm2 2019-06-02 21 05 44

    Signed-off-by: mritd [email protected]

    opened by mritd 13
  • Modify API to allow for non-string result from prompts?

    Modify API to allow for non-string result from prompts?

    @AlecAivazis, creating an issue to track discussions started in [#28] and [#30] regarding potential API changes to encapsulate variable data returned from prompts (example: MultiChoice could return an []string and Confirm could return a bool).

    Thinking about your last suggestion, if I understand what you are saying the usage would look roughly like:

        var simpleQs = []*survey.Question{{
            Name: "name",
        }, {
            Name: "color",
        }, {
            Name: "days",
        }, {
            Name: "happy",
        answers := struct {
            Name  string
            Color string
            Days  []string
            Happy bool
        err := survey.Ask(simpleQs, &answers)

    Or more with tags:

        answers := struct {
            UserName   string   `survey:"name"`
            FavColor   string   `survey:"color"`
            PreferDays []string `survey:"days"`
            IsHappy    bool     `survey:"happy"`
        err := survey.Ask(simpleQs, &answers)

    How would we extend AskOne to work on interface values as well? Perhaps something like:

    days := []string{}
    err := survey.AskOne(prompt, &days)

    I think the usage of this is good from a user perspective. However I think the implementation will be reasonably tricky though (ie lots of code) and we will need to do lots of reflection (which will potentially move some compile-time errors to runtime-errors). So I think it is do-able but non-trivial, and I am not sure the implementation complexity cost would justify the relative ease of use in the API.

    opened by coryb 13
  • Is there a way to pass a different value on a Select prompt?

    Is there a way to pass a different value on a Select prompt?

    I have a Select prompt, and would like to display one thing to the user, but return a different value than what is being displayed.

    That is to say, it will show "George Bluth", but would like it to instead return the value of "george-bluth", which is something i could have in a map, let's say.

    In this particular case, I can transform the value myself (since it's simple toLower and string replacement), but in other cases it might be more arbitrary.

    Feature Question 
    opened by mattstratton 12
  • Fix prompt reset on some terminals

    Fix prompt reset on some terminals

    fixes #300

    PreviousLine() prints \e[1F, which is apparently not recognized by Konsole. I didn't find this control code anywhere in VT100 and ANSI references. On the other hand, Up() writes \e[1A, which works as expected. Using this makes it work perfectly in both the VSCode integrated terminal and Konsole.

    This would require a little bit of testing on Windows and MacOS though, but I don't expect this change to break anything.

    opened by System-Glitch 11
  • Dep ensure failing for survey

    Dep ensure failing for survey

    I have the following constraint in Gopkg.toml

      name = "github.com/AlecAivazis/survey"
      version = "2.0.0"

    Dep ensure with the above constraint is failing with error:

    v2.0.0:  "github.com/AlecAivazis/survey" imports "github.com/AlecAivazis/survey/v2/core", which contains malformed code: no package exists at "github.com/AlecAivazis/survey/v2/core"`

    After ignoring the pkg github.com/AlecAivazis/survey/v2/core in dep, build is failing with the following error:

    # github.com/Zomato/ZomatoDBQuery/query-parser/vendor/github.com/AlecAivazis/survey
    vendor/github.com/AlecAivazis/survey/multiselect.go:46:18: undefined: core.OptionAnswer
    opened by vermdeep 11
  • multiple selection,get the key from the console by default

    multiple selection,get the key from the console by default

    When multiple selection,After running and before the selection appears。

    • input enter , the first one will be selected and end。
    • input left,all will selected

    i guess this code has a problem of window rv, _, e := readConsoleInput.Call(rr.stdio.In.Fd(), uintptr(unsafe.Pointer(ir)), 1, uintptr(unsafe.Pointer(&bytesRead)))

    opened by wangzhiy 0
  • Clear to end of screen before redrawing prompt

    Clear to end of screen before redrawing prompt


    This PR adds a terminal.EraseScreen function to support the "Erase in Display" ANSI control sequence. This function replaces calls to terminal.ClearLine in resetPrompt in order to clear previous prompt output entirely and atomically, instead of clearing each line in an iterative manner.

    Updating resetPrompt to clear to the end of the screen seems to significantly reduce the "flickering" effect noted in #436 since fewer updates to the terminal screen are made between each render.

    Additionally, the MultiLine prompt was updated as a result of changes to the resetPrompt logic. This prompt now preserves leading and trailing spaces in answers and replaces the input template with an answered template after submission. The template was also updated to begin inputs on a newline, which happens to be a request of #336.







    The following steps can be used to inspect these changes:

    1. Checkout this branch
    2. In a project using survey and survey.Select, survey.MultiSelect, or survey.MultiLine, append the following to your go.mod, pointing to your local survey source:
    replace github.com/AlecAivazis/survey/v2 v2.3.6 => ../../go-survey/survey
    1. Run your project and rapidly page through select options in an attempt to reproduce the flickering effect.


    • Flickering is not entirely removed since there is brief moment between clearing the past prompt and outputting the updated one where the erased screen might be shown. This seems to be a fairly rare occurrence though, only happening a handful of times in my testing. The "synchronized update" suggestion from @dnkl would likely prevent this, but I had some difficulties in implementing this.

    • This has not been tested with a Windows terminal, however I presume this escape code is properly handled as "virtual terminal sequences are recommended" when developing for Windows.

      • These changes are also likely to impact the updates in #474, as both PRs are modifying the logic of resetPrompt.
    • These changes do not seem to impact the current behavior shown in #452.

    opened by e-zim 0
  • Fix redrawing prompts on Windows

    Fix redrawing prompts on Windows

    Fixes redrawing prompts on Windows so that:

    1. The line before the 1st survey prompt isn't accidentally deleted,
    2. The survey prompt is properly redrawn after recording an answer.

    For help with debugging Survey, this also adds logging support by setting SURVEY_LOG_FILE environment variable.

    Fixes https://github.com/go-survey/survey/issues/368 Closes https://github.com/go-survey/survey/pull/458


    • [ ] test in more different terminal combos
    • [ ] test cursor handling when a prompt or an answer wraps due to viewport width
    opened by mislav 0
  • Use virtual terminal processing on Windows

    Use virtual terminal processing on Windows

    This removes:

    1. Manual conversion of ANSI escape codes to Windows syscalls, and
    2. Windows-specific Cursor implementation

    in favor of the 3rd-party go-colorable module that implements all those conversions plus more. Furthermore, go-colorable will attempt to enable "virtual terminal processing" under Windows which is a mode where ANSI escape codes are recognized natively by the system, and no conversions whatsoever will be necessary.

    Note: doesn't work yet. Not sure why, but any prompt is now hanging. I suspect the Windows-specific runereader is not liking the changes to Cursor.

    opened by mislav 0
  • Support for `fmt.Stringer` interface to display structs in `Select`/`MultiSelect`

    Support for `fmt.Stringer` interface to display structs in `Select`/`MultiSelect`

    Awesome lib! But I really miss such behaviour, it would make things much easier.

    Title says it's all, but just for the reference

    type User struct {
    	name, surname string
    func (u *User) String() string {
    	return fmt.Sprintf("%s %s", u.name, u.surname)
    var users = []User{
    	{"John", "Doe"},
    	{"Sam", "Smith"},
    func main() {
    	var selected User
    		Message: "Select user",
    		Options:   users,
    	}, &selected)

    This feature would make such operations much more convenient and optimised, rather than manually searching for a related data based on string somehow.

    Are there any reasons why it's not a thing?

    sad cat

    opened by metafates 0
  • Rename package to `github.com/go-survey/survey/v2` in `go.mod`

    Rename package to `github.com/go-survey/survey/v2` in `go.mod`

    An example that showcases the bug.

    Executing go get -u github.com/go-survey/survey/v2

    What did you expect to see?

    No error

    What did you see instead?

    go: downloading github.com/go-survey/survey/v2 v2.3.6              
    go: github.com/go-survey/survey/[email protected]: parsing go.mod:           
            module declares its path as: github.com/AlecAivazis/survey/v2     
                    but was required as: github.com/go-survey/survey/v2                                                                                                                           

    The GitHub repository has been renamed, but not the package name in go.mod:


    opened by EtienneM 0
Alec Aivazis
Alec Aivazis
Guillaume J. Charmes 1.3k Jan 6, 2023
🎨 Terminal color rendering library, support 8/16 colors, 256 colors, RGB color rendering output, support Print/Sprintf methods, compatible with Windows.

?? Terminal color rendering library, support 8/16 colors, 256 colors, RGB color rendering output, support Print/Sprintf methods, compatible with Windows. GO CLI 控制台颜色渲染工具库,支持16色,256色,RGB色彩渲染输出,使用类似于 Print/Sprintf,兼容并支持 Windows 环境的色彩渲染

Gookit 1.2k Dec 30, 2022
An easy to use menu structure for cli applications that prompts users to make choices.

WMenu Package wmenu creates menus for cli programs. It uses wlog for its interface with the command line. It uses os.Stdin, os.Stdout, and os.Stderr w

Will Dixon 182 Dec 26, 2022
Prompts users to enter values for required flags in Cobra CLI applications

Cobra Flag Prompt Cobra Flag Prompt prompts users to enter values for required flags. It is an extension of Cobra, and requires that you use Cobra to

null 1 Nov 13, 2021
Golang library with POSIX-compliant command-line UI (CLI) and Hierarchical-configuration. Better substitute for stdlib flag.

cmdr cmdr is a POSIX-compliant, command-line UI (CLI) library in Golang. It is a getopt-like parser of command-line options, be compatible with the ge

hz 116 Oct 28, 2022
A simple posix shell created in golang

Fox-Shell Description Fox-Shell is a simple posix shell builded with golang Features - chdir works perfectly - mkdir works, but need bug fix To-Do Li

null 2 Dec 13, 2021
Drop-in replacement for Go's flag package, implementing POSIX/GNU-style --flags.

Description pflag is a drop-in replacement for Go's flag package, implementing POSIX/GNU-style --flags. pflag is compatible with the GNU extensions to

Steve Francia 2k Dec 30, 2022
Terminal UI library with rich, interactive widgets — written in Golang

Rich Interactive Widgets for Terminal UIs This Go package provides commonly needed components for terminal based user interfaces. Among these componen

rivo 7.8k Jan 7, 2023
Build an interactive CLI application with Go, Cobra and promptui. Video tutorial available on the Div Rhino YouTube channel.

Build an interactive CLI app with Go, Cobra and promptui Text tutorial: https://divrhino.com/articles/build-interactive-cli-app-with-go-cobra-promptui

Div Rhino Dev 16 Dec 8, 2022
Interactive CLI helper for creating git branches with JIRA Links and some text

bb (better-branch) Interactive CLI helper for creating git branches with JIRA Links and some text Still in development? Yes How it works? This tiny ut

Eugene Uvarov 3 Aug 18, 2022
Interactive prompt to set and push a semver tag

cutver For when you know what version to tag, and you want to cut a release in the annotated tag format. Installation go install github.com/roryq/cutv

Rory Quinn 8 Nov 15, 2022
Abacus is a simple interactive calculator CLI

Abacus is a simple interactive calculator CLI with support for variables, comparison checks, and math functions abacus -

Viktor Danov 33 Sep 15, 2022
🔥 [WIP] Interactive Jira Command Line

JiraCLI Interactive Jira CLI ?? This project is still a work in progress ?? This tool mostly focuses on issue search and navigation at the moment. How

Ankit Pokhrel 2.3k Jan 4, 2023
Simplistic interactive filtering tool

peco Simplistic interactive filtering tool NOTE: If you are viewing this on GitHub, this document refers to the state of peco in whatever current bran

null 7.2k Dec 30, 2022
Interactive prompt for command-line applications

promptui Interactive prompt for command-line applications. We built Promptui because we wanted to make it easy and fun to explore cloud services with

Manifold 5.3k Jan 8, 2023
Interactive cli tool for HTTP inspection

Wuzz command line arguments are similar to cURL's arguments, so it can be used to inspect/modify requests copied from the browser's network inspector with the "copy as cURL" feature.

Adam Tauber 10.2k Dec 27, 2022
An interactive command-line tool to manage your environments

goto An interactive command-line tool to manage your environments Overview You always need to login to some Linux machine or connect to a MySQL instan

Lucien 10 Jul 11, 2022
This tool is a CLI-interactive tool for TA who use eeclass platform

NTHU eeclass TA helper. This tool is a CLI-interactive tool for TA who use eeclass platform. It helps TA to download all the submitted homework, and use CSV to record the score and comment, and upload CSV score directly to the eeclass platform with just 2 Enter key!

Bo-Wei Chen 1 Dec 11, 2021
🧨 Interactive Process Killer CLI made with Go!

proc-manager is an interactive CLI to kill processes made with Go, currently supports Linux, Mac OS X, Solaris, and Windows.

Aykut 24 Dec 2, 2022