Documentation ¶
Index ¶
- Variables
- func Compact(json string) (string, error)
- func NewEncoder(tab bool, indent int) *encoder
- func PrettyPrint(in string) string
- func PrintJson(json string) error
- func PrintJsonToStderr(json string) error
- func RunJQ(queryStr string, result interface{}) (interface{}, error)
- func RunJQOnString(queryStr string, json string) (interface{}, error)
- func RunJQOnStringAndGetString(queryStr string, json string) (string, error)
- func RunJQOnStringAndMarshalResponse(queryStr string, json string, obj any) error
- func RunJQOnStringWithArray(queryStr string, json string) ([]interface{}, error)
- func RunJQWithArray(queryStr string, result interface{}) ([]interface{}, error)
- func ToJson(args []string, noWrapping bool, compliant bool, ...) (string, error)
Constants ¶
This section is empty.
Variables ¶
View Source
var KeysToDelete = []string{
".data.links",
".data.meta",
".data[].links",
".data[].meta",
".links",
".meta",
"..|nulls",
`..|select(. == {})`,
`..|select(. == {})`,
`..|select(. == "")`,
}
View Source
var MonochromeOutput = false
Functions ¶
func NewEncoder ¶
func PrettyPrint ¶ added in v0.10.0
func PrintJsonToStderr ¶ added in v0.5.0
func RunJQOnString ¶ added in v0.8.1
func RunJQOnStringAndGetString ¶ added in v0.12.0
func RunJQOnStringAndMarshalResponse ¶ added in v0.12.0
func RunJQOnStringWithArray ¶ added in v0.9.0
These copy and paste functions below, were because the existing functions were buggy if the iterator returns more than one thing, only the last is saved. it was deemed to risky to fix at the moment.
func RunJQWithArray ¶ added in v0.9.0
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.