[nodejs-fs-extra] Initial import

Jamie Nguyen jamielinux at fedoraproject.org
Fri Apr 25 18:21:31 UTC 2014


commit d0dd6166fb5554121f9b34f29546cd58d0738e0c
Author: Jamie Nguyen <j at jamielinux.com>
Date:   Fri Apr 25 19:21:19 2014 +0100

    Initial import

 .gitignore           |    2 +
 dl-tests.sh          |   23 ++++++++++++++
 nodejs-fs-extra.spec |   81 ++++++++++++++++++++++++++++++++++++++++++++++++++
 sources              |    2 +
 4 files changed, 108 insertions(+), 0 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index e69de29..148ddc4 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1,2 @@
+/fs-extra-0.8.1.tgz
+/tests-v0.8.1.tar.bz2
diff --git a/dl-tests.sh b/dl-tests.sh
new file mode 100644
index 0000000..ea995e3
--- /dev/null
+++ b/dl-tests.sh
@@ -0,0 +1,23 @@
+#!/bin/bash
+
+tag=v0.8.1
+
+set -e
+
+tmp=$(mktemp -d)
+
+trap cleanup EXIT
+cleanup() {
+    set +e
+    [ -z "$tmp" -o ! -d "$tmp" ] || rm -rf "$tmp"
+}
+
+unset CDPATH
+pwd=/home/jamie/source/rpmbuild/SOURCES
+
+pushd "$tmp"
+git clone git://github.com/jprichardson/node-fs-extra.git
+cd node-fs-extra
+git archive --prefix="test/" --format=tar tags/${tag}:test/ \
+    | bzip2 > "$pwd"/tests-${tag}.tar.bz2
+popd
diff --git a/nodejs-fs-extra.spec b/nodejs-fs-extra.spec
new file mode 100644
index 0000000..d0eb69a
--- /dev/null
+++ b/nodejs-fs-extra.spec
@@ -0,0 +1,81 @@
+%{?nodejs_find_provides_and_requires}
+
+%global enable_tests 0
+
+Name:       nodejs-fs-extra
+Version:    0.8.1
+Release:    2%{?dist}
+Summary:    A drop-in replacement for Node's native fs module with a few extra methods
+License:    MIT
+Group:      System Environment/Libraries
+URL:        https://github.com/jprichardson/node-fs-extra
+Source0:    http://registry.npmjs.org/fs-extra/-/fs-extra-%{version}.tgz
+# Source1 is generated by running Source10, which pulls from the upstream
+# version control repository.
+Source1:    tests-v%{version}.tar.bz2
+Source10:   dl-tests.sh
+
+BuildArch:  noarch
+%if 0%{?fedora} >= 19
+ExclusiveArch: %{nodejs_arches} noarch
+%else
+ExclusiveArch: %{ix86} x86_64 %{arm} noarch
+%endif
+
+BuildRequires:  nodejs-packaging
+
+%if 0%{?enable_tests}
+BuildRequires:  npm(jsonfile)
+BuildRequires:  npm(mkdirp)
+BuildRequires:  npm(mocha)
+BuildRequires:  npm(ncp)
+BuildRequires:  npm(rimraf)
+# Not yet packaged for Fedora.
+# BuildRequires:  npm(path-extra)
+# BuildRequires:  npm(testutil)
+%endif
+
+%description
+%{summary}.
+
+
+%prep
+%setup -q -n package
+%setup -q -T -D -a 1 -n package
+chmod 644 package.json
+
+%nodejs_fixdep ncp '~0.5'
+
+
+%build
+#nothing to do
+
+
+%install
+mkdir -p %{buildroot}%{nodejs_sitelib}/fs-extra
+cp -pr package.json lib/ \
+    %{buildroot}%{nodejs_sitelib}/fs-extra
+
+%nodejs_symlink_deps
+
+
+%if 0%{?enable_tests}
+%check
+%nodejs_symlink_deps --check
+# /usr/bin/npm install path-extra at 0.0.x
+# /usr/bin/npm install testutil at 0.5.x
+/usr/bin/mocha -R spec test
+%endif
+
+
+%files
+%doc CHANGELOG.md LICENSE README.md
+%{nodejs_sitelib}/fs-extra
+
+
+%changelog
+* Wed Apr 23 2014 Jamie Nguyen <jamielinux at fedoraproject.org> - 0.8.1-2
+- fix version of npm(ncp) dependency
+
+* Sat Apr 19 2014 Jamie Nguyen <jamielinux at fedoraproject.org> - 0.8.1-1
+- initial package
diff --git a/sources b/sources
index e69de29..59f5b65 100644
--- a/sources
+++ b/sources
@@ -0,0 +1,2 @@
+bb55aca171c71262c0eced254ff90fe3  fs-extra-0.8.1.tgz
+2f70e89e8c4aee9480f07980716555be  tests-v0.8.1.tar.bz2


More information about the scm-commits mailing list