Hacker News new | ask | show | jobs
by dale_glass 854 days ago
JSON is a good start, but Powershell is great in that a date is actually a date object, which means that I can do operations on that without faffing around with parsing and worrying about whether what comes in the JSON might depend on the locale of some system, or that somebody didn't take into account that I might want microseconds and truncated the timestamp.
2 comments

Right, but at that point you're tying it to a universal type system.

Personally I like YAML, since you can add type-hints to data which you can use to turn simple text types into more complex types, but I can see why that standard wouldn't take off.

Most of the unix-philosophy people I know are interested in stuff like that, it just has to be implemented in a thoughtful way.

YAML is a crime.
I can see why you'd be worried about it, it's a lot more powerful than what I'd actually want for this.

But that's sort of part of the problem, no one is going to agree on a common universal data-type.

if you're going to use something JSONesque as your common language, I think you do need to include a schema