| Crates.io | uni-cli |
| lib.rs | uni-cli |
| version | 0.0.12 |
| created_at | 2025-10-18 18:50:24.686553+00 |
| updated_at | 2025-10-25 13:47:55.761246+00 |
| description | Command-line REPL and interpreter for the Uni programming language |
| homepage | |
| repository | https://github.com/edadma/uni |
| max_upload_size | |
| id | 1889532 |
| size | 93,043 |
Command-line REPL and interpreter for the Uni programming language - a homoiconic stack-based language that unifies code and data.
cargo install uni-cli
This installs the uni command-line tool.
uni
_ _ _
| | | |_ __ (_)
| | | | '_ \| |
| |_| | | | | |
\___/|_| |_|_| v0.0.12
Type 'quit' or press Ctrl-D to exit
uni> 5 3 +
=> 8 : int32
uni> 'square [dup *] def
uni> 7 square
=> 49 : int32
# Execute and print result
uni -e "5 3 +"
# Output: 8
# Execute code without printing
uni -c "5 3 + ."
# Output: 8
uni script.uni
5 3 + # Addition: 8
10 4 - # Subtraction: 6
7 6 * # Multiplication: 42
20 4 / # Division: 5
dup # Duplicate top item
swap # Swap top two items
drop # Remove top item
[1 2 3] # Create list
[1 2 3] head # Get first element: 1
[1 2 3] tail # Get rest: [2 3]
[1 2 3] length # Length: 3
'square [dup *] def # Define function
5 square # Use it: 25
5 0 > [true] [false] if # Conditional
The CLI can also be built for embedded systems:
For embedded builds and more documentation, see the main repository:
GitHub: https://github.com/edadma/uni
To embed Uni in your own application, use the uni-core library crate:
[dependencies]
uni-core = "0.0.12"
See the uni-core crate documentation for API details.
Dual-licensed under MIT OR Unlicense.