%{?nodejs_find_provides_and_requires} %global enable_tests 1 Name: nodejs-defined Version: 1.0.0 Release: 2 Summary: Return the first argument that is '!== undefined' License: MIT URL: https://github.com/substack/defined Source0: http://registry.npmjs.org/defined/-/defined-%{version}.tgz BuildArch: noarch ExclusiveArch: %{nodejs_arches} noarch BuildRequires: nodejs-packaging %if 0%{?enable_tests} BuildRequires: npm(tap) npm(tape) %endif %description %{summary}. %prep %setup -q -n package %build %install mkdir -p %{buildroot}%{nodejs_sitelib}/defined cp -pr package.json index.js \ %{buildroot}%{nodejs_sitelib}/defined %nodejs_symlink_deps %if 0%{?enable_tests} %check ln -sf %{nodejs_sitelib} . %tap test/*.js %endif %files %{!?_licensedir:%global license %doc} %doc readme.markdown example/ %license LICENSE %{nodejs_sitelib}/defined %changelog * Thu Nov 26 2020 leiju - 1.0.0-2 - delete nodejs-defined.spec.old redundancy file * Tue Aug 18 2020 Anan Fu - 1.0.0-1 - package init