An interactive shell written in Sigil

Type commands. Start a line with ( and it's Sigil.

Shale reads command lines the way Bash and fish do: words, quotes, pipes, redirects, &&, globs and $(...). When you need a loop, a condition or real data, open a parenthesis and you have the whole language, with every library a script can import.

shale 0.1.0 · Linux · GPL-3.0-or-later

~/project $ ls src
main.sgl
util.sgl

~/project $ (define sources (glob "src/*.sgl"))

~/project $ wc -l ,@sources | tail -1
 3 total

~/project $ sleep 300 &

~/project $ jobs
[1] running sleep 300

~/project $ grep plumber README.md

✗ exited 1 · 0s

ada :: build-box · ~/project = main · 14:05
$ grep plumber README.md
A Shale session with the short prompt turned on: a Sigil definition spliced into a command, a job in the background, a failed command with its status and time, and the next prompt with a suggestion from history.

What you get

  • Suggestions from your history

    As you type, the rest of a line you ran before appears in gray, preferring lines from the directory you're in. C-e takes all of it, M-f one word.

  • Job control

    Start a job in the background with &, list it with jobs and bring it back with fg. C-z stops the job you're running.

  • Outcomes you can see

    A failed command prints its exit status and how long it ran, and the next $ turns red. ,last shows the latest outcome again.

  • Sigil on the same line

    ,name puts a Sigil value into a command and ,@list splices in a list, the same comma a script uses, so a line you got working pastes into a script.

  • Configured in Sigil

    ~/.config/shale/config.sgl is a Sigil file. Shale reads it again at the next prompt after you save it, and keeps the old settings if the new ones have a mistake.

  • Ready for agents

    shale --json -e runs one line and prints its outcome as JSON: the status, the output and every stage of the pipeline.

Install

build from source

$ git clone https://git.usesigil.org/sigil/shale.git
$ cd shale
$ sigil deps install
$ sigil build --config release
$ build/release/bin/shale

Shale needs Sigil 0.24.11, which isn't released yet, so these steps won't work until it is. Until then, the source is there to read and follow along.

Once it's built, try Shale in a terminal you already have open; the manual starts from there.

Platforms
SystemArchitectureStatus
Linuxx86_64supported
Linuxaarch64not yet tested
macOSarm64not yet supported