From 0b5f2047f829f5bee2366de135bb705dcaea6899 Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Fri, 25 Jul 2025 21:13:38 +0000 Subject: [PATCH 01/10] Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild From 5860566afe51e447d79692e11f1668c32effadd2 Mon Sep 17 00:00:00 2001 From: Maxwell G Date: Fri, 15 Aug 2025 18:48:15 -0500 Subject: [PATCH 02/10] Rebuild for golang-1.25.0 From e4018e8da8405f4c60fb56ca99a99d51b3a01511 Mon Sep 17 00:00:00 2001 From: Romain Geissler Date: Fri, 25 Jul 2025 23:07:21 +0000 Subject: [PATCH 03/10] Upgrade to upstream version 4.47.1 and use vendoring (rhbz#2282002). --- .gitignore | 2 ++ go-vendor-tools.toml | 8 +++++ sources | 3 +- yq-go1_24-replace_error_creation.diff | 29 ---------------- yq.spec | 48 ++++++++++++++------------- 5 files changed, 37 insertions(+), 53 deletions(-) create mode 100644 go-vendor-tools.toml delete mode 100644 yq-go1_24-replace_error_creation.diff diff --git a/.gitignore b/.gitignore index 9aebf04..9c01938 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,3 @@ /yq-4.43.1.tar.gz +/yq-4.47.1.tar.gz +/yq-4.47.1-vendor.tar.bz2 diff --git a/go-vendor-tools.toml b/go-vendor-tools.toml new file mode 100644 index 0000000..771eb1c --- /dev/null +++ b/go-vendor-tools.toml @@ -0,0 +1,8 @@ +[archive] + +[licensing] +detector = "askalono" +[[licensing.licenses]] +path = "vendor/go.yaml.in/yaml/v3/LICENSE" +sha256sum = "d18f6323b71b0b768bb5e9616e36da390fbd39369a81807cca352de4e4e6aa0b" +expression = "MIT AND (MIT AND Apache-2.0)" diff --git a/sources b/sources index 0a33990..db89950 100644 --- a/sources +++ b/sources @@ -1 +1,2 @@ -SHA512 (yq-4.43.1.tar.gz) = a3bb594421811db613118af5ba002e08ccb4b76a63ddf428bbdd4926cf8614217d67f47bfa4ad2c87361a96ade1841fde656fcf9ed700a8994333d61b9a80a8d +SHA512 (yq-4.47.1.tar.gz) = 16bec8fb67f4fb92fa881110028edbadf3e4fefeb3f59421c3c0e261acce9df6f085d12fadd0ae4b2212251e709bc6f6f692d133b4616cc450fbe6bbf5c43225 +SHA512 (yq-4.47.1-vendor.tar.bz2) = 1027061ebb90800dd2b163f3964f16fa05b4dddd44d18ea2c823c806775f5cb34c115fe1201d627e3c19fdf5b0463b54fb7697caa0486f1aeb55651abc744678 diff --git a/yq-go1_24-replace_error_creation.diff b/yq-go1_24-replace_error_creation.diff deleted file mode 100644 index 617187a..0000000 --- a/yq-go1_24-replace_error_creation.diff +++ /dev/null @@ -1,29 +0,0 @@ -From 6908161f1fb6713db8259909c606109770fe7673 Mon Sep 17 00:00:00 2001 -From: Marco Vito Moscaritolo -Date: Mon, 11 Nov 2024 14:06:04 +0100 -Subject: [PATCH] replace error creation - ---- - pkg/yqlib/operator_error.go | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/pkg/yqlib/operator_error.go b/pkg/yqlib/operator_error.go -index 1a2283de87..d6a2b67fed 100644 ---- a/pkg/yqlib/operator_error.go -+++ b/pkg/yqlib/operator_error.go -@@ -1,7 +1,7 @@ - package yqlib - - import ( -- "fmt" -+ "errors" - ) - - func errorOperator(d *dataTreeNavigator, context Context, expressionNode *ExpressionNode) (Context, error) { -@@ -16,5 +16,5 @@ func errorOperator(d *dataTreeNavigator, context Context, expressionNode *Expres - if rhs.MatchingNodes.Len() > 0 { - errorMessage = rhs.MatchingNodes.Front().Value.(*CandidateNode).Value - } -- return Context{}, fmt.Errorf(errorMessage) -+ return Context{}, errors.New(errorMessage) - } diff --git a/yq.spec b/yq.spec index f6e0b7b..e285baa 100644 --- a/yq.spec +++ b/yq.spec @@ -1,58 +1,60 @@ -# Generated by go2rpm 1.11.1 -%bcond_without check +# Generated by go2rpm 1.17.1 +%bcond check 1 # https://github.com/mikefarah/yq %global goipath github.com/mikefarah/yq/v4 -Version: 4.43.1 +Version: 4.47.1 %gometa -L -f -%global common_description %{expand: -Yq is a portable command-line YAML, JSON, XML, CSV, TOML and properties -processor.} - -%global golicenses LICENSE -%global godocs examples CODE_OF_CONDUCT.md how-it-works.md project-\\\ - words.txt release_instructions.txt CONTRIBUTING.md\\\ - README.md release_notes.txt Name: yq Release: %autorelease Summary: Yq is a portable command-line YAML, JSON, XML, CSV, TOML and properties processor -License: MIT +# Generated by go-vendor-tools +License: Apache-2.0 AND BSD-2-Clause AND BSD-3-Clause AND MIT URL: %{gourl} -Source: %{gosource} -Patch: https://github.com/mikefarah/yq/commit/6908161f1fb6713db8259909c606109770fe7673.patch#/yq-go1_24-replace_error_creation.diff +Source0: %{gosource} +# Generated by go-vendor-tools +Source1: %{archivename}-vendor.tar.bz2 +Source2: go-vendor-tools.toml -%description %{common_description} +BuildRequires: go-vendor-tools -%gopkg +%description +Yq is a portable command-line YAML, JSON, XML, CSV, TOML and properties +processor. %prep %goprep -A +%setup -q -T -D -a1 %{forgesetupargs} %autopatch -p1 %generate_buildrequires -%go_generate_buildrequires +%go_vendor_license_buildrequires -c %{S:2} %build +%global gomodulesmode GO111MODULE=on %gobuild -o %{gobuilddir}/bin/yq %{goipath} %install +%go_vendor_license_install -c %{S:2} install -m 0755 -vd %{buildroot}%{_bindir} install -m 0755 -vp %{gobuilddir}/bin/* %{buildroot}%{_bindir}/ -%if %{with check} %check -%gocheck +%go_vendor_license_check -c %{S:2} +%if %{with check} +%gotest ./... %endif -%files -%license LICENSE -%doc examples CODE_OF_CONDUCT.md how-it-works.md project-words.txt -%doc release_instructions.txt CONTRIBUTING.md README.md release_notes.txt +%files -f %{go_vendor_license_filelist} +%license vendor/modules.txt +%doc examples CODE_OF_CONDUCT.md CONTRIBUTING.md README.md how-it-works.md +%doc project-words.txt release_instructions.txt release_notes.txt %{_bindir}/yq + %changelog %autochangelog From e19346b601840140d3b8570029d849651fb22bcc Mon Sep 17 00:00:00 2001 From: Mikel Olasagasti Uranga Date: Fri, 29 Aug 2025 16:21:01 +0200 Subject: [PATCH 04/10] Add shell completions --- yq.spec | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/yq.spec b/yq.spec index e285baa..45fbeae 100644 --- a/yq.spec +++ b/yq.spec @@ -38,11 +38,19 @@ processor. %global gomodulesmode GO111MODULE=on %gobuild -o %{gobuilddir}/bin/yq %{goipath} +%{gobuilddir}/bin/%{name} shell-completion bash > %{name}.bash +%{gobuilddir}/bin/%{name} shell-completion fish > %{name}.fish +%{gobuilddir}/bin/%{name} shell-completion zsh > %{name}.zsh + %install %go_vendor_license_install -c %{S:2} install -m 0755 -vd %{buildroot}%{_bindir} install -m 0755 -vp %{gobuilddir}/bin/* %{buildroot}%{_bindir}/ +install -Dpm 0644 %{name}.bash %{buildroot}%{bash_completions_dir}/%{name} +install -Dpm 0644 %{name}.fish %{buildroot}%{fish_completions_dir}/%{name}.fish +install -Dpm 0644 %{name}.zsh %{buildroot}%{zsh_completions_dir}/_%{name} + %check %go_vendor_license_check -c %{S:2} %if %{with check} @@ -54,6 +62,9 @@ install -m 0755 -vp %{gobuilddir}/bin/* %{buildroot}%{_bindir}/ %doc examples CODE_OF_CONDUCT.md CONTRIBUTING.md README.md how-it-works.md %doc project-words.txt release_instructions.txt release_notes.txt %{_bindir}/yq +%{bash_completions_dir}/%{name} +%{fish_completions_dir}/%{name}.fish +%{zsh_completions_dir}/_%{name} %changelog From d2295bbe56412e6a6204a60a507bba517eaf7b57 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alejandro=20S=C3=A1ez?= Date: Fri, 10 Oct 2025 16:40:28 +0200 Subject: [PATCH 05/10] rebuild From 9ea538ca37b94920259093fdf0b41b1c747daade Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Sat, 17 Jan 2026 21:03:23 +0000 Subject: [PATCH 06/10] Rebuilt for https://fedoraproject.org/wiki/Fedora_44_Mass_Rebuild From a93b68f43017d9e984854b657770278ecc1ab36e Mon Sep 17 00:00:00 2001 From: Maxwell G Date: Mon, 2 Feb 2026 20:04:38 -0600 Subject: [PATCH 07/10] Rebuild for https://fedoraproject.org/wiki/Changes/golang1.26 From 1e417689deb66a73dce7d332b98073e33a6dfa39 Mon Sep 17 00:00:00 2001 From: Mikel Olasagasti Uranga Date: Tue, 14 Jul 2026 11:45:43 +0200 Subject: [PATCH 08/10] Update to 4.53.3 and add packit integration --- .gitignore | 2 ++ .packit.yaml | 34 ++++++++++++++++++++++++++++++++++ go-vendor-tools.toml | 6 +++--- sources | 4 ++-- yq.spec | 21 ++++++++++----------- 5 files changed, 51 insertions(+), 16 deletions(-) create mode 100644 .packit.yaml diff --git a/.gitignore b/.gitignore index 9c01938..822b084 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,5 @@ /yq-4.43.1.tar.gz /yq-4.47.1.tar.gz /yq-4.47.1-vendor.tar.bz2 +/yq-4.53.3.tar.gz +/yq-4.53.3-vendor.tar.bz2 diff --git a/.packit.yaml b/.packit.yaml new file mode 100644 index 0000000..167cb29 --- /dev/null +++ b/.packit.yaml @@ -0,0 +1,34 @@ +--- +downstream_package_name: yq +upstream_project_url: https://github.com/mikefarah/yq +upstream_tag_template: "v{version}" + +jobs: + - job: pull_from_upstream + trigger: release + dist_git_branches: + rawhide: + fast_forward_merge_into: + - fedora-branched + - epel-all + + - job: koji_build + trigger: commit + dist_git_branches: + - rawhide +actions: + post-modifications: + - | + sh -xeuc " + cd $PACKIT_DOWNSTREAM_REPO + export GOTOOLCHAIN=local+auto + spec="$PACKIT_DOWNSTREAM_PACKAGE_NAME.spec" + go_vendor_archive create --config go-vendor-tools.toml "$spec" + go_vendor_license \ + --config go-vendor-tools.toml \ + --path "$spec" \ + report \ + --verify-spec \ + --autofill=auto + " +create_sync_note: false diff --git a/go-vendor-tools.toml b/go-vendor-tools.toml index 771eb1c..f4fa890 100644 --- a/go-vendor-tools.toml +++ b/go-vendor-tools.toml @@ -3,6 +3,6 @@ [licensing] detector = "askalono" [[licensing.licenses]] -path = "vendor/go.yaml.in/yaml/v3/LICENSE" -sha256sum = "d18f6323b71b0b768bb5e9616e36da390fbd39369a81807cca352de4e4e6aa0b" -expression = "MIT AND (MIT AND Apache-2.0)" +path = "vendor/github.com/apparentlymart/go-textseg/v15/LICENSE" +sha256sum = "59e80949c14925f65181757d837ed93dea3783f62b031f642281d9e5b1936917" +expression = "(MIT AND Apache-2.0) AND Unicode-3.0" diff --git a/sources b/sources index db89950..cae3158 100644 --- a/sources +++ b/sources @@ -1,2 +1,2 @@ -SHA512 (yq-4.47.1.tar.gz) = 16bec8fb67f4fb92fa881110028edbadf3e4fefeb3f59421c3c0e261acce9df6f085d12fadd0ae4b2212251e709bc6f6f692d133b4616cc450fbe6bbf5c43225 -SHA512 (yq-4.47.1-vendor.tar.bz2) = 1027061ebb90800dd2b163f3964f16fa05b4dddd44d18ea2c823c806775f5cb34c115fe1201d627e3c19fdf5b0463b54fb7697caa0486f1aeb55651abc744678 +SHA512 (yq-4.53.3.tar.gz) = 420825768e0806ee82393dd80dccedcd8f62a31a2ed14b1ba1a22c89a8fcf34c5100cb1efa7e38bea9f4f6db07450417701dd1193588e5f48b04f9baad8cb28e +SHA512 (yq-4.53.3-vendor.tar.bz2) = 9f13dfd7619b60ba6352e340ba5e3dfa48794fc04d2a5ff618dc2004c346dd0520f0215b1eff06d1749b6c05dbd81239b17d1b411e39b22d3b591fa83f8fec8f diff --git a/yq.spec b/yq.spec index 45fbeae..77bafdf 100644 --- a/yq.spec +++ b/yq.spec @@ -1,19 +1,19 @@ -# Generated by go2rpm 1.17.1 +# Generated by go2rpm 1.19.0 %bcond check 1 # https://github.com/mikefarah/yq %global goipath github.com/mikefarah/yq/v4 -Version: 4.47.1 +Version: 4.53.3 %gometa -L -f Name: yq Release: %autorelease -Summary: Yq is a portable command-line YAML, JSON, XML, CSV, TOML and properties processor +Summary: Yq is a portable command-line YAML, JSON, XML, CSV, TOML, HCL and properties processor # Generated by go-vendor-tools -License: Apache-2.0 AND BSD-2-Clause AND BSD-3-Clause AND MIT +License: Apache-2.0 AND BSD-2-Clause AND BSD-3-Clause AND MIT AND MPL-2.0 AND Unicode-3.0 URL: %{gourl} Source0: %{gosource} # Generated by go-vendor-tools @@ -23,13 +23,12 @@ Source2: go-vendor-tools.toml BuildRequires: go-vendor-tools %description -Yq is a portable command-line YAML, JSON, XML, CSV, TOML and properties +Yq is a portable command-line YAML, JSON, XML, CSV, TOML, HCL and properties processor. %prep -%goprep -A -%setup -q -T -D -a1 %{forgesetupargs} -%autopatch -p1 +%goprep -p1 +tar -xf %{S:1} %generate_buildrequires %go_vendor_license_buildrequires -c %{S:2} @@ -58,9 +57,9 @@ install -Dpm 0644 %{name}.zsh %{buildroot}%{zsh_completions_dir}/_%{name} %endif %files -f %{go_vendor_license_filelist} -%license vendor/modules.txt -%doc examples CODE_OF_CONDUCT.md CONTRIBUTING.md README.md how-it-works.md -%doc project-words.txt release_instructions.txt release_notes.txt +%doc examples CODE_OF_CONDUCT.md CONTRIBUTING.md README.md SECURITY.md +%doc how-it-works.md project-words.txt release_instructions.txt +%doc release_notes.txt %{_bindir}/yq %{bash_completions_dir}/%{name} %{fish_completions_dir}/%{name}.fish From f2a5285f11f16c469940d9bafd35dc0ee9b5f091 Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Fri, 17 Jul 2026 09:35:56 +0000 Subject: [PATCH 09/10] Rebuilt for https://fedoraproject.org/wiki/Fedora_45_Mass_Rebuild From 2592ddd904fad8d7efccdc8f02a2f947be8608fb Mon Sep 17 00:00:00 2001 From: Packit Date: Wed, 19 Aug 2026 06:49:22 +0000 Subject: [PATCH 10/10] Update to 4.53.4 upstream release - Resolves: rhbz#2519404 Upstream tag: v4.53.4 Upstream commit: ce7026e3 Commit authored by Packit automation (https://packit.dev/) --- .gitignore | 2 ++ sources | 4 ++-- yq.spec | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index 822b084..a17047c 100644 --- a/.gitignore +++ b/.gitignore @@ -3,3 +3,5 @@ /yq-4.47.1-vendor.tar.bz2 /yq-4.53.3.tar.gz /yq-4.53.3-vendor.tar.bz2 +/yq-4.53.4.tar.gz +/yq-4.53.4-vendor.tar.bz2 diff --git a/sources b/sources index cae3158..ff85f49 100644 --- a/sources +++ b/sources @@ -1,2 +1,2 @@ -SHA512 (yq-4.53.3.tar.gz) = 420825768e0806ee82393dd80dccedcd8f62a31a2ed14b1ba1a22c89a8fcf34c5100cb1efa7e38bea9f4f6db07450417701dd1193588e5f48b04f9baad8cb28e -SHA512 (yq-4.53.3-vendor.tar.bz2) = 9f13dfd7619b60ba6352e340ba5e3dfa48794fc04d2a5ff618dc2004c346dd0520f0215b1eff06d1749b6c05dbd81239b17d1b411e39b22d3b591fa83f8fec8f +SHA512 (yq-4.53.4.tar.gz) = f5edb9198abfbfff0e54fa7f0de7fa2d34184716fffdd34360e955fa1eca0b06c3f268713cf459863de688648e3ce535f1c2851342b90690904de330fd9f94f3 +SHA512 (yq-4.53.4-vendor.tar.bz2) = 6121e2e7f20642452ec63f3f652ca416eedd9004a6dc5c2854f10fb06657a417277bde379e6759f9d940c162ff4b6587aee9869fcf1475f6aa39dfadaa6f59ac diff --git a/yq.spec b/yq.spec index 77bafdf..75bdca6 100644 --- a/yq.spec +++ b/yq.spec @@ -3,7 +3,7 @@ # https://github.com/mikefarah/yq %global goipath github.com/mikefarah/yq/v4 -Version: 4.53.3 +Version: 4.53.4 %gometa -L -f