https://github.com/JFryy/qq Skip to content Navigation Menu Toggle navigation Sign in * Product + Actions Automate any workflow + Packages Host and manage packages + Security Find and fix vulnerabilities + Codespaces Instant dev environments + GitHub Copilot Write better code with AI + Code review Manage code changes + Issues Plan and track work + Discussions Collaborate outside of code Explore + All features + Documentation + GitHub Skills + Blog * Solutions By size + Enterprise + Teams + Startups By industry + Healthcare + Financial services + Manufacturing By use case + CI/CD & Automation + DevOps + DevSecOps * Resources Resources + Learning Pathways + White papers, Ebooks, Webinars + Customer Stories + Partners * Open Source + GitHub Sponsors Fund open source developers + The ReadME Project GitHub community articles Repositories + Topics + Trending + Collections * Enterprise + Enterprise platform AI-powered developer platform Available add-ons + Advanced Security Enterprise-grade security features + GitHub Copilot Enterprise-grade AI features + Premium Support Enterprise-grade 24/7 support * Pricing Search or jump to... Search code, repositories, users, issues, pull requests... Search [ ] Clear Search syntax tips Provide feedback We read every piece of feedback, and take your input very seriously. [ ] [ ] Include my email address so I can be contacted Cancel Submit feedback Saved searches Use saved searches to filter your results more quickly Name [ ] Query [ ] To see all available qualifiers, see our documentation. Cancel Create saved search Sign in Sign up You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. Dismiss alert {{ message }} JFryy / qq Public * Notifications You must be signed in to change notification settings * Fork 0 * Star 191 jq inspired interoperable config format transcoder with interactive querying. License MIT license 191 stars 0 forks Branches Tags Activity Star Notifications You must be signed in to change notification settings * Code * Issues 1 * Pull requests 0 * Actions * Projects 0 * Security * Insights Additional navigation options * Code * Issues * Pull requests * Actions * Projects * Security * Insights JFryy/qq This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository. main BranchesTags Go to file Code Folders and files Name Name Last commit Last commit message date Latest commit History 13 Commits .github/workflows .github/ workflows cli cli codec codec docs docs internal/tui internal/tui tests tests .gitignore .gitignore Dockerfile Dockerfile LICENSE LICENSE Makefile Makefile README.md README.md go.mod go.mod go.sum go.sum main.go main.go View all files Repository files navigation * README * MIT license qq qq is a interoperable configuration format transcoder with jq query syntax powered by gojq. qq is multi modal, and can be used as a replacement for jq or be interacted with via a repl with autocomplete and realtime rendering preview for building queries. Usage Basic usage: [6874747073] # query file and infer format from extension qq .foo.bar file.xml # query file through pipe, transcode xml -> terraform (it can be done but it probably shouldn't) cat file.xml | qq '.bar.foo[].meep' -i xml -o tf # interactive query builder mode on target file qq . file.toml --interactive Installation From source (requires go >=1.22.4) make install Download at releases here. Background qq is inspired by fq and jq. jq is a powerful and succinct query tool, sometimes I would find myself needing to use another bespoke tool for another format than json, whether its something dedicated with json query built in or a simple converter from one configuration format to json to pipe into jq. qq aims to be the only utility needed for most interaction with structured formats in the terminal. It can transcode configuration formats interchangeably between one-another with the power of jq and it has an an interactive repl (with automcomplete) to boot so you can have an interactive experience when building queries optionally. Many thanks to the authors of the libraries used in this project, especially jq, gojq, and fq for direct usage or inspiration for the project. Features * support a wide range of configuration formats and transform them interchangeably between eachother. * quick and comprehensive querying of configuration formats without needing a pipeline of dedicated tools. * provide a fun to use interactive mode for building queries with autocomplete and realtime rendering preview. * qq is broad, but focuses on performance of encodings (but mostly gojq is very fast), execution is often times faster than most any "jq but for ${x} configuration format"-type tools. qq performs similarly to benchmarks of jq running on JSON itself in most covered formats. Supported formats Note: these unsupported formats are on a roadmap for inclusion. Format Input Output JSON Supported Supported YAML Supported Supported TOML Supported Supported XML Supported Supported INI Supported Supported HCL Supported Supported TF Supported Supported CSV Supported Not Supported Protobuf Not Supported Not Supported HTML Not Supported Not Supported Caveats * qq is not a full jq/*q replacement and comes with idiosyncrasies from the underlying gojq library. * the encoders and decoders are not perfect and may not be able to handle all edge cases. * qq is under active development and more codecs are intended to be supported along with improvements to interactive mode. Contributions All contributions are welcome to qq, especially for upkeep/ optimization/addition of new encodings. For ideas on contributions please refer to the todo docs or make an issue/PR for a suggestion if there's something that's wanted or fixes. Thanks and Acknowledgements / Related Projects * gojq: gojq is a pure Go implementation of jq. It is used to power the query engine of qq. * fq : fq is a jq like tool for querying a wide array of binary formats. * Many encoding modules About jq inspired interoperable config format transcoder with interactive querying. Topics config go golang yaml toml json csv transcoding terraform jq hcl ini Resources Readme License MIT license Activity Stars 191 stars Watchers 3 watching Forks 0 forks Report repository Releases 1 v.0.1.1-alpha Latest Jun 23, 2024 Packages 0 No packages published Languages * Go 87.7% * Shell 5.8% * HCL 4.6% * Makefile 1.1% * Dockerfile 0.8% Footer (c) 2024 GitHub, Inc. Footer navigation * Terms * Privacy * Security * Status * Docs * Contact * Manage cookies * Do not share my personal information You can't perform that action at this time.