diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..ccdf43c --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ +SOURCES/es6-promise-3.0.2.tgz +SOURCES/tests-3.0.2.tar.bz2 diff --git a/.rh-nodejs4-nodejs-es6-promise.metadata b/.rh-nodejs4-nodejs-es6-promise.metadata new file mode 100644 index 0000000..98e92e6 --- /dev/null +++ b/.rh-nodejs4-nodejs-es6-promise.metadata @@ -0,0 +1,2 @@ +010d5858423a5f118979665f46486a95c6ee2bb6 SOURCES/es6-promise-3.0.2.tgz +7b8f8ac7e4f238c8db9fa85de244285285e3fc37 SOURCES/tests-3.0.2.tar.bz2 diff --git a/README.md b/README.md deleted file mode 100644 index 98f42b4..0000000 --- a/README.md +++ /dev/null @@ -1,4 +0,0 @@ -The master branch has no content - -Look at the c7 branch if you are working with CentOS-7, or the c4/c5/c6 branch for CentOS-4, 5 or 6 -If you find this file in a distro specific branch, it means that no content has been checked in yet diff --git a/SOURCES/dl-tests.es6-promise.sh b/SOURCES/dl-tests.es6-promise.sh new file mode 100644 index 0000000..181377a --- /dev/null +++ b/SOURCES/dl-tests.es6-promise.sh @@ -0,0 +1,23 @@ +#!/bin/bash + +tag=3.0.2 + +set -e + +tmp=$(mktemp -d) + +trap cleanup EXIT +cleanup() { + set +e + [ -z "$tmp" -o ! -d "$tmp" ] || rm -rf "$tmp" +} + +unset CDPATH +pwd=$(pwd) + +pushd "$tmp" +git clone git@github.com:jakearchibald/es6-promise.git +cd es6-promise +git archive --prefix="test/" --format=tar tags/v${tag}:test/ \ + | bzip2 > "$pwd"/tests-${tag}.tar.bz2 +popd diff --git a/SPECS/nodejs-es6-promise.spec b/SPECS/nodejs-es6-promise.spec new file mode 100644 index 0000000..d985cbd --- /dev/null +++ b/SPECS/nodejs-es6-promise.spec @@ -0,0 +1,81 @@ +%{?scl:%scl_package nodejs-%{npm_name}} +%{!?scl:%global pkg_name %{name}} + +%{?nodejs_find_provides_and_requires} + +%global npm_name es6-promise +# Tests disabled due to dependencies not in Fedora yet +# Tests also are not working even with dependencies +%global enable_tests 0 + + +Summary: Lightweight library that provides tools for organizing asynchronous code +Name: %{?scl_prefix}nodejs-%{npm_name} +Version: 3.0.2 +Release: 5%{?dist} +License: MIT +URL: https://github.com/jakearchibald/ES6-Promises +Source0: http://registry.npmjs.org/%{npm_name}/-/%{npm_name}-%{version}.tgz +# The test files are not included in the npm tarball. +# Source1 is generated by running Source10, which pulls from the upstream +# version control repository. +Source1: tests-%{version}.tar.bz2 +Source10: dl-tests.%{npm_name}.sh +BuildRequires: %{?scl_prefix}runtime +%if 0%{?enable_tests} +BuildRequires: %{?scl_prefix}nodejs(ember) +BuildRequires: %{?scl_prefix}nodejs(ember-cli) +%endif + +BuildArch: noarch +ExclusiveArch: %{nodejs_arches} noarch + +%description +A lightweight library that provides tools for organizing +asynchronous code + +This is a polyfill of the ES6 Promise. The implementation +is a subset of rsvp.js. + +%prep +%setup -q -n package +# setup the tests +%setup -q -T -D -a 1 -n package + +%build +#nothing to do + +%install +mkdir -p %{buildroot}%{nodejs_sitelib}/%{npm_name} +cp -pr dist lib package.json %{buildroot}%{nodejs_sitelib}/%{npm_name} + +%nodejs_symlink_deps + +%if 0%{?enable_tests} + +%check +%nodejs_symlink_deps --check +ember test +%endif + +%files +%{!?_licensedir:%global license %doc} +%doc CHANGELOG.md README.md +%license LICENSE +%{nodejs_sitelib}/%{npm_name} + +%changelog +* Tue Feb 16 2016 Zuzana Svetlikova - 3.0.2-5 +- Use macro in -runtime dependency + +* Sun Feb 14 2016 Zuzana Svetlikova - 3.0.2-4 +- Rebuilt with updated metapackage + +* Wed Jan 06 2016 Tomas Hrcka - 3.0.2-3 +- Enable scl macros + +* Tue Oct 20 2015 Troy Dawson - 3.0.2-2 +- Add tests, fixup spec file + +* Mon Sep 21 2015 Troy Dawson - 3.0.2-1 +- Initial build \ No newline at end of file