mirror of
https://abf.rosa.ru/djam/finch.git
synced 2025-02-23 14:22:56 +00:00
61 lines
1.5 KiB
RPMSpec
61 lines
1.5 KiB
RPMSpec
%define debug %nil
|
|
%define debug_package %nil
|
|
%define secscan 0
|
|
|
|
Name: finch
|
|
Version: 1.4.1
|
|
Release: 1
|
|
Summary: The Finch CLI an open source client for container development
|
|
URL: https://github.com/runfinch/finch
|
|
Source0: %{url}/archive/v%{version}/%{name}-%{version}.tar.gz
|
|
License: ASL 2.0
|
|
Group: Development/Other
|
|
BuildRequires: go
|
|
BuildRequires: git-core
|
|
BuildRequires: upx
|
|
#BuildRequires: lima
|
|
%if %{secscan}
|
|
BuildRequires: clamav
|
|
BuildRequires: trivy
|
|
%endif
|
|
|
|
|
|
%description
|
|
Finch is an open source client for container development.
|
|
Its simple installer provides a minimal native client along
|
|
with an opinionated distribution of other open source
|
|
components. Rather than creating even more options to reason
|
|
about and choose from, Finch aims to help promote other
|
|
projects by making it easy to install and use them, while
|
|
offering a simple native client to tie it all together
|
|
|
|
%prep
|
|
%setup -q
|
|
%if %{secscan}
|
|
clamscan -ir .
|
|
trivy fs --scanners vuln --format cosign-vuln .
|
|
%endif
|
|
|
|
%build
|
|
export GOPROXY=https://proxy.golang.org/cached-only
|
|
export VERSION=%{verson}
|
|
#make %{name}
|
|
|
|
go build -ldflags "-s -w -X github.com/runfinch/finch/pkg/version.Version=%{version} -X github.com/runfinch/finch/pkg/version.GitCommit=.m" -o bin/%{name} ./cmd/finch
|
|
|
|
upx bin/finch
|
|
|
|
%install
|
|
install -Dm0755 bin/%{name} %{buildroot}%{_bindir}/%{name}
|
|
|
|
%files
|
|
%doc README.md LICENSE
|
|
%{_bindir}/%{name}
|
|
|
|
%check
|
|
export GOPROXY=https://proxy.golang.org/cached-only
|
|
#go test ./...
|
|
|
|
%if %{secscan}
|
|
clamscan -ir %{buildroot}
|
|
%endif
|