b15192f
%global npm_name node-static
b15192f
%global enable_tests 0
b15192f
aeb9083
%{?nodejs_find_provides_and_requires}
aeb9083
b15192f
Summary:       Simple, compliant file streaming module for node
b15192f
Name:          nodejs-%{npm_name}
aeb9083
Version:       0.7.3
9920fbd
Release:       2%{?dist}
b15192f
Group:         Development/Languages
b15192f
License:       MIT
b15192f
URL:           http://github.com/cloudhead/node-static
b15192f
Source0:       http://registry.npmjs.org/%{npm_name}/-/%{npm_name}-%{version}.tgz
b15192f
BuildRequires: nodejs-devel
b15192f
%if 0%{?enable_tests}
b15192f
BuildRequires:  npm(vows)
b15192f
%endif
b15192f
BuildArch:     noarch
aeb9083
ExclusiveArch: %{ix86} x86_64 %{arm} noarch
b15192f
b15192f
%description
b15192f
node-static is a simple, "rfc 2616 compliant" file streaming module 
b15192f
for node.
b15192f
b15192f
node-static has an in-memory file cache, making it highly efficient.
b15192f
node-static understands and supports "conditional GET" and "HEAD" requests.
b15192f
node-static was inspired by some of the other static-file serving modules
b15192f
out there, such as node-paperboy and antinode.
b15192f
b15192f
%prep
b15192f
%setup -q -n package
b15192f
b15192f
%build
b15192f
#nothing to do
b15192f
b15192f
%install
b15192f
mkdir -p %{buildroot}%{nodejs_sitelib}/%{npm_name}
aeb9083
cp -pr benchmark bin examples lib package.json test %{buildroot}%{nodejs_sitelib}/%{npm_name}
b15192f
b15192f
# Setup Binaries
b15192f
mkdir %{buildroot}%{_bindir}
b15192f
ln -s %{nodejs_sitelib}/%{npm_name}/bin/cli.js %{buildroot}%{_bindir}/static
b15192f
b15192f
%if 0%{?enable_tests}
b15192f
%check
b15192f
vows --spec --isolate
b15192f
%endif
b15192f
b15192f
%files
b15192f
%doc LICENSE README.md
b15192f
%{nodejs_sitelib}/%{npm_name}
b15192f
%{_bindir}/static
b15192f
b15192f
%changelog
9920fbd
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.7.3-2
9920fbd
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
9920fbd
aeb9083
* Thu Feb 06 2014 Troy Dawson <tdawson@redhat.com> - 0.7.3-1
aeb9083
- Update to version 0.7.3
aeb9083
- add nodejs exclusive arch
aeb9083
- add macro to invoke dependency generator on EL6
aeb9083
b15192f
* Fri Oct 11 2013 Troy Dawson <tdawson@redhat.com> - 0.7.1-2
b15192f
- Cleaned up description
b15192f
b15192f
* Tue Oct 08 2013 Troy Dawson <tdawson@redhat.com> - 0.7.1-1
b15192f
- Updated to 0.7.1
b15192f
b15192f
* Thu Feb 16 2012 Troy Dawson <tdawson@redhat.com> - 0.6.9-1
b15192f
- Initial build
b15192f