Documentation

DML — Descriptive Markup Language

DML is a simple, JSON-like descriptive language that supports variables, arithmetic operations, nested structures, lists, and maps. It was created using Kotlin, ANTLR, and the Java Virtual Machine.

Think of it as a strongly-typed, comment-friendly version of JSON — built for configuration, definition, and readability.


Features


Installation

Coming soon: Homebrew Tap to install globally

brew tap tree-software-company/dml
brew install dml

update this lang

brew uninstall dml
brew untap tree-software-company/dml
brew tap tree-software-company/dml
brew install dml

Then you can use it globally like:

dml read test.dml

The Homebrew formula will download the .jar from GitHub Releases automatically.


Option 2: Manual Installation (Local Development)

1. Clone the repo and build the .jar

git clone https://github.com/tree-software-company/dml.git
cd dml
gradle build

After build, you'll find your CLI JAR at:

build/libs/DML-all.jar

2. Run the CLI

java -jar build/libs/DML-all.jar read test.dml

3. (Optional) Make it global

Create a wrapper script:

sudo nano /usr/local/bin/dml

Paste:

#!/bin/bash
java -jar /path/to/DML-all.jar "$@"

Then make it executable:

chmod +x /usr/local/bin/dml

Now you can run:

dml read file.dml

Example DML Code

string title = "Hello";
number age = 30 + 2;
boolean isActive = true;

list numbers = [1, 2, 3, 4];
map user = { "name": "Szymon", "email": "example@example.com" };

string message = "Welcome, " + user.name;

Output:

Variables: {
  title=Hello,
  age=32,
  isActive=true,
  numbers=[1, 2, 3, 4],
  user={name=Szymon, email=example@example.com},
  message=Welcome, Szymon
}

CLI Commands

Command Description
dml read FILE Executes and interprets a .dml file
dml help Shows help menu

Development

This project uses:


License

This project is licensed under the Apache 2.0 License.


Author

Developed by Tree