# RBel A programming language that keeps context, code, and configuration in one document. An RBel document can explain a rule, define it in executable code, and put a runnable example beside it. ## Try RBel [Download RBel for macOS](https://getworkloop.com/download/rbel/mac) and unzip the file. Save this document as `quickstart.rbel.md` next to the extracted `rbel` executable. In Terminal, go to that folder. ### Add a bonus The score includes a two-point bonus. ```rbel code=score (def score (points) (+ points 2)) ``` Five points should become seven. ```rbel example=score-check (score 5) => 7 ``` Load this document and evaluate the expression from the example: ```sh ./rbel --eval-with quickstart.rbel.md '(score 5)' ``` The result is `7`. Change the bonus from `2` to `3` and run the command again. It now prints `8`, so update the expected result in the example to match. ## Build from source These instructions use Git and Nix with flakes enabled. They were verified on Apple silicon macOS. ```sh git clone https://github.com/getworkloop/coworker-protocol.git cd coworker-protocol git checkout --detach 9490e3459f549682ba50de9b13bf793f2c9934bc ``` Copy this document to the root of the checkout, then run: ```sh nix develop -c ./coworkers/bin/rbel --eval-with quickstart.rbel.md '(score 5)' ``` - [RBel project page](https://randallb.com/projects/rbel) - [Language draft](https://github.com/getworkloop/coworker-protocol/blob/9490e3459f549682ba50de9b13bf793f2c9934bc/areas/rbel/rbel.rbel.md) - [Coworker Protocol](https://randallb.com/projects/coworker-protocol) - [Coworker Runtime](https://randallb.com/projects/coworker-runtime)