53 lines
1.4 KiB
RPMSpec
53 lines
1.4 KiB
RPMSpec
|
|
%global goipath github.com/mikefarah/yq/v4
|
||
|
|
|
||
|
|
%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
|
||
|
|
Version: 4.44.2
|
||
|
|
Release: 1%{?dist}
|
||
|
|
Summary: Yq is a portable command-line YAML, JSON, XML, CSV, TOML and properties processor
|
||
|
|
|
||
|
|
License: MIT
|
||
|
|
URL: https://github.com/mikefarah/yq
|
||
|
|
Source: https://github.com/mikefarah/yq/archive/refs/tags/v%{version}.tar.gz
|
||
|
|
|
||
|
|
BuildRequires: golang-bin
|
||
|
|
BuildRequires: golang
|
||
|
|
|
||
|
|
%define debug_package %{nil}
|
||
|
|
|
||
|
|
%description
|
||
|
|
A lightweight and portable command-line YAML, JSON and XML processor.
|
||
|
|
yq uses jq like syntax but works with yaml files as well as json, xml, properties, csv and tsv.
|
||
|
|
It doesn't yet support everything jq does - but it does support the most common operations
|
||
|
|
and functions, and more is being added continuously.
|
||
|
|
|
||
|
|
%prep
|
||
|
|
%setup
|
||
|
|
%autopatch -p1
|
||
|
|
|
||
|
|
|
||
|
|
%build
|
||
|
|
go mod vendor
|
||
|
|
go build .
|
||
|
|
|
||
|
|
%install
|
||
|
|
install -m 0755 -vd %{buildroot}%{_bindir}
|
||
|
|
install -m 0755 -vp %{name} %{buildroot}%{_bindir}/%{name}
|
||
|
|
|
||
|
|
%check
|
||
|
|
go test ./...
|
||
|
|
|
||
|
|
%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
|
||
|
|
%{_bindir}/yq
|
||
|
|
|
||
|
|
%changelog
|
||
|
|
* Thu Aug 1 2024 Daniel Steiner <daniel.steiner@dsteiner.ch>
|
||
|
|
- First build.
|
||
|
|
|