An Emmet-like language that produces JSON, TOML, or YAML

Overview

.august:true

August is an Emmet-like language that produces JSON, TOML, or YAML from a single-line concise selector-like syntax.

If you aren't familiar with Emmet, think of August as a snippet or shortcut to quickly typing or editing a document in any of the target languages.

August is currently in very early stages. The repository currently contains a CLI under crates/cli, which will soon be published in various forms. Editor extensions and a playground will be supported later on.

Please feel free to open issues with syntax suggestions / general suggestions if you want to become involved!

Features

  • Values that are alphanumeric (may be expanded) do not need to be quoted
  • Familiar JSON-like operators (., ,, :)
  • Easy to type (close to the home row) operators (^ being the current exception, may change)
  • Context aware: .true:true becomes { "true": true }
  • Supports exiting a context (object or list) via ^ to the parent scope
  • More document types can be added in the future
  • Other features TBD!

Examples (syntax not final)

Prettier-esque

.semi:true,trailingComma:all,singleQuote:true,printwidth:120,tabwidth:2,ignored:.hello:world

JSON Output

{
  "ignored": {
    "hello": "world"
  },
  "tabwidth": "2",
  "trailingComma": "all",
  "singleQuote": "true",
  "semi": "true",
  "printwidth": "120"
}

TOML Output

tabwidth = "2"
trailingComma = "all"
singleQuote = "true"
semi = "true"
printwidth = "120"

[ignored]
hello = "world"

YAML Output

ignored:
  hello: world
tabwidth: '2'
trailingComma: all
singleQuote: 'true'
semi: 'true'
printwidth: '120'

Deeply Nested

.this:.is:.deeply:.nested:.indeed:.how:odd

JSON Output

{
  "this": {
    "is": {
      "deeply": {
        "nested": {
          "indeed": {
            "how": "odd"
          }
        }
      }
    }
  }
}

TOML Output

[this.is.deeply.nested.indeed]
how = "odd"

YAML Output

this:
  is:
    deeply:
      nested:
        indeed:
          how: odd

Syntax (current)

  • . - opens a new object (similar to { in JSON)
  • : - sets a value for a key
  • > - opens a new list (similar to [ in JSON)
  • ^ - climb up to the parent scope (object or list)
  • identifier - an unquoted string, can be used for keys and values
  • "this is my identifier" - a quoted string, can be used for keys and values
  • true, false, null - similar to JSON counterparts
  • \ - escapes a character within a quoted string (e.g. \")

CLI Usage (CLI command TBD)

ag -o / --output [OUTPUT] (json|toml|yaml) [INPUT]
You might also like...
Easily create dynamic css using json notation

jss! This crate provides an easy way to write dynamic css using json notation. This gives you more convenient than you think. Considering using a dyna

Decode Metaplex mint account metadata into a JSON file.

Simple Metaplex Decoder (WIP) Install From Source Install Rust. curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh Clone the source: git c

A fast and simple command-line tool for common operations over JSON-lines files

rjp: Rapid JSON-lines processor A fast and simple command-line tool for common operations over JSON-lines files, such as: converting to and from text

A node package based on jsonschema-rs for performing JSON schema validation

A node package based on jsonschema-rs for performing JSON schema validation.

Typify - Compile JSON Schema documents into Rust types.

Typify Compile JSON Schema documents into Rust types. This can be used ... via the macro import_types!("types.json") to generate Rust types directly i

Tools for working with Twitter JSON data

Twitter stream user info extractor This project lets you parse JSON data from the Twitter API or other sources to extract some basic user information,

A easy and declarative way to test JSON input in Rust.

assert_json A easy and declarative way to test JSON input in Rust. assert_json is a Rust macro heavily inspired by serde json macro. Instead of creati

A fast way to minify JSON

COMPACTO (work in progress) A fast way to minify JSON. Usage/Examples # Compress # Input example (~0.11 KB) # { # "id": "123", # "name": "Edua

JSON Schema validation library

A JSON Schema validator implementation. It compiles schema into a validation tree to have validation as fast as possible.

Owner
Yoav Lavi
jɔɑːv lɑviː
Yoav Lavi
Get JSON values quickly - JSON parser for Rust

get json values quickly GJSON is a Rust crate that provides a fast and simple way to get values from a json document. It has features such as one line

Josh Baker 160 Dec 29, 2022
rurl is like curl but with a json configuration file per request

rurl rurl is a curl-like cli tool made in rust, the difference is that it takes its params from a json file so you can have all different requests sav

Bruno Ribeiro da Silva 6 Sep 10, 2022
command line tool to navigate JSON files with basic SQL-like queries

navi-json command line tool to navigate JSON files with basic SQL-like queries. The name plays with the assonance with the word 'navigator', at least

Giulio Toldo 2 Oct 2, 2022
A JSON Query Language CLI tool built with Rust 🦀

JQL A JSON Query Language CLI tool built with Rust ?? ?? Core philosophy ?? Stay lightweight ?? Keep its features as simple as possible ?? Avoid redun

Davy Duperron 872 Jan 1, 2023
JSON parser which picks up values directly without performing tokenization in Rust

Pikkr JSON parser which picks up values directly without performing tokenization in Rust Abstract Pikkr is a JSON parser which picks up values directl

Pikkr 615 Dec 29, 2022
Strongly typed JSON library for Rust

Serde JSON   Serde is a framework for serializing and deserializing Rust data structures efficiently and generically. [dependencies] serde_json = "1.0

null 3.6k Jan 5, 2023
JSON implementation in Rust

json-rust Parse and serialize JSON with ease. Changelog - Complete Documentation - Cargo - Repository Why? JSON is a very loose format where anything

Maciej Hirsz 500 Dec 21, 2022
Rust port of gjson,get JSON value by dotpath syntax

A-JSON Read JSON values quickly - Rust JSON Parser change name to AJSON, see issue Inspiration comes from gjson in golang Installation Add it to your

Chen Jiaju 90 Dec 6, 2022
A rust script to convert a better bibtex json file from Zotero into nice organised notes in Obsidian

Zotero to Obsidian script This is a script that takes a better bibtex JSON file exported by Zotero and generates an organised collection of reference

Sashin Exists 3 Oct 9, 2022
A tool for outputs semantic difference of json

jsondiff A tool for outputs semantic difference of json. "semantic" means: sort object key before comparison sort array before comparison (optional, b

niboshi 3 Sep 22, 2021