Description #
RC is a minimalist, functional shell from the Plan 9 operating system, known for its simplicity, elegance, and consistent syntax. It was designed to overcome the inconsistencies and complexities found in traditional Unix shells.
History #
RC was developed in the late 1980s by Tom Duff at Bell Labs as part of the Plan 9 from Bell Labs project — a research operating system intended as a successor to Unix. RC stands for “run commands” and follows a clean, orthogonal design heavily influenced by functional programming principles. Though less widely used, it is appreciated by enthusiasts for its clarity and predictability.
Hello World Code #
echo 'Hello, World!'
How to Run #
Option 1: Online
- No dedicated RC shell emulator online, but some Unix VM environments support it.
- Try Plan 9 Online (9pfs) (indirect access to RC shell)
Option 2: Local
Install RC Shell (via 9base or Plan 9 packages):
sudo apt install 9base
Save the code in hello.rc
and run:
rc hello.rc
Key Concepts #
- Minimalist syntax
- Functional, orthogonal design
- No special characters like
$
for variables - Uses
=
for assignment (noexport
) - Clean command substitution with
backtick()
- Easy-to-read and predictable syntax
- No control structures like
case
, usesif
and loops - Consistent quoting rules
- Part of the Plan 9 OS philosophy
- Still used in niche systems programming circles
Try It Online #
- 9p.io – Plan 9 from Bell Labs (indirect access)
Fun Facts #
- RC was designed by Tom Duff, also known for Duff’s Device in C.
- Unlike most shells, variables don’t need a
$
prefix. - RC scripts often look more like functional code than traditional shell scripts.