Live data from Hacker News

Cue – A language for defining, generating, and validating data

cuelang.org

11–20 of 167 posts

Re: Cue – A language for defining, generating, and validating data

#11
Disclosure: I work on Tree Notation.

If the authors would like to discuss how Tree Notation may be a better syntax for this language, please feel free to get in touch: breck7@gmail.com or yunits@hawaii.edu.

Here is a demonstration of what a Tree Language for config files could look like: https://treenotation.org/designer/#standard%20config

Re: Cue – A language for defining, generating, and validating data

#12
post #3

Seems like an interesting language, but I'm very disappointed that my first attempt to view example code took 5 clicks. The most important part of any programming language website is a short example snippet: put it above the fold on the front page!

I gave up looking after 1min

Re: Cue – A language for defining, generating, and validating data

#14

Seems really interesting after a quick read-through. Specs that allow range-based validation look useful, and the structural declarations also feel like they'll help reduce a lot of boilerplate and repetition. I wonder how this compares with Dhall and Jsonnet, both of which I've been looking into as a safer alternative to templated YAML. With Google putting its weight behind this I'm curious if it'll start finding it…

A safer yaml:

https://hitchdev.com/strictyaml/

Re: Cue – A language for defining, generating, and validating data

#16
Here is an interesting example showing what it looks like: https://github.com/cuelang/cue/blob/e5d8d09b3ba2e4f48c84a3b5...

I used the following command on the cloned repository to find it[1]:

  find . -iname '*.cue' | xargs ls -l | tr -s ' ' | cut -d ' ' -f5,9 | sort -n
[1] Note that 'find' has a '-printf' option which could have been used to simplify this one-liner.

Re: Cue – A language for defining, generating, and validating data

#19
post #6

The tl;dr is buried deep in the docs > CUE is an extension of JSON. This improves familiarity and makes it easy to get going quickly. > In its simplest use case, CUE can substitute for a more pleasant way to write JSON.

So it’s a google branded yaml? Let’s raise a glass to our blue eyed comrades who’ll adopt this fully, only for google to decide in 2-3 years to completely and aggressively kill it again for no apparent reason.

Pardon for slamming my ignorance down on the table here: I know Google has a tendency of killing products but I’m not familiar with many of their engineering tooling being similarly sunset with comparable frequency.

Any named examples? I’m sure there are-and likely they just elude me at present, maybe seeing their names will jog the memory probably?

Post reply on HN