package init
This commit is contained in:
parent
f308cf0e13
commit
6f457635ec
65
nodejs-rollup.spec
Normal file
65
nodejs-rollup.spec
Normal file
@ -0,0 +1,65 @@
|
||||
%{?nodejs_find_provides_and_requires}
|
||||
%global packagename rollup
|
||||
%global enable_tests 0
|
||||
Name: nodejs-rollup
|
||||
Version: 0.41.6
|
||||
Release: 1
|
||||
Summary: Next-generation ES6 module bundler
|
||||
License: MIT
|
||||
URL: https://github.com/rollup/rollup
|
||||
Source0: https://registry.npmjs.org/%{packagename}/-/%{packagename}-%{version}.tgz
|
||||
#git clone https://github.com/rollup/rollup
|
||||
#cd test
|
||||
#git archive --prefix='test/' --format=tar tags/v%{version}:test/ | bzip2 > tests-%{version}.tar.bz2
|
||||
Source1: tests-%{version}.tar.bz2
|
||||
#git clone https://github.com/rollup/rollup
|
||||
#cd src
|
||||
#git archive --prefix='src/' --format=tar tags/v%{version}:src/ | bzip2 > src-%{version}.tar.bz2
|
||||
Source2: src-%{version}.tar.bz2
|
||||
BuildArch: noarch
|
||||
ExclusiveArch: %{nodejs_arches} noarch
|
||||
BuildRequires: nodejs-packaging
|
||||
%if 0%{?enable_tests}
|
||||
BuildRequires: mocha npm(buble)
|
||||
%endif
|
||||
%description
|
||||
Next-generation ES6 module bundler
|
||||
|
||||
%prep
|
||||
%autosetup -n package
|
||||
%autosetup -T -D -a 1 -n package
|
||||
%autosetup -T -D -a 2 -n package
|
||||
sed -i '1s/env //' bin/rollup
|
||||
|
||||
%build
|
||||
|
||||
%install
|
||||
mkdir -p %{buildroot}%{nodejs_sitelib}/%{packagename}
|
||||
cp -pr package.json bin/ dist/ \
|
||||
%{buildroot}%{nodejs_sitelib}/%{packagename}
|
||||
mkdir -p %{buildroot}%{nodejs_sitelib}/%{packagename}/bin
|
||||
install -p -D -m0755 bin/rollup %{buildroot}%{nodejs_sitelib}/%{packagename}/bin/rollup
|
||||
mkdir -p %{buildroot}%{_bindir}
|
||||
ln -sf %{nodejs_sitelib}/%{packagename}/bin/rollup \
|
||||
%{buildroot}%{_bindir}/%{packagename}
|
||||
%nodejs_symlink_deps
|
||||
|
||||
%check
|
||||
%nodejs_symlink_deps --check
|
||||
%{__nodejs} -e 'require("./")'
|
||||
%if 0%{?enable_tests}
|
||||
NODE_ENV=test %{_bindir}/mocha -R spec
|
||||
%else
|
||||
%{_bindir}/echo -e "\e[101m -=#=- Tests disabled -=#=- \e[0m"
|
||||
%endif
|
||||
|
||||
%files
|
||||
%{!?_licensedir:%global license %doc}
|
||||
%doc CHANGELOG.md README.md
|
||||
%license LICENSE.md
|
||||
%{nodejs_sitelib}/%{packagename}
|
||||
%{_bindir}/%{packagename}
|
||||
|
||||
%changelog
|
||||
* Thu Aug 20 2020 wangyue <wangyue92@huawei.com> - 0.41.6-1
|
||||
- package init
|
||||
5
nodejs-rollup.yaml
Normal file
5
nodejs-rollup.yaml
Normal file
@ -0,0 +1,5 @@
|
||||
git_url: https://github.com/rollup/rollup
|
||||
version_control: github
|
||||
src_repo: rollup/rollup
|
||||
tag_prefix: "^v"
|
||||
seperator: "."
|
||||
BIN
rollup-0.41.6.tgz
Normal file
BIN
rollup-0.41.6.tgz
Normal file
Binary file not shown.
BIN
src-0.41.6.tar.bz2
Normal file
BIN
src-0.41.6.tar.bz2
Normal file
Binary file not shown.
BIN
tests-0.41.6.tar.bz2
Normal file
BIN
tests-0.41.6.tar.bz2
Normal file
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user