Favicon of fq

fq

CLI tool for inspecting, querying, and transforming binary formats including executables, codecs, and serialization formats with interactive REPL support.

fq is a powerful command-line tool designed for working with binary data using jq-like syntax and expressions. It combines the functionality of jq, hexdump, dd, and gdb into a single unified tool, making binary format inspection and manipulation accessible to developers.

The tool excels at querying and debugging binary formats across a wide range of file types. Whether you're working with media codecs like MP4 and FLAC, executable files, packet captures with TCP reassembly, or serialization formats such as JSON, YAML, XML, CBOR, and protobuf, fq provides a consistent interface for exploration and analysis.

Key capabilities include:

  • Decoded tree structures that display binary data in human-readable hierarchical formats
  • Data transformation allowing you to slice, concatenate, and modify binary content
  • Nested format support for complex file structures with multiple layers
  • Interactive REPL with auto-completion of functions and field names for exploratory work
  • Extensive format support covering 100+ formats including media files, archives, databases, and network protocols
  • Bit-oriented decoding for precise control over binary data interpretation

Basic usage is straightforward: fq . file displays the decoded structure, fq d file shows details, or fq 'some query' file executes custom jq expressions. The tool also handles common text formats and provides functions for URL manipulation, hex conversion, base64 encoding, and pattern searching.

fq is particularly valuable for developers engaged in debugging, data transformation, and format validation, offering a quick and comfortable way to inspect file structures without switching between multiple specialized tools.

Install

Brew
$ brew install wader/tap/fq

Features

JSON outputScriptable

Media

Pros

4
  • Inspect, query, and transform binary formats
  • Interactive REPL with auto-completion
  • Supports a wide variety of binary and text formats
  • Inspired by jq for powerful data manipulation

Cons

1
  • Steeper learning curve for complex binary formats

Related tools

Share:

Auto-fetched .

Recent releases

Similar to fq

Favicon

 

  
 
Favicon

 

  
 
Favicon