git.delta.rocks / jrsonnet / refs/commits / aeb50fc41570

difftreelog

source

README.adoc2.8 KiBrenderedsourcehistory
1= jrsonnet23[.text-center]4image:./docs/logowide.svg[Interactive,470, alt=jrsonnet logo]56[.text-center]7--8image:https://img.shields.io/github/v/tag/CertainLach/jrsonnet?color=%23fb4934&label=latest%20release&style=for-the-badge[alt=release, link=https://github.com/CertainLach/jrsonnet/releases]9image:https://img.shields.io/github/license/CertainLach/jrsonnet?color=%2383a598&label=license&style=for-the-badge[alt=license, ./LICENSE]10image:https://img.shields.io/opencollective/all/jrsonnet?color=%238ec07c&style=for-the-badge[alt=opencollective, link=https://opencollective.com/jrsonnet]11--1213== What is it1415https://jsonnet.org/[Jsonnet] is a data templating language1617This Rust crate implements both jsonnet library and an alternative `jsonnet` executable based on it.18For more information see <<bindings,Bindings>>.1920== Install2122=== NixOS2324jrsonnet is packaged in nixpkgs and maintained by @CertainLach2526[source,sh]27----28nix-env -iA nixpkgs.jrsonnet29----3031=== MacOS3233jrsonnet is packaged to brew and maintained by @messense3435[source,sh]36----37brew install jrsonnet38----3940=== Windows/other linux distributions4142You can get latest build of jrsonnet in https://github.com/CertainLach/jrsonnet/releases[releases].4344=== Build from sources4546jrsonnet should build on latest stable Rust version (probably on the oldest, but there is no MSRV policy provided)4748Debug build will work too, but it is much slower than release4950[source]51----52cargo build --release53----5455== Why?5657There already are multiple implementations of this standard implemented in different languages:5859* https://github.com/google/jsonnet[C++];60* https://github.com/google/go-jsonnet/[Go];61* https://github.com/databricks/sjsonnet[Scala].6263This implementation shows performance better than all existing implementations.64For more information see link:./docs/benchmarks.md[benchmarks]6566Also, I wanted to experiment on new syntax features, and jrsonnet implements some of them.67For more information see link:./docs/features.adoc[features]6869In the end, it's always fun to implement something in Rust.7071== Bindings [[bindings]]7273=== Rust7475image:https://img.shields.io/crates/v/jrsonnet-evaluator[alt=crates.io, link=https://crates.io/crates/jrsonnet-evaluator]76image:https://docs.rs/jrsonnet-evaluator/badge.svg[alt=docs.rs, link=https://docs.rs/jrsonnet-evaluator]7778Jrsonnet is written in rust itself, so just add it as dependency7980=== Python8182image:https://img.shields.io/pypi/v/rjsonnet[alt=crates.io, link=https://pypi.org/project/rjsonnet/]8384Bindings are created and maintained by @messense8586=== C/C++8788Jrsonnet provides a standard `libjsonnet.so` shared library and should work as drop-in replacement for it8990=== Other9192WASM bingings are also available, Java bindings (Both JNI and WASM compiled to `.class`) are in progress9394See link:./bindings/[bindings] for more information.