From af60b64f010f6f85e6f35466b5c9b91fa288ccfe Mon Sep 17 00:00:00 2001 From: Tom Hughes Date: Dec 31 2015 10:30:17 +0000 Subject: Update to 4.1.2 upstream release and enable tests --- diff --git a/.gitignore b/.gitignore index 60c7b97..620c36b 100644 --- a/.gitignore +++ b/.gitignore @@ -2,3 +2,4 @@ /graceful-fs-1.2.0.tgz /graceful-fs-1.2.1.tgz /graceful-fs-1.2.2.tgz +/nodejs-graceful-fs-4.1.2.tar.gz diff --git a/nodejs-graceful-fs.spec b/nodejs-graceful-fs.spec index c318427..2b64d46 100644 --- a/nodejs-graceful-fs.spec +++ b/nodejs-graceful-fs.spec @@ -1,48 +1,75 @@ %{?nodejs_find_provides_and_requires} -Name: nodejs-graceful-fs -Version: 2.0.0 -Release: 5%{?dist} -Summary: 'fs' module with incremental back-off on EMFILE -License: BSD -Group: Development/Libraries -URL: https://github.com/isaacs/node-graceful-fs -Source0: http://registry.npmjs.org/graceful-fs/-/graceful-fs-%{version}.tgz -BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) -BuildArch: noarch -ExclusiveArch: %{nodejs_arches} noarch - -BuildRequires: nodejs-devel +Name: nodejs-graceful-fs +Version: 4.1.2 +Release: 1%{?dist} +Summary: A drop-in replacement for fs, making various improvements +License: BSD +Group: Development/Libraries +URL: https://github.com/isaacs/node-graceful-fs +Source0: https://github.com/isaacs/node-graceful-fs/archive/v%{version}/%{name}-%{version}.tar.gz +BuildArch: noarch +ExclusiveArch: %{nodejs_arches} noarch + +BuildRequires: nodejs-packaging + +BuildRequires: npm(tap) +BuildRequires: npm(rimraf) %description -Just like node.js' fs module, but it does an incremental back-off when EMFILE is -encountered. Useful in asynchronous situations where one needs to try to open -lots and lots of files. +A drop-in replacement for fs, making various improvements. + +The improvements are meant to normalize behavior across different +platforms and environments, and to make filesystem access more +resilient to errors. + +Improvements over fs module + +* Queues up open and readdir calls, and retries them once something + closes if there is an EMFILE error from too many file descriptors. +* Fixes lchmod for Node versions prior to 0.6.2. +* Implements fs.lutimes if possible. Otherwise it becomes a noop. +* Ignores EINVAL and EPERM errors in chown, fchown or lchown if the + user isn't root. +* Makes lchmod and lchown become noops, if not available. +* Retries reading a file if read results in EAGAIN error. + +On Windows, it retries renaming a file for up to one second if EACCESS +or EPERM error occurs, likely because antivirus software has locked the +directory. + %prep -%setup -q -n package +%autosetup -n node-graceful-fs-%{version} + %build #nothing to do -%install -rm -rf %{buildroot} +%install mkdir -p %{buildroot}%{nodejs_sitelib}/graceful-fs -cp -p graceful-fs.js package.json polyfills.js \ +cp -p package.json graceful-fs.js fs.js polyfills.js legacy-streams.js \ %{buildroot}%{nodejs_sitelib}/graceful-fs - %nodejs_symlink_deps -%clean -rm -rf %{buildroot} + +%check +%nodejs_symlink_deps --check +%{nodejs_sitelib}/tap/bin/tap.js test/*.js + %files -%defattr(-,root,root,-) +%doc README.md +%license LICENSE %{nodejs_sitelib}/graceful-fs -%doc README.md LICENSE + %changelog +* Thu Dec 31 2015 Tom Hughes - 4.1.2-1 +- Update to 4.1.2 upstream release +- Enable tests + * Wed Jun 17 2015 Fedora Release Engineering - 2.0.0-5 - Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild diff --git a/sources b/sources index 6f9cddf..db66686 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -025456d563ee91984ab5fe813c152d56 graceful-fs-2.0.0.tgz +908318e75de9110348aa6dbc61681e33 nodejs-graceful-fs-4.1.2.tar.gz