Fairly dirty way of allowing shebang lines
This snippet will read the first two characters of a file passed in to
`yq` and remove the line if it begins with "`#!`". This will allow `yq`
to continue parsing it as though the shebang line was not there.
I was not able to find canonical documentation that the shebang is
limited to a single line or cannot include continuation characters.
However these seem to be accepted truths. See:
https://linux.die.net/man/2/execvehttps://en.wikipedia.org/wiki/Shebang_(Unix)#Syntax
This is to ensure solid parsing of complex data (with any binary
content except NUL chars) by separating the `yq` root collection
member's output with NUL char. As a safe-guard, an error will be cast
if trying to use NUL character with content that contains itself NUL
characters inside.
* Refactor ordered_map into separate files
Separate json and xml, from the regular yaml.
Makes it possible to compile, without those...
* Refactor encoder and decoder creation
Use more consistent parameters vs globals
Return errors instead of calling panic()
* Allow build without json and xml support