Blame SPECS/nodejs-url-parse-lax.spec

0329f7
%{?scl:%scl_package nodejs-%{module_name}}
0329f7
%{!?scl:%global pkg_name %{name}}
0329f7
%{?nodejs_find_provides_and_requires}
0329f7
0329f7
# xo and ava not in fedora yet
0329f7
%global enable_tests 0
0329f7
%global module_name url-parse-lax
0329f7
0329f7
Name:           %{?scl_prefix}nodejs-%{module_name}
0329f7
Version:        1.0.0
0329f7
Release:        5%{?dist}
0329f7
Summary:        The url.parse() with support for protocol-less URLs & IPs
0329f7
0329f7
License:        MIT
0329f7
URL:            https://github.com/sindresorhus/url-parse-lax
0329f7
Source0:        https://github.com/sindresorhus/%{module_name}/archive/%{version}.tar.gz
0329f7
BuildArch:      noarch
0329f7
ExclusiveArch:  %{nodejs_arches} noarch
0329f7
0329f7
BuildRequires:  %{?scl_prefix}nodejs-devel
0329f7
0329f7
%if 0%{?enable_tests}
0329f7
BuildRequires: %{?scl_prefix}npm(ava)
0329f7
BuildRequires: %{?scl_prefix}npm(xo)
0329f7
%endif
0329f7
0329f7
%description
0329f7
The url.parse() with support for protocol-less URLs & IPs.
0329f7
0329f7
%prep
0329f7
%setup -q -n %{module_name}-%{version}
0329f7
rm -rf node_modules
0329f7
0329f7
%build
0329f7
# nothing to build
0329f7
0329f7
%install
0329f7
mkdir -p %{buildroot}%{nodejs_sitelib}/%{module_name}
0329f7
cp -pr package.json *.js %{buildroot}%{nodejs_sitelib}/%{module_name}
0329f7
%nodejs_symlink_deps
0329f7
0329f7
%if 0%{?enable_tests}
0329f7
0329f7
%check
0329f7
%nodejs_symlink_deps --check
0329f7
xo && ava
0329f7
%endif
0329f7
0329f7
%files
0329f7
%{!?_licensedir:%global license %doc}
0329f7
%doc readme.md
0329f7
%license license
0329f7
%{nodejs_sitelib}/%{module_name}
0329f7
0329f7
%changelog
0329f7
* Tue Feb 16 2016 Zuzana Svetlikova <zsvetlik@redhat.com> - 1.0.0-5
0329f7
- Use macro in -runtime dependency
0329f7
0329f7
* Sun Feb 14 2016 Zuzana Svetlikova <zsvetlik@redhat.com> - 1.0.0-4
0329f7
- Rebuilt with updated metapackage
0329f7
0329f7
* Tue Jan 12 2016 Tomas Hrcka <thrcka@redhat.com> - 1.0.0-3
0329f7
- Use macro to find provides and requires
0329f7
0329f7
* Tue Jan 12 2016 Tomas Hrcka <thrcka@redhat.com> - 1.0.0-2
0329f7
- Enable scl macros, fix license macro for el6
0329f7
0329f7
* Sun Nov 29 2015 Parag Nemade <pnemade AT redhat DOT com> - 1.0.0-1
0329f7
- Initial packaging