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

difftreelog

source

README.adoc3.6 KiBrenderedsourcehistory
1= jrsonnet23++++4<p align="center"><a href="https://github.com/CertainLach/jrsonnet"><img alt="jrsonnet logo" src="./docs/logowide.svg" width="470px"></img></a></p>5<p align="center">6  <a href="https://github.com/CertainLach/jrsonnet/releases"><img alt="release" src="https://img.shields.io/github/v/tag/CertainLach/jrsonnet?color=%23fb4934&label=latest%20release&style=for-the-badge"></img></a>7  <a href="./LICENSE"><img alt="license" src="https://img.shields.io/github/license/CertainLach/jrsonnet?color=%2383a598&label=license&style=for-the-badge"></img></a>8  <a href="https://opencollective.com/jrsonnet"><img alt="opencollective" src="https://img.shields.io/opencollective/all/jrsonnet?color=%238ec07c&style=for-the-badge"></img></a>9</p>10++++1112// Github sucks: I can't center those images the normal way: https://github.com/github/markup/issues/984 13// [.text-center]14// image:./docs/logowide.svg[Interactive,470, alt=jrsonnet logo]15//16// [.text-center]17// --18// image: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]19// image:https://img.shields.io/github/license/CertainLach/jrsonnet?color=%2383a598&label=license&style=for-the-badge[alt=license, ./LICENSE]20// image:https://img.shields.io/opencollective/all/jrsonnet?color=%238ec07c&style=for-the-badge[alt=opencollective, link=https://opencollective.com/jrsonnet]21// --2223== What is it2425https://jsonnet.org/[Jsonnet] is a data templating language2627This Rust crate implements both jsonnet library and an alternative `jsonnet` executable based on it.28For more information see <<bindings,Bindings>>.2930== Install3132=== NixOS3334jrsonnet is packaged in nixpkgs and maintained by @CertainLach3536[source,sh]37----38nix-env -iA nixpkgs.jrsonnet39----4041=== MacOS4243jrsonnet is packaged to brew and maintained by @messense4445[source,sh]46----47brew install jrsonnet48----4950=== Windows/other linux distributions5152You can get latest build of jrsonnet in https://github.com/CertainLach/jrsonnet/releases[releases].5354=== Build from sources5556jrsonnet should build on latest stable Rust version (probably on the oldest, but there is no MSRV policy provided)5758Debug build will work too, but it is much slower than release5960[source]61----62cargo build --release63----6465== Why?6667There already are multiple implementations of this standard implemented in different languages:6869* https://github.com/google/jsonnet[C++];70* https://github.com/google/go-jsonnet/[Go];71* https://github.com/databricks/sjsonnet[Scala].7273This implementation shows performance better than all existing implementations.74For more information see link:./docs/benchmarks.md[benchmarks]7576Also, I wanted to experiment on new syntax features, and jrsonnet implements some of them.77For more information see link:./docs/features.adoc[features]7879In the end, it's always fun to implement something in Rust.8081== Bindings [[bindings]]8283=== Rust8485image:https://img.shields.io/crates/v/jrsonnet-evaluator[alt=crates.io, link=https://crates.io/crates/jrsonnet-evaluator]86image:https://docs.rs/jrsonnet-evaluator/badge.svg[alt=docs.rs, link=https://docs.rs/jrsonnet-evaluator]8788Jrsonnet is written in rust itself, so just add it as dependency8990=== Python9192image:https://img.shields.io/pypi/v/rjsonnet[alt=crates.io, link=https://pypi.org/project/rjsonnet/]9394Bindings are created and maintained by @messense9596=== C/C++9798Jrsonnet provides a standard `libjsonnet.so` shared library and should work as drop-in replacement for it99100=== Other101102WASM bingings are also available, Java bindings (Both JNI and WASM compiled to `.class`) are in progress103104See link:./bindings/[bindings] for more information.