Getting Started with LeonBasic¶
Installation¶
LeonBasic is a Rust-based interpreted language. Follow these steps to install and run it:
Prerequisites¶
- Rust programming language (latest stable version recommended)
- Cargo package manager (included with Rust)
Clone the Repository¶
git clone https://github.com/leonmmcoset/leonlang.git
cd leonlang
Build the Project¶
cargo build
Run a LeonBasic Program¶
cargo run path/to/your/file.leon
Your First LeonBasic Program¶
Create a file named hello.leon with the following content:
require("basic");
basic.print(string:"Hello, World!");
Run it with:
cargo run hello.leon
You should see the output: Hello, World!
Basic Workflow¶
- Write your code in a
.leonfile - Run the code using the LeonBasic interpreter
- Debug as needed
Development Tools¶
VS Code Extension¶
LeonBasic provides a VS Code extension for better development experience. You can find it in the addons directory of the repository.
To install the extension:
- Open VS Code
- Go to Extensions
- Click on the three dots in the top right corner
- Select "Install from VSIX..."
- Choose the
.vsixfile from theaddonsdirectory
Next Steps¶
- Learn about Basic Syntax
- Explore the Module System
- Check out examples in the
testdirectory