[Rpm-maint] [rpm-software-management/rpm] Implement --json query format (PR #2913)

Panu Matilainen notifications at github.com
Fri Feb 16 09:24:49 UTC 2024


The existing --xml output is extremely useful when inspecting oddities but the format is such an eyesore. JSON is much saner to look at.

Details in the commits and their messages, but the first commits are just refactoring to make this feasible. The actual feature in the last commit is quite small, as often happens the tests are bigger than the actual patch.

You can view, comment on, or merge this pull request online at:

  https://github.com/rpm-software-management/rpm/pull/2913

-- Commit Summary --

  * Refactor header format string append to a helper function
  * Generalize xml header formatting to support other formats too
  * Refactor tag name formatting to a helper function
  * Implement --json query format

-- File Changes --

    M docs/man/rpm.8.md (6)
    M include/rpm/rpmtd.h (1)
    M lib/formats.c (27)
    M lib/headerfmt.c (225)
    M rpmpopt.in (3)
    M tests/rpmquery.at (260)

-- Patch Links --

https://github.com/rpm-software-management/rpm/pull/2913.patch
https://github.com/rpm-software-management/rpm/pull/2913.diff

-- 
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/pull/2913
You are receiving this because you are subscribed to this thread.

Message ID: <rpm-software-management/rpm/pull/2913 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rpm.org/pipermail/rpm-maint/attachments/20240216/9aa73ba0/attachment.html>


More information about the Rpm-maint mailing list