Skip to content
/ ton Public

A human-friendly language for programmatic authoring and safe interchange of tree-structured data.

License

Notifications You must be signed in to change notification settings

vezel-dev/ton

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

TON

TON

A human-friendly language for programmatic authoring and safe interchange of tree-structured data.

License Commits Build Discussions Discord Zulip


Warning

This is currently in-development vaporware.

TON (Tree Object Notation) is a modern data language featuring two dialects: One for programmatic generation of data, and a static subset for safe data interchange.

TON is designed to be a pleasant and compact replacement for both XML and JSON, combining the best qualities of each, while allowing advanced users to programmatically generate large data sets using the full language dialect. At its simplest, TON can be used as a static data format just like XML or JSON, while at its full potential, it can be used to maintain large and complex textual databases at a level of maintainability that such data formats simply cannot achieve.

The original motivation for the creation of TON was the maintenance of the sorts of large data sheets that video games often use to describe things like areas, items, quests, characters, skills, etc. The code dialect should be well-suited to any similar use case. On the other hand, the data dialect can is well-suited as a safe and more compact replacement for XML and JSON, e.g. in networked APIs.

TON is an open standard. This project provides both the specification and the reference implementation in C#.

Usage

This project offers the following packages:

Package Description Downloads
[ton][ton-pkg] Provides the .NET global tool. ![Downloads][ton-dls]
Vezel.Ton Provides the core parsing, analysis, and runtime services. Downloads
Vezel.Ton.Tooling Provides user-facing tooling such as syntax coloring and diagnostic rendering. Downloads
Vezel.Ton.Service Provides the Language Server Protocol implementation. Downloads

To install a tool package in a project, run dotnet tool install <name>. To install it globally, also pass -g.

To install a library package, run dotnet add package <name>.

For more information, please visit the project home page.

Building

You will need the .NET SDK and Node.js installed. Simply run ./cake (a Bash script) to build artifacts and run tests. You can also run ./cake pack to avoid running tests, or ./cake test to just build and run tests.

These commands will use the Debug configuration by default, which is suitable for development and debugging. Pass -c Release instead to get an optimized build.

License

This project is licensed under the terms found in LICENSE-0BSD.