commit
2c3d37406f
82
rubygem-sprockets.spec
Normal file
82
rubygem-sprockets.spec
Normal file
@ -0,0 +1,82 @@
|
|||||||
|
%global gem_name sprockets
|
||||||
|
Name: rubygem-%{gem_name}
|
||||||
|
Version: 3.7.2
|
||||||
|
Release: 1
|
||||||
|
Summary: Rack-based asset packaging system
|
||||||
|
License: MIT
|
||||||
|
URL: https://github.com/rails/sprockets
|
||||||
|
Source0: https://rubygems.org/gems/sprockets-%{version}.gem
|
||||||
|
Source1: https://github.com/rails/sprockets/archive/v%{version}.tar.gz
|
||||||
|
BuildRequires: ruby(release) rubygems-devel ruby >= 1.9.3 rubygem(concurrent-ruby)
|
||||||
|
BuildRequires: rubygem(coffee-script) rubygem(ejs) rubygem(execjs) rubygem(minitest)
|
||||||
|
BuildRequires: rubygem(nokogiri) rubygem(rack-test) rubygem(rake) rubygem(sass)
|
||||||
|
BuildRequires: rubygem(uglifier) help2man nodejs
|
||||||
|
BuildArch: noarch
|
||||||
|
%description
|
||||||
|
Sprockets is a Rack-based asset packaging system that concatenates and serves
|
||||||
|
JavaScript, CoffeeScript, CSS, LESS, Sass, and SCSS.
|
||||||
|
|
||||||
|
%package help
|
||||||
|
Summary: Documentation for %{name}
|
||||||
|
Requires: %{name} = %{version}-%{release}
|
||||||
|
BuildArch: noarch
|
||||||
|
Provides: %{name}-doc = %{version}-%{release}
|
||||||
|
Obsoletes: %{name}-doc < %{version}-%{release}
|
||||||
|
%description help
|
||||||
|
Documentation for %{name}.
|
||||||
|
|
||||||
|
%prep
|
||||||
|
%setup -q -c -T
|
||||||
|
%gem_install -n %{SOURCE0}
|
||||||
|
|
||||||
|
%build
|
||||||
|
|
||||||
|
%install
|
||||||
|
mkdir -p %{buildroot}%{gem_dir}
|
||||||
|
cp -a .%{gem_dir}/* \
|
||||||
|
%{buildroot}%{gem_dir}/
|
||||||
|
mkdir -p %{buildroot}%{_bindir}
|
||||||
|
cp -a .%{_bindir}/* \
|
||||||
|
%{buildroot}%{_bindir}/
|
||||||
|
find %{buildroot}%{gem_instdir}/bin -type f | xargs chmod a+x
|
||||||
|
export GEM_PATH="%{buildroot}/%{gem_dir}:%{gem_dir}"
|
||||||
|
mkdir -p %{buildroot}%{_mandir}/man1
|
||||||
|
help2man --no-discard-stderr -N -s1 -o %{buildroot}%{_mandir}/man1/%{gem_name}.1 \
|
||||||
|
%{buildroot}/usr/share/gems/gems/%{gem_name}-%{version}/bin/%{gem_name}
|
||||||
|
|
||||||
|
%check
|
||||||
|
pushd .%{gem_instdir}
|
||||||
|
tar xzf %{SOURCE1}
|
||||||
|
cd %{gem_name}-%{version}
|
||||||
|
mv test/test_closure_compressor.rb{,.disabled}
|
||||||
|
mv lib/sprockets/autoload/closure.rb{,.disabled}
|
||||||
|
sed -i '/:Closure/ s/^/#/' lib/sprockets/autoload.rb
|
||||||
|
mv test/test_eco_processor.rb{,.disabled}
|
||||||
|
mv lib/sprockets/autoload/eco.rb{,.disabled}
|
||||||
|
sed -i '/:Eco/ s/^/#/' lib/sprockets/autoload.rb
|
||||||
|
sed -i '/test "eco templates" do/,/^ end/ s/^/#/' test/test_environment.rb
|
||||||
|
mv test/test_yui_compressor.rb{,.disabled}
|
||||||
|
mv lib/sprockets/autoload/yui.rb{,.disabled}
|
||||||
|
sed -i '/:YUI/ s/^/#/' lib/sprockets/autoload.rb
|
||||||
|
touch Gemfile
|
||||||
|
RUBYOPT=-Ilib:test ruby -e 'Dir.glob "./test/**/test_*.rb", &method(:require)'
|
||||||
|
popd
|
||||||
|
|
||||||
|
%files
|
||||||
|
%dir %{gem_instdir}
|
||||||
|
%{_bindir}/sprockets
|
||||||
|
%license %{gem_instdir}/LICENSE
|
||||||
|
%{gem_instdir}/bin
|
||||||
|
%{gem_libdir}
|
||||||
|
%exclude %{gem_cache}
|
||||||
|
%{gem_spec}
|
||||||
|
%{_mandir}/man1/%{gem_name}.1*
|
||||||
|
|
||||||
|
%files help
|
||||||
|
%doc %{gem_docdir}
|
||||||
|
%doc %{gem_instdir}/CHANGELOG.md
|
||||||
|
%doc %{gem_instdir}/README.md
|
||||||
|
|
||||||
|
%changelog
|
||||||
|
* Mon Aug 24 2020 liyanan <liyanan32@huawei.com> - 3.7.2-1
|
||||||
|
- package init
|
||||||
5
rubygem-sprockets.yaml
Normal file
5
rubygem-sprockets.yaml
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
git_url: https://github.com/rails/sprockets.git
|
||||||
|
version_control: github
|
||||||
|
src_repo: rails/sprockets
|
||||||
|
tag_prefix: "^v"
|
||||||
|
seperator: "."
|
||||||
BIN
sprockets-3.7.2.gem
Normal file
BIN
sprockets-3.7.2.gem
Normal file
Binary file not shown.
BIN
v3.7.2.tar.gz
Normal file
BIN
v3.7.2.tar.gz
Normal file
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user