Skip to content
🐚 an instant REPL for any command
Shell
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
license
readme.md
repl

readme.md

repl

an instant REPL for any command

Features

  • Command history (cycle with arrow keys)
  • Reverse-search using Ctrl+R
  • It's epic

Requirements

  • bash
  • rlwrap (optional, needed for history)

Installation

Assuming $HOME/bin is in your $PATH,

curl -s https://raw.githubusercontent.com/icyphox/repl/master/repl -o $HOME/bin/repl
chmod +x $HOME/bin/repl

Usage

It's simple, just repl <command>:

$ repl git
git% branch
* master
git% remote -v
origin  git@github.com:icyphox/asdf (fetch)
origin  gitgit@github.com:icyphox/asdf (push)

Or, pipe it to STDIN — repl --stdin <command>:

$ repl --stdin cat
cat% 
yeet
cat% fortnite bad, mc good
fornite bad, mc good

Reverse-search by hitting Ctrl+R:

$ repl pip3
(reverse-i-search)`li': list

And here's repl for ed(1) :)

$ repl --stdin ed
ed% what
?

ed% am
?

ed% i

ed% doing
?

Prior art

repl(1) by Chris Wanstrath

License

MIT © Anirudh Oppiliappan

You can’t perform that action at this time.