Bug 259884 - [NEW PORT] textproc/gojq: Pure Go implementation of jq
Summary: [NEW PORT] textproc/gojq: Pure Go implementation of jq
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: Dries Michiels
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-11-16 19:09 UTC by Norikatsu Shigemura
Modified: 2021-12-01 13:42 UTC (History)
1 user (show)

See Also:


Attachments
textproc/gojq port (3.57 KB, patch)
2021-11-16 19:09 UTC, Norikatsu Shigemura
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Norikatsu Shigemura 2021-11-16 19:09:40 UTC
Created attachment 229540 [details]
textproc/gojq port

Add a Pure Go implementation of jq.

gojq is almost jq, but it has many many different from jq,
nice error messages for invalid query and JSON input, fixed
various bugs of jq, and YAML support...
See also https://github.com/itchyny/gojq#difference-to-jq
Comment 1 Dries Michiels freebsd_committer freebsd_triage 2021-11-21 14:46:00 UTC
Take
Comment 2 Dries Michiels freebsd_committer freebsd_triage 2021-11-21 14:49:18 UTC
Thanks for the patch!

From the porters handbook:

GO_MODULE
The name of the application module as specified by the module directive in go.mod. In most cases, this is the only required variable for ports that use Go modules.

Could you use that in the makfile? So something like this:

GO_MODULE= github.com/itchyny/gojq

Will do all the heavy lifting (can remove the the github tuples etc).
Comment 3 commit-hook freebsd_committer freebsd_triage 2021-12-01 13:40:33 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=8b46ce03f521842fc322d33c09b4c8f5bb90d746

commit 8b46ce03f521842fc322d33c09b4c8f5bb90d746
Author:     Norikatsu Shigemura <nork@ninth-nine.com>
AuthorDate: 2021-11-30 21:29:47 +0000
Commit:     Dries Michiels <driesm@FreeBSD.org>
CommitDate: 2021-12-01 13:36:59 +0000

    textproc/gojq: New port

    Pure Go implementation of jq.

    PR:                     259884
    Approved by:            philip (mentor)
    Differential Revision:  https://reviews.freebsd.org/D33204

 textproc/Makefile             |  1 +
 textproc/gojq/Makefile (new)  | 21 +++++++++++++++++++++
 textproc/gojq/distinfo (new)  |  5 +++++
 textproc/gojq/pkg-descr (new) |  4 ++++
 textproc/gojq/pkg-plist (new) |  2 ++
 5 files changed, 33 insertions(+)
Comment 4 Dries Michiels freebsd_committer freebsd_triage 2021-12-01 13:42:18 UTC
Committed with some minor modifications. Thanks!