Skip to main content

Shell

The bingo-functional REPL (bingo-functional-repl), is an appendage of the bingo-functional set of utilities. Capable of parsing idiomatic PHP input, the shell provides an interactive playground for interaction with the primitives available in the bingo-functional library.

Installation#

bingo-functional-repl is, like bingo-functional, installable via Composer and Git. To install the shell, type either one of the following set of directives in a console of your choosing.

$ composer global require chemem/bingo-functional-repl dev-master

Basic Usage#

The REPL is operationalizable via the bfrepl executable file - accessible in a Composer-created vendor directory. It parses expressions - string concatenation, Mathematical operations, class instantiation, and the like - written in idiomatic PHP. bingo-functional primitives take center stage and, are thus first-class REPL citizens.

Shown below is a simple demonstration of REPL usage.

asciicast

Important Commands#

help#

Displays a list of poignant console commands.

howto#

Displays additional information on how to use the console.

history#

Displays a list of previously typed REPL input.

doc#

Prints documentation for a bingo-functional primitive - parameter names, count, and return types for functions; type and methods for library algebras.

exit#

Terminates the REPL.