f49691c
%{?nodejs_find_provides_and_requires}
f49691c
f49691c
%global enable_tests 1
f49691c
f49691c
Name:       nodejs-readdirp
be8e41e
Version:    0.4.0
0d819ed
Release:    3%{?dist}
f49691c
Summary:    Recursive version of Node's fs.readdir with a streaming API
f49691c
License:    MIT
f49691c
Group:      System Environment/Libraries
f49691c
URL:        https://github.com/thlorenz/readdirp
f49691c
Source0:    http://registry.npmjs.org/readdirp/-/readdirp-%{version}.tgz
f49691c
# The test files are not included in the npm tarball.
f49691c
# Source1 is generated by running Source10, which pulls from the upstream
f49691c
# version control repository.
f49691c
Source1:    tests-v%{version}.tar.bz2
f49691c
Source10:   dl-tests.sh
f49691c
f49691c
BuildArch:  noarch
f49691c
%if 0%{?fedora} >= 19
f49691c
ExclusiveArch: %{nodejs_arches} noarch
f49691c
%else
f49691c
ExclusiveArch: %{ix86} x86_64 %{arm} noarch
f49691c
%endif
f49691c
f49691c
BuildRequires:  nodejs-packaging
f49691c
f49691c
%if 0%{?enable_tests}
f49691c
BuildRequires:  npm(graceful-fs)
f49691c
BuildRequires:  npm(minimatch)
f49691c
BuildRequires:  npm(tap)
f49691c
BuildRequires:  npm(through)
f49691c
%endif
f49691c
f49691c
%description
f49691c
%{summary}.
f49691c
f49691c
f49691c
%prep
f49691c
%setup -q -n package
f49691c
# The NPM tarball is missing some files within test/
f49691c
rm -rf test/
f49691c
%setup -q -T -D -a 1 -n package
f49691c
# Remove executable bit.
f49691c
find . -type f -exec chmod -x '{}' \;
f49691c
f49691c
f49691c
%build
f49691c
#nothing to do
f49691c
f49691c
f49691c
%install
f49691c
mkdir -p %{buildroot}%{nodejs_sitelib}/readdirp
f49691c
cp -pr package.json readdirp.js stream-api.js \
f49691c
    %{buildroot}%{nodejs_sitelib}/readdirp
f49691c
f49691c
%nodejs_symlink_deps
f49691c
f49691c
f49691c
%if 0%{?enable_tests}
f49691c
%check
f49691c
%nodejs_symlink_deps --check
f49691c
%__tap test/*.js
f49691c
%endif
f49691c
f49691c
f49691c
%files
f49691c
%doc LICENSE README.md examples/
f49691c
%{nodejs_sitelib}/readdirp
f49691c
f49691c
f49691c
%changelog
0d819ed
* Wed Jun 17 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.4.0-3
0d819ed
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
0d819ed
94a7cf5
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.4.0-2
94a7cf5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
94a7cf5
be8e41e
* Sat Apr 26 2014 Jamie Nguyen <jamielinux@fedoraproject.org> - 0.4.0-1
be8e41e
- update to upstream release 0.4.0
be8e41e
f49691c
* Sun Mar 02 2014 Jamie Nguyen <jamielinux@fedoraproject.org> - 0.3.3-1
f49691c
- initial package