DigiNews

Tech Watch by Johan Denoyer

← Back to articles

Using jq to format JSON on the clipboard

Quality: 6/10 Relevance: 9/10

Summary

A practical blog post demonstrating how to use jq to pretty-print JSON that’s on the clipboard across macOS and Linux, with a tweak to handle non-JSON input gracefully. It includes code snippets for macOS (pbpaste | jq '.' | pbcopy) and Linux (xclip -selection clipboard -o | jq '.' | xclip -selection clipboard), discusses error handling, and links to related JSON/terminal topics.

🚀 Service construit par Johan Denoyer