You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
87 lines
2.2 KiB
87 lines
2.2 KiB
# Generated by rust2rpm 17
|
|
%bcond_without check
|
|
%global __cargo_skip_build 0
|
|
|
|
%global crate ripgrep
|
|
|
|
Name: rust-%{crate}
|
|
Version: 13.0.0
|
|
Release: %autorelease
|
|
Summary: Line oriented search tool
|
|
|
|
# Upstream license specification: Unlicense OR MIT
|
|
License: Unlicense or MIT
|
|
URL: https://crates.io/crates/ripgrep
|
|
Source: %{crates_source}
|
|
# Initial patched metadata
|
|
# * drop unsupported SIMD feature
|
|
# * drop unsupported jemalloc feature
|
|
Patch0: ripgrep-fix-metadata.diff
|
|
|
|
ExclusiveArch: %{rust_arches}
|
|
|
|
BuildRequires: rust-packaging
|
|
|
|
%global _description %{expand:
|
|
Line-oriented search tool that recursively searches the current directory for a
|
|
regex pattern while respecting gitignore rules. ripgrep has first class support
|
|
on Windows, macOS and Linux.}
|
|
|
|
%description %{_description}
|
|
|
|
%package -n %{crate}
|
|
Summary: %{summary}
|
|
# ASL 2.0 or Boost
|
|
# ASL 2.0 or MIT
|
|
# MIT
|
|
# MIT or ASL 2.0
|
|
# Unlicense or MIT
|
|
License: MIT and (ASL 2.0 or Boost)
|
|
|
|
%description -n %{crate} %{_description}
|
|
|
|
%files -n %{crate}
|
|
%license LICENSE-MIT UNLICENSE COPYING
|
|
%doc README.md CHANGELOG.md FAQ.md GUIDE.md
|
|
%{_bindir}/rg
|
|
%{_mandir}/man1/rg.1*
|
|
%dir %{_datadir}/bash-completion
|
|
%dir %{_datadir}/bash-completion/completions
|
|
%{_datadir}/bash-completion/completions/rg.bash
|
|
%dir %{_datadir}/fish
|
|
%dir %{_datadir}/fish/vendor_completions.d
|
|
%{_datadir}/fish/vendor_completions.d/rg.fish
|
|
%dir %{_datadir}/zsh
|
|
%dir %{_datadir}/zsh/site-functions
|
|
%{_datadir}/zsh/site-functions/_rg
|
|
|
|
%prep
|
|
%autosetup -n %{crate}-%{version_no_tilde} -p1
|
|
%cargo_prep
|
|
|
|
%generate_buildrequires
|
|
%cargo_generate_buildrequires -a
|
|
echo '/usr/bin/asciidoctor'
|
|
|
|
%build
|
|
%cargo_build -a
|
|
|
|
%install
|
|
%cargo_install -a
|
|
install -Dpm0644 -t %{buildroot}%{_mandir}/man1 \
|
|
target/release/build/%{crate}-*/out/rg.1
|
|
install -Dpm0644 -t %{buildroot}%{_datadir}/bash-completion/completions \
|
|
target/release/build/%{crate}-*/out/rg.bash
|
|
install -Dpm0644 -t %{buildroot}%{_datadir}/fish/vendor_completions.d \
|
|
target/release/build/%{crate}-*/out/rg.fish
|
|
install -Dpm0644 -t %{buildroot}%{_datadir}/zsh/site-functions \
|
|
complete/_rg
|
|
|
|
%if %{with check}
|
|
%check
|
|
%cargo_test -a
|
|
%endif
|
|
|
|
%changelog
|
|
%autochangelog
|