Jared K. Smith 1dbb4e5
%{?nodejs_find_provides_and_requires}
Jared K. Smith 1dbb4e5
Jared K. Smith 1dbb4e5
%global packagename is-number
Jared K. Smith 1dbb4e5
%global enable_tests 1
Jared K. Smith 1dbb4e5
Jared K. Smith 1dbb4e5
Name:		nodejs-is-number
Jared K. Smith 1dbb4e5
Version:	2.1.0
4eb8e3e
Release:	8%{?dist}
Jared K. Smith 1dbb4e5
Summary:	Returns true if the value is a number
Jared K. Smith 1dbb4e5
Jared K. Smith 1dbb4e5
License:	MIT
Jared K. Smith 1dbb4e5
URL:		https://github.com/jonschlinkert/is-number.git
Jared K. Smith 1dbb4e5
Source0:	https://registry.npmjs.org/%{packagename}/-/%{packagename}-%{version}.tgz
Jared K. Smith 1dbb4e5
# The test files are not included in the npm tarball.
Jared K. Smith 1dbb4e5
# The 2.1.0 release is not tagged in github, so pull the test from master for now
Jared K. Smith 1dbb4e5
Source1:	https://raw.githubusercontent.com/jonschlinkert/is-number/master/test.js
Jared K. Smith 1dbb4e5
Jared K. Smith 1dbb4e5
Jared K. Smith 1dbb4e5
BuildArch:	noarch
Jared K. Smith 1dbb4e5
%if 0%{?fedora} >= 19
Jared K. Smith 1dbb4e5
ExclusiveArch: %{nodejs_arches} noarch
Jared K. Smith 1dbb4e5
%else
Jared K. Smith 1dbb4e5
ExclusiveArch: %{ix86} x86_64 %{arm} noarch
Jared K. Smith 1dbb4e5
%endif
Jared K. Smith 1dbb4e5
Jared K. Smith 1dbb4e5
BuildRequires:	nodejs-packaging
Jared K. Smith 1dbb4e5
%if 0%{?enable_tests}
Jared K. Smith 1dbb4e5
BuildRequires:	mocha
Jared K. Smith 1dbb4e5
BuildRequires:	npm(kind-of)
Jared K. Smith 1dbb4e5
%endif
Jared K. Smith 1dbb4e5
Jared K. Smith 1dbb4e5
%description
Jared K. Smith 1dbb4e5
Returns true if the value is a number. comprehensive tests.
Jared K. Smith 1dbb4e5
Jared K. Smith 1dbb4e5
Jared K. Smith 1dbb4e5
%prep
Jared K. Smith 1dbb4e5
%setup -q -n package
Jared K. Smith 1dbb4e5
# setup the tests
Jared K. Smith 1dbb4e5
cp -p %{SOURCE1} .
Jared K. Smith 1dbb4e5
Jared K. Smith 1dbb4e5
Jared K. Smith 1dbb4e5
%build
Jared K. Smith 1dbb4e5
# nothing to do!
Jared K. Smith 1dbb4e5
Jared K. Smith 1dbb4e5
%install
Jared K. Smith 1dbb4e5
mkdir -p %{buildroot}%{nodejs_sitelib}/%{packagename}
Jared K. Smith 1dbb4e5
cp -pr package.json index.js \
Jared K. Smith 1dbb4e5
	%{buildroot}%{nodejs_sitelib}/%{packagename}
Jared K. Smith 1dbb4e5
Jared K. Smith 1dbb4e5
%nodejs_symlink_deps
Jared K. Smith 1dbb4e5
Jared K. Smith 1dbb4e5
%check
Jared K. Smith 1dbb4e5
%nodejs_symlink_deps --check
Jared K. Smith 1dbb4e5
%{__nodejs} -e 'require("./")'
Jared K. Smith 1dbb4e5
%if 0%{?enable_tests}
Jared K. Smith 1dbb4e5
%{_bindir}/mocha -R spec
Jared K. Smith 1dbb4e5
%else
Jared K. Smith 1dbb4e5
%{_bindir}/echo "Tests disabled..."
Jared K. Smith 1dbb4e5
%endif
Jared K. Smith 1dbb4e5
Jared K. Smith 1dbb4e5
Jared K. Smith 1dbb4e5
%files
Jared K. Smith 1dbb4e5
%{!?_licensedir:%global license %doc}
Jared K. Smith 1dbb4e5
%doc *.md
Jared K. Smith 1dbb4e5
%license LICENSE
Jared K. Smith 1dbb4e5
%{nodejs_sitelib}/%{packagename}
Jared K. Smith 1dbb4e5
Jared K. Smith 1dbb4e5
Jared K. Smith 1dbb4e5
%changelog
4eb8e3e
* Wed Jan 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 2.1.0-8
4eb8e3e
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
4eb8e3e
8338a56
* Thu Jul 25 2019 Fedora Release Engineering <releng@fedoraproject.org> - 2.1.0-7
8338a56
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
8338a56
46ba354
* Fri Feb 01 2019 Fedora Release Engineering <releng@fedoraproject.org> - 2.1.0-6
46ba354
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
46ba354
64a701e
* Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org> - 2.1.0-5
64a701e
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
64a701e
d36bcf5
* Thu Feb 08 2018 Fedora Release Engineering <releng@fedoraproject.org> - 2.1.0-4
d36bcf5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
d36bcf5
072447a
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 2.1.0-3
072447a
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
072447a
0dfe8c5
* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 2.1.0-2
0dfe8c5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
0dfe8c5
Jared K. Smith 1dbb4e5
* Thu Feb  4 2016 Jared Smith <jsmith@fedoraproject.org> - 2.1.0-1
Jared K. Smith 1dbb4e5
- Initial packaging