# tests disabled, missing dependencies, jshint has incompatible license # tests not included, need to be downloaded from upstream repo %global enable_tests 0 %global srcname handlebars Name: nodejs-%{srcname} Version: 2.0.0 Release: 1%{?dist} Summary: Build semantic templates effectively with no frustration License: MIT Group: System Environment/Libraries URL: http://www.handlebarsjs.com/ Source0: http://registry.npmjs.org/%{srcname}/-/%{srcname}-%{version}.tgz BuildArch: noarch ExclusiveArch: %{nodejs_arches} noarch BuildRequires: nodejs-packaging %if 0%{?enable_tests} BuildRequires: npm BuildRequires: npm(grunt-cli) BuildRequires: npm(grunt-contrib-clean) BuildRequires: npm(grunt-contrib-concat) BuildRequires: npm(grunt-contrib-connect) BuildRequires: npm(grunt-contrib-copy) BuildRequires: npm(grunt-contrib-requrejs) BuildRequires: npm(grunt-contrib-jshint) BuildRequires: npm(grunt-contrib-uglify) BuildRequires: npm(grunt-contrib-watch) BuildRequires: npm(es6-module-packager) %endif %description Handlebars provides the power necessary to let you build semantic templates effectively with no frustration. Handlebars is largely compatible with Mustache templates. In most cases it is possible to swap out Mustache with Handlebars and continue using your current templates. %prep %setup -q -n package %build #nothing to do %install mkdir -p %{buildroot}%{nodejs_sitelib}/%{srcname} cp -pr package.json runtime.js bin/ dist/ lib/ print-script \ %{buildroot}%{nodejs_sitelib}/%{srcname} mkdir -p %{buildroot}%{_bindir} ln -s %{nodejs_sitelib}/%{srcname}/bin/handlebars \ %{buildroot}%{_bindir}/handlebars %nodejs_symlink_deps %if 0%{?enable_tests} %check %nodejs_symlink_deps --check npm test %endif %files %doc LICENSE README.markdown CONTRIBUTING.md CONTRIBUTING.md release-notes.md %doc FAQ.md %{nodejs_sitelib}/%{srcname} %{_bindir}/%{srcname} %changelog * Tue Nov 18 2014 Piotr Popieluch - 2.0.0-1 - Initial package