diff --git a/nodejs-resumer-concat-stream.patch b/nodejs-resumer-concat-stream.patch new file mode 100644 index 0000000..db4b7fe --- /dev/null +++ b/nodejs-resumer-concat-stream.patch @@ -0,0 +1,54 @@ +commit 161d30df8da2339418e1ee5ef1d9ad502ed5dcbb +Author: Tom Hughes +Date: Thu Jul 24 19:28:39 2014 +0100 + + Update to a more recent version of concat-stream + +diff --git a/package.json b/package.json +index 22c84b6..9445f20 100644 +--- a/package.json ++++ b/package.json +@@ -9,7 +9,7 @@ + "devDependencies": { + "tap": "~0.4.0", + "tape": "~1.0.2", +- "concat-stream": "~0.1.1" ++ "concat-stream": "~1.4.4" + }, + "scripts": { + "test": "tap test/*.js" +diff --git a/test/resume.js b/test/resume.js +index 1eaecac..c36a602 100644 +--- a/test/resume.js ++++ b/test/resume.js +@@ -6,7 +6,7 @@ test('implicit resume', function (t) { + t.plan(1); + + var s = createStream(); +- s.pipe(concat(function (err, body) { ++ s.pipe(concat(function (body) { + t.equal(body, 'beep boop\n'); + })); + }); +@@ -23,7 +23,7 @@ test('pause/resume', function (t) { + s.resume(); + }, 100); + +- s.pipe(concat(function (err, body) { ++ s.pipe(concat(function (body) { + t.equal(paused, false); + t.equal(body, 'beep boop\n'); + })); +diff --git a/test/through.js b/test/through.js +index ddcaf48..f9981fa 100644 +--- a/test/through.js ++++ b/test/through.js +@@ -11,7 +11,7 @@ test('through write/end', function (t) { + t.ok(true); + }); + +- s.pipe(concat(function (err, body) { ++ s.pipe(concat(function (body) { + t.equal(body, 'BEGIN\nRAWR\nEND\n'); + })); + diff --git a/nodejs-resumer.spec b/nodejs-resumer.spec new file mode 100644 index 0000000..7848671 --- /dev/null +++ b/nodejs-resumer.spec @@ -0,0 +1,39 @@ +Name: nodejs-resumer +Version: 0.0.0 +Release: 1 +Summary: A stream that starts paused and resumes on the next tick +License: MIT +URL: https://github.com/substack/resumer +Source0: http://registry.npmjs.org/resumer/-/resumer-%{version}.tgz +# https://github.com/substack/resumer/pull/2 +Patch0: nodejs-resumer-concat-stream.patch +BuildArch: noarch +ExclusiveArch: %{nodejs_arches} noarch +BuildRequires: nodejs-packaging +BuildRequires: npm(tap) npm(tape) npm(concat-stream) npm(through) +%description +A through stream that starts paused and resumes on the next tick. + +%prep +%setup -q -n package +%patch0 -p1 +rm -rf node_modules + +%build + +%install +mkdir -p %{buildroot}%{nodejs_sitelib}/resumer +cp -pr package.json index.js %{buildroot}%{nodejs_sitelib}/resumer +%nodejs_symlink_deps + +%check +%nodejs_symlink_deps --check +%tap test/*.js + +%files +%doc LICENSE readme.markdown example +%{nodejs_sitelib}/resumer + +%changelog +* Thu Aug 20 2020 wangyue - 0.0.0-1 +- package init diff --git a/nodejs-resumer.yaml b/nodejs-resumer.yaml new file mode 100644 index 0000000..6f6352e --- /dev/null +++ b/nodejs-resumer.yaml @@ -0,0 +1,5 @@ +git_url: https://github.com/substack/resumer +version_control: github +src_repo: substack/resumer +tag_prefix: "^" +seperator: "." diff --git a/resumer-0.0.0.tgz b/resumer-0.0.0.tgz new file mode 100644 index 0000000..f2e61c2 Binary files /dev/null and b/resumer-0.0.0.tgz differ