diff --git a/nodejs-wordwrap.spec b/nodejs-wordwrap.spec new file mode 100644 index 0000000..f678d7f --- /dev/null +++ b/nodejs-wordwrap.spec @@ -0,0 +1,45 @@ +%{?nodejs_find_provides_and_requires} +%global enable_tests 1 +Name: nodejs-wordwrap +Version: 1.0.0 +Release: 1 +Summary: Word wrapping library for node +License: MIT +URL: https://github.com/substack/node-wordwrap +Source0: https://registry.npmjs.org/wordwrap/-/wordwrap-%{version}.tgz +BuildArch: noarch +ExclusiveArch: %{nodejs_arches} noarch +BuildRequires: nodejs-packaging +%if 0%{?enable_tests} +BuildRequires: npm(tape) +%endif +%description +Wrap those words. Show them at what columns to start and stop. + +%prep +%setup -q -n package + +%build + +%install +mkdir -p %{buildroot}%{nodejs_sitelib}/wordwrap +cp -pr package.json index.js %{buildroot}%{nodejs_sitelib}/wordwrap +%nodejs_symlink_deps + +%check +%nodejs_symlink_deps --check +%{__nodejs} -e 'require("./")' +%if 0%{?enable_tests} +ln -sf .. node_modules/wordwrap +%{_bindir}/tape test/*.js +%endif + +%files +%{!?_licensedir:%global license %doc} +%doc README.markdown example +%license LICENSE +%{nodejs_sitelib}/wordwrap + +%changelog +* Thu Aug 20 2020 zhanghua - 1.0.0-1 +- Package init diff --git a/nodejs-wordwrap.yaml b/nodejs-wordwrap.yaml new file mode 100644 index 0000000..b7b2dca --- /dev/null +++ b/nodejs-wordwrap.yaml @@ -0,0 +1,4 @@ +version_control: github +src_repo: substack/node-wordwrap +tag_pattern: "^wordwrap-" +seperator: "." diff --git a/wordwrap-1.0.0.tgz b/wordwrap-1.0.0.tgz new file mode 100644 index 0000000..2c19afc Binary files /dev/null and b/wordwrap-1.0.0.tgz differ