ruby-kramdown/ruby-kramdown.spec

61 lines
1.9 KiB
RPMSpec
Raw Normal View History

%define gitver %(echo %version | tr . _)
Name: ruby-kramdown
Version: 2.4.0
Release: 1mamba
Summary: Fast, pure Ruby Markdown superset converter, using a strict syntax definition
Group: System/Libraries
Vendor: openmamba
Distribution: openmamba
Packager: Silvan Calarco <silvan.calarco@mambasoft.it>
URL: https://kramdown.gettalong.org/
Source: https://github.com/gettalong/kramdown.git/REL_%{gitver}/kramdown-%{version}.tar.bz2
License: MIT
## AUTOBUILDREQ-BEGIN
## AUTOBUILDREQ-END
BuildRequires: ruby-devel
Requires: ruby
%description
Fast, pure Ruby Markdown superset converter, using a strict syntax definition.
%prep
%setup -q -n kramdown-%{version}
rake gemspec
sed -r 's|~>|>=|g' -i kramdown.gemspec
%build
gem build kramdown.gemspec
%install
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
gemdir="$(ruby -rrubygems -e'puts Gem.default_dir')"
gem install --no-user-install --ignore-dependencies -i "%{buildroot}$gemdir" -n "%{buildroot}%{_bindir}" \
kramdown-%{version}.gem
rm -rf %{buildroot}${gemdir}/cache
install -d -m0755 %{buildroot}%{_mandir}/man1
mv %{buildroot}${gemdir}/gems/kramdown-%{version}/man/man1/kramdown.1 %{buildroot}%{_mandir}/man1/kramdown.1
%clean
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
%files
%defattr(-,root,root)
%{_bindir}/kramdown
%dir %{_libdir}/ruby/gems/*/doc/kramdown-%{version}
%{_libdir}/ruby/gems/*/doc/kramdown-%{version}/*
%dir %{_libdir}/ruby/gems/*/gems/kramdown-%{version}
%{_libdir}/ruby/gems/*/gems/kramdown-%{version}/*
%{_libdir}/ruby/gems/*/specifications/kramdown-%{version}.gemspec
%{_mandir}/man1/kramdown.1*
%doc AUTHORS COPYING
%changelog
* Wed Dec 06 2023 Silvan Calarco <silvan.calarco@mambasoft.it> 2.4.0-1mamba
- update to 2.4.0
* Sat Apr 23 2022 Silvan Calarco <silvan.calarco@mambasoft.it> 2.3.2-1mamba
- package created using the webbuild interface