diff --git a/nodejs-unpipe.spec b/nodejs-unpipe.spec new file mode 100644 index 0000000..f8ffe8a --- /dev/null +++ b/nodejs-unpipe.spec @@ -0,0 +1,52 @@ +%{?nodejs_find_provides_and_requires} +%global packagename unpipe +%global enable_tests 1 +Name: nodejs-unpipe +Version: 1.0.0 +Release: 1 +Summary: Unpipe a stream from all destinations +License: MIT +URL: https://github.com/stream-utils/unpipe +Source0: https://registry.npmjs.org/unpipe/-/unpipe-%{version}.tgz +#git clone https://github.com/stream-utils/unpipe +#cd unpipe +#git archive --prefix='test/' --format=tar ${gittag}:test/ \ +# | bzip2 > "$pwd"/tests-${tag}.tar.bz2 +Source1: tests-%{version}.tar.bz2 +ExclusiveArch: %{nodejs_arches} noarch +BuildArch: noarch +BuildRequires: nodejs-packaging +%if 0%{?enable_tests} +BuildRequires: mocha npm(readable-stream) +%endif +Requires: nodejs +%description +Unpipe a stream from all destinations + +%prep +%setup -q -n package +%setup -q -T -D -a 1 -n package + +%build + +%install +mkdir -p %{buildroot}%{nodejs_sitelib}/%{packagename} +cp -pr package.json *.js \ + %{buildroot}%{nodejs_sitelib}/%{packagename} +%nodejs_symlink_deps +%if 0%{?enable_tests} + +%check +%nodejs_symlink_deps --check +/usr/bin/mocha -R spec +%endif + +%files +%{!?_licensedir:%global license %doc} +%doc *.md +%license LICENSE +%{nodejs_sitelib}/%{packagename} + +%changelog +* Wed Aug 12 2020 zhanghua - 1.0.0-1 +- package init diff --git a/nodejs-unpipe.yaml b/nodejs-unpipe.yaml new file mode 100644 index 0000000..b0eb456 --- /dev/null +++ b/nodejs-unpipe.yaml @@ -0,0 +1,4 @@ +version_control: github +src_repo: stream-utils/unpipe +tag_pattern: "^v" +seperator: "." diff --git a/tests-1.0.0.tar.bz2 b/tests-1.0.0.tar.bz2 new file mode 100644 index 0000000..4bd44d8 Binary files /dev/null and b/tests-1.0.0.tar.bz2 differ diff --git a/unpipe-1.0.0.tgz b/unpipe-1.0.0.tgz new file mode 100644 index 0000000..ac60140 Binary files /dev/null and b/unpipe-1.0.0.tgz differ