Blame SPECS/nodejs-ms.spec

f7600c
%{?scl:%scl_package nodejs-ms}
f7600c
%{!?scl:%global pkg_name %{name}}
f7600c
f7600c
%{?nodejs_find_provides_and_requires}
f7600c
f7600c
%global enable_tests 0
f7600c
f7600c
Name:       %{?scl_prefix}nodejs-ms
f7600c
Version:    0.7.1
37a097
Release:    5%{?dist}
f7600c
Summary:    Tiny milliseconds conversion utility for Node.js
f7600c
License:    MIT
f7600c
URL:        https://github.com/guille/ms.js/
f7600c
Source0:    http://registry.npmjs.org/ms/-/ms-%{version}.tgz
f7600c
# The tests are not included in the npm tarball.
f7600c
# Source1 is generated by running Source10, which pulls from the upstream
f7600c
# version control repository.
f7600c
Source1:    tests-%{version}.tar.bz2
f7600c
Source10:   dl-tests.ms.sh
f7600c
f7600c
BuildArch:  noarch
f7600c
%if 0%{?fedora} >= 19
f7600c
ExclusiveArch: %{nodejs_arches} noarch
f7600c
%else
37a097
ExclusiveArch: %{nodejs_arches} noarch
f7600c
%endif
f7600c
f7600c
BuildRequires:  %{?scl_prefix}nodejs-devel
f7600c
f7600c
%if 0%{?enable_tests}
f7600c
BuildRequires:  %{?scl_prefix}npm(expect.js)
f7600c
BuildRequires:  %{?scl_prefix}npm(mocha)
f7600c
%endif
f7600c
f7600c
%description
f7600c
This module is a tiny milliseconds conversion utility for Node.js.
f7600c
f7600c
It does the following:
f7600c
 - If a number is supplied to ms, a string with a unit is returned.
f7600c
 - If a string that contains the number is supplied, it returns it as a
f7600c
   number (e.g: it returns 100 for '100').
f7600c
 - If you pass a string with a number and a valid unit, the number of
f7600c
   equivalent milliseconds is returned.
f7600c
f7600c
%prep
f7600c
%setup -q -n package
f7600c
%setup -q -T -D -a 1 -n package
f7600c
f7600c
%build
f7600c
#nothing to do
f7600c
f7600c
%install
f7600c
mkdir -p %{buildroot}%{nodejs_sitelib}/ms
f7600c
cp -pr package.json index.js \
f7600c
    %{buildroot}%{nodejs_sitelib}/ms
f7600c
f7600c
%nodejs_symlink_deps
f7600c
f7600c
f7600c
%if 0%{?enable_tests}
f7600c
f7600c
%check
f7600c
%nodejs_symlink_deps --check
f7600c
%{nodejs_sitelib}/mocha/bin/mocha test/test.js
f7600c
%endif
f7600c
f7600c
%files
f7600c
%doc History.md LICENSE README.md
f7600c
%{nodejs_sitelib}/ms
f7600c
f7600c
%changelog
37a097
* Mon May 28 2018 Zuzana Svetlikova <zsvetlik@redhat.com> - 0.7.1-5
37a097
- Resolves: RHBZ#1543198, rebuild for multiarch
37a097
f7600c
* Tue Feb 16 2016 Zuzana Svetlikova <zsvetlik@redhat.com> - 0.7.1-4
f7600c
- Use macro in -runtime dependency
f7600c
f7600c
* Sun Feb 14 2016 Zuzana Svetlikova <zsvetlik@redhat.com> - 0.7.1-3
f7600c
- Rebuilt with updated metapackage
f7600c
f7600c
* Tue Dec 01 2015 Tomas Hrcka <thrcka@redhat.com> - 0.7.1-2
f7600c
- Enable scl macros
f7600c
f7600c
* Thu Sep 10 2015 Troy Dawson <tdawson@redhat.com> - 0.7.1-1
f7600c
- Update to 0.7.1
f7600c
- Turn off tests until all dependencies are built
f7600c
f7600c
* Fri Apr 18 2014 Jamie Nguyen <jamielinux@fedoraproject.org> - 0.6.2-1
f7600c
- update to upstream release 0.6.2
f7600c
f7600c
* Sun Jul 28 2013 Jamie Nguyen <jamielinux@fedoraproject.org> - 0.6.1-2
f7600c
- restrict to compatible arches
f7600c
f7600c
* Sat May 25 2013 Jamie Nguyen <jamielinux@fedoraproject.org> - 0.6.1-1
f7600c
- update to upstream release 0.6.1
f7600c
f7600c
* Sat Mar 16 2013 Jamie Nguyen <jamielinux@fedoraproject.org> - 0.6.0-1
f7600c
- update to upstream release 0.6.0
f7600c
- History.md is now not included in the npm tarball
f7600c
- tests are now not included in the npm tarball, so download separately
f7600c
f7600c
* Fri Mar 15 2013 Jamie Nguyen <jamielinux@fedoraproject.org> - 0.5.1-1
f7600c
- update to upstream release 0.5.1
f7600c
f7600c
* Fri Feb 22 2013 Jamie Nguyen <jamielinux@fedoraproject.org> - 0.5.0-2
f7600c
- add a copy of the MIT license to comply with license requirements
f7600c
f7600c
* Thu Feb 14 2013 Jamie Nguyen <jamielinux@fedoraproject.org> - 0.5.0-1
f7600c
- initial package