%{?nodejs_find_provides_and_requires} %global packagename only-shallow %global enable_tests 1 Name: nodejs-only-shallow Version: 1.2.0 Release: 4%{?dist} Summary: Like `deeper` and `deepest`, but less strict, and with 90s flavor License: ISC URL: https://github.com/othiym23/only-shallow.git Source0: https://registry.npmjs.org/%{packagename}/-/%{packagename}-%{version}.tgz Source1: LICENSE-ISC.txt # upstream license file requested at https://github.com/othiym23/only-shallow/issues/3 # In the meantime, I've added a license file with the text of the ISC license ExclusiveArch: %{nodejs_arches} noarch BuildArch: noarch BuildRequires: nodejs-packaging %if 0%{?enable_tests} BuildRequires: npm(buffertools) BuildRequires: npm(tap) %endif %description Like `deeper` and `deepest`, but less strict, and with 90s flavor %prep %setup -q -n package cp -p %{SOURCE1} . %build # nothing to do! %install mkdir -p %{buildroot}%{nodejs_sitelib}/%{packagename} cp -pr package.json *.js \ %{buildroot}%{nodejs_sitelib}/%{packagename} %nodejs_symlink_deps %check %nodejs_symlink_deps --check %{__nodejs} -e 'require("./")' %if 0%{?enable_tests} %{_bindir}/tap test/*.js %endif %files %{!?_licensedir:%global license %doc} %doc *.md %license LICENSE-ISC.txt %{nodejs_sitelib}/%{packagename} %changelog * Tue Jan 19 2016 Jared Smith - 1.2.0-4 - Fix license * Tue Jan 19 2016 Jared Smith - 1.2.0-3 - Fix build dependency on npm(buffertools) * Mon Oct 19 2015 Jared Smith - 1.2.0-2 - Initial packging