diff --git a/istanbul-0.4.5.tgz b/istanbul-0.4.5.tgz new file mode 100644 index 0000000..0618fd5 Binary files /dev/null and b/istanbul-0.4.5.tgz differ diff --git a/nodejs-istanbul.spec b/nodejs-istanbul.spec new file mode 100644 index 0000000..4be3421 --- /dev/null +++ b/nodejs-istanbul.spec @@ -0,0 +1,67 @@ +%{?nodejs_find_provides_and_requires} +%global enable_tests 1 +%global srcname istanbul +Name: nodejs-%{srcname} +Version: 0.4.5 +Release: 1 +Summary: A JS code coverage tool written in JS +License: BSD +URL: https://github.com/gotwarlost/istanbul +Source0: https://registry.npmjs.org/%{srcname}/-/%{srcname}-%{version}.tgz +#git clone https://github.com/gotwarlost/istanbul +#cd istanbul +#git archive --prefix='test/' --format=tar ${gittag}:test/ \ +# | bzip2 > "$pwd"/tests-${tag}.tar.bz2 +Source1: tests-%{version}.tar.bz2 +BuildArch: noarch +ExclusiveArch: %{nodejs_arches} noarch +BuildRequires: nodejs-packaging +%if 0%{?enable_tests} +BuildRequires: npm(escodegen) npm(fileset) npm(handlebars) npm(js-yaml) npm(nodeunit) +BuildRequires: npm(once) npm(resolve) npm(requirejs) npm(rimraf) npm(supports-color) +BuildRequires: npm(which) +%endif +%description +%{summary}. + +%prep +%setup -q -n package +%setup -q -T -D -a 1 -n package +%nodejs_fixdep async +%nodejs_fixdep escodegen +%nodejs_fixdep esprima +%nodejs_fixdep fileset +%nodejs_fixdep glob +%nodejs_fixdep handlebars +%nodejs_fixdep js-yaml +%nodejs_fixdep mkdirp +%nodejs_fixdep nopt +%nodejs_fixdep resolve +%nodejs_fixdep supports-color +%nodejs_fixdep which +%nodejs_fixdep wordwrap + +%build + +%install +mkdir -p %{buildroot}%{nodejs_sitelib}/%{srcname} +cp -pr package.json index.js lib/ %{buildroot}%{nodejs_sitelib}/%{srcname} +mkdir -p %{buildroot}%{_bindir} +ln -s %{nodejs_sitelib}/%{srcname}/lib/cli.js %{buildroot}%{_bindir}/istanbul-js +%nodejs_symlink_deps +%if 0%{?enable_tests} + +%check +%nodejs_symlink_deps --check +test/run.js +%endif + +%files +%doc README.md CHANGELOG.md +%license LICENSE +%{nodejs_sitelib}/%{srcname} +%{_bindir}/istanbul-js + +%changelog +* Thu Aug 20 2020 wangxiao - 0.4.5-1 +- Package init diff --git a/nodejs-istanbul.yaml b/nodejs-istanbul.yaml new file mode 100644 index 0000000..9e58aa4 --- /dev/null +++ b/nodejs-istanbul.yaml @@ -0,0 +1,5 @@ +git_url: https://github.com/gotwarlost/istanbul +version_control: github +src_repo: gotwarlost/istanbul +tag_prefix: "^v" +seperator: "." diff --git a/tests-0.4.5.tar.bz2 b/tests-0.4.5.tar.bz2 new file mode 100644 index 0000000..7d7599b Binary files /dev/null and b/tests-0.4.5.tar.bz2 differ