[nodejs-ast-types] Initial import (#1122211)
Ralph Bean
ralph at fedoraproject.org
Wed Jul 23 15:10:33 UTC 2014
commit 467a61ac38264ce516e7c58da883c9bf46c38033
Author: Ralph Bean <rbean at redhat.com>
Date: Wed Jul 23 11:10:26 2014 -0400
Initial import (#1122211)
.gitignore | 1 +
nodejs-ast-types.spec | 68 +++++++++++++++++++++++++++++++++++++++++++++++++
sources | 1 +
3 files changed, 70 insertions(+), 0 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index e69de29..0e6d62a 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/ast-types-0.4.5.tgz
diff --git a/nodejs-ast-types.spec b/nodejs-ast-types.spec
new file mode 100644
index 0000000..0f54895
--- /dev/null
+++ b/nodejs-ast-types.spec
@@ -0,0 +1,68 @@
+# This macro is needed at the start for building on EL6
+%{?nodejs_find_provides_and_requires}
+
+%global enable_tests 0
+
+%global barename ast-types
+
+Name: nodejs-ast-types
+Version: 0.4.5
+Release: 1%{?dist}
+Summary: Esprima-compatible implementation of the Mozilla JS Parser API
+
+Group: Development/Libraries
+License: MIT
+URL: https://www.npmjs.org/package/ast-types
+Source0: http://registry.npmjs.org/%{barename}/-/%{barename}-%{version}.tgz
+BuildArch: noarch
+%if 0%{?fedora} >= 19
+ExclusiveArch: %{nodejs_arches} noarch
+%else
+ExclusiveArch: %{ix86} x86_64 %{arm} noarch
+%endif
+
+BuildRequires: nodejs-packaging >= 6
+
+%if 0%{?enable_tests}
+BuildRequires: npm(esprima)
+BuildRequires: npm(mocha)
+%endif
+
+
+%description
+This module provides an efficient, modular, Esprima-compatible implementation
+of the abstract syntax tree type hierarchy pioneered by the Mozilla Parser API.
+
+%prep
+%setup -q -n package
+
+# Remove bundled node_modules if there are any..
+rm -rf node_modules/
+
+%nodejs_fixdep --caret
+
+%build
+%nodejs_symlink_deps --build
+
+%install
+mkdir -p %{buildroot}%{nodejs_sitelib}/ast-types
+cp -pr package.json main.js lib \
+ %{buildroot}%{nodejs_sitelib}/ast-types
+
+%nodejs_symlink_deps
+
+
+%check
+%if 0%{?enable_tests}
+%nodejs_symlink_deps --check
+mocha --reporter spec test/run.js
+%endif
+
+
+%files
+%doc README.md LICENSE
+%{nodejs_sitelib}/ast-types/
+
+%changelog
+* Tue Jul 22 2014 Ralph Bean <rbean at redhat.com> - 0.4.5-1
+- Initial packaging for Fedora.
diff --git a/sources b/sources
index e69de29..67c6d73 100644
--- a/sources
+++ b/sources
@@ -0,0 +1 @@
+80f1d9ecfe9ff8bf576c0dbe9056137a ast-types-0.4.5.tgz
More information about the scm-commits
mailing list