All Projects → gko → listbox

gko / listbox

Licence: MIT license
💬 listbox element for bash

Programming Languages

shell
77523 projects

Projects that are alternatives of or similar to listbox

dotfiles
/home/yous
Stars: ✭ 43 (-2.27%)
Mutual labels:  bashrc, zshrc
dotfiles
Dotfiles & Developer Environment. Supports Ubuntu2004+, macOS Catalina+, Windows 10 w WSL
Stars: ✭ 30 (-31.82%)
Mutual labels:  bashrc, zshrc
dotfiles
A total nord dotfiles used by me. Forever work in progress.
Stars: ✭ 35 (-20.45%)
Mutual labels:  bashrc, zshrc
Dot-It-Up
A collection of dotfile scripts, plugins, and clever hacks so that you can become the master of your own OS! 🚀
Stars: ✭ 254 (+477.27%)
Mutual labels:  bashrc, zshrc
dotfiles
📑 .dotfiles for Bash (Linux) / ZSH (Linux) / Git Bash (Windows) / Cygwin (Windows) / Bash on Ubuntu on Windows
Stars: ✭ 175 (+297.73%)
Mutual labels:  bashrc, zshrc
CLE
Command Live Environment
Stars: ✭ 21 (-52.27%)
Mutual labels:  bashrc, zshrc
anyrc
🐚 Bring your shell environment to anywhere
Stars: ✭ 28 (-36.36%)
Mutual labels:  bashrc, zshrc
rc.d
🛠 My rc files and other configs. Includes: Bash, Zsh, Vim, Tmux, Git, Terminal (macOS), VS Code
Stars: ✭ 32 (-27.27%)
Mutual labels:  bashrc, zshrc
q
q - vim like macro registers for your bash and zsh shell!
Stars: ✭ 54 (+22.73%)
Mutual labels:  bashrc, zshrc
awesome-bashrc
🚀 Collection of bash snippets/aliases that will save your time on the terminal
Stars: ✭ 109 (+147.73%)
Mutual labels:  bashrc
dotfiles
Personal configuration files. neovim, alacritty, hammerspoon and others.
Stars: ✭ 83 (+88.64%)
Mutual labels:  zshrc
BashConfig
BASH configuration files.
Stars: ✭ 46 (+4.55%)
Mutual labels:  bashrc
dotfiles
personal dotfiles with stow
Stars: ✭ 16 (-63.64%)
Mutual labels:  bashrc
gac
One simple command to format and faster your git add and git commit actions.
Stars: ✭ 162 (+268.18%)
Mutual labels:  zshrc
dotfiles
There is no place like ~/
Stars: ✭ 19 (-56.82%)
Mutual labels:  bashrc
custom zshrc
My personal dotfiles
Stars: ✭ 25 (-43.18%)
Mutual labels:  zshrc
terminal-themes
rc files for vim, tmux, iterm and zsh
Stars: ✭ 18 (-59.09%)
Mutual labels:  zshrc
homesick-bash
Homesick castle for bash (base for other castles)
Stars: ✭ 17 (-61.36%)
Mutual labels:  bashrc
my-little-friends
Moved to https://gitlab.com/skybert/my-little-friends
Stars: ✭ 62 (+40.91%)
Mutual labels:  bashrc
dotfiles
Dotfiles repo
Stars: ✭ 12 (-72.73%)
Mutual labels:  bashrc

Listbox

💬 listbox element for bash

demo

Simple bash listbox to choose from options

Installation

Manually

git clone https://github.com/gko/listbox

then in .bashrc or .zshrc:

source ./listbox/listbox.sh

With Fig

Fig adds apps, shortcuts, and autocomplete to your existing terminal.

Install listbox in just one click.

With antigen

In your .zshrc

antigen bundle gko/listbox

With oh-my-zsh

git clone https://github.com/gko/listbox.git ~/.oh-my-zsh/custom/plugins/listbox

then in your .zshrc

plugins=(
  ...
  listbox
  ...
)

Usage

Usage: listbox [options]
Example:
  listbox -t title -o "option 1|option 2|option 3" -r resultVariable -a '>'
Options:
  -h, --help                         help
  -t, --title                        list title
  -o, --options "option 1|option 2"  listbox options
  -r, --result <var>                 result variable
  -a, --arrow <symbol>               selected option symbol

General usage

source ./listbox.sh
listbox -t Title -o "option 1|option 2|option 3" -r result
echo "user chose: $result"

output:

  Title
  -----
  option 1
> option 2
  option 3
  
user chose: option 2

Specify arrow symbol

listbox -t Title -o "option 1|option 2|option 3" -a ''

output:

  Title
  ---
→ option 1
  option 2
  option 3
  
option 1

Pipe directly to variable

result=$(listbox -t Title -o "option 1|option 2|option 3" | tee /dev/tty | tail -n 1)
echo "user chose: $result"

output:

  Title
  ---
  option 1
> option 2
  option 3
  
user chose: option 2

Like it?

this repo

License

MIT

Copyright (c) 2012-2016 Konstantin Gorodinskiy

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].