Skip to content
This repository has been archived by the owner on Jun 13, 2020. It is now read-only.
/ pick Public archive
forked from bernardorufino/pick

Command line picker to pipe through

Notifications You must be signed in to change notification settings

marcelocra/pick

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

48 Commits
 
 
 
 
 
 
 
 

Repository files navigation

pick

pick is a command line tool that lets you select parts of the input before printing to the standard output. It's useful to use in the middle of a piped sequence of commands.

pick parses the input trying to understand its table structure and presents an interactive UI to select which parts of the input you want. It has 2 output modes: list and table.

  • List mode: outputs a list divided by '\n', handy for selecting sublists before executing commands on some input.
  • Table mode: lets you select parts of the table and constructs the final subtable, useful for filtering huge tables that some commands output.

It's been tested in OSX and Debian, pull requests for other platforms are welcome :)

Demo

pick demo

Installing

Homebrew

  • brew tap bernardorufino/pick
  • brew install pick

Manual

  • cd <install-dir>
  • git clone -b release --depth 1 https://github.com/bernardorufino/pick.git .
  • ln -s $(pwd)/pick.sh /usr/local/bin/pick # or other directory present in the $PATH variable

Using

Give it a try:

  • ls -l | pick # print files and copy to clipboard
  • ls | pick | xargs rm # select files in current directory before removing

Known issues

  • Can't see full output preview when it overflows

About

Command line picker to pipe through

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Python 93.1%
  • Shell 6.9%