This document describes the Oil language from clean slate perspective. Knowledge of Unix shell or the compatible OSH language isn’t assumed. But shell users will see similarities, simplifications, and upgrades.
This document is long because it demonstrates nearly every feature of the language. You may want to read it in multiple sittings, or read The Simplest Explanation of Oil first.
A summary of what follows:
Oil has interleaved word, command, and expression languages.
The command language has Ruby-like blocks, and the expression language has Python-like data types.
Oil has two kinds of builtins that form the “standard library”.
Languages for data (like JSON) are complementary to Oil code.
OSH and Oil share both an interpreter data model and a process model (provided by the Unix kernel). Understanding these common models will make you both a better shell user and Oil user.
Keep those 4 points in mind as you read the details below.