%global npm_name ultron # Although there are tests # the dependancies aren't in Fedora yet %global enable_tests 0 %{?nodejs_find_provides_and_requires} Summary: Ultron is a high-intelligence robot Name: nodejs-%{npm_name} Version: 1.0.1 Release: 3%{?dist} License: MIT URL: https://github.com/unshiftio/ultron Source0: http://registry.npmjs.org/%{npm_name}/-/%{npm_name}-%{version}.tgz # Upstream licence file, will be in next release # https://github.com/unshiftio/ultron/blob/master/LICENSE Source1: nodejs-ultron-LICENSE BuildRequires: nodejs-devel %if 0%{?enable_tests} BuildRequires: npm(assume) BuildRequires: npm(eventemitter3) BuildRequires: npm(istanbul) BuildRequires: npm(mocha) BuildRequires: npm(pre-commit) %endif ExclusiveArch: %{ix86} x86_64 %{arm} noarch BuildArch: noarch %description Ultron is a high-intelligence robot. It gathers intelligence so it can start improving upon his rudimentary design. It will learn your event emitting patterns and find ways to exterminate them. Allowing you to remove only the event emitters that you assigned and not the ones that your users or developers assigned. This can prevent race conditions, memory leaks and even file descriptor leaks from ever happening as you won't remove clean up processes. %prep %setup -q -n package cp %{SOURCE1} LICENSE %build %install mkdir -p %{buildroot}%{nodejs_sitelib}/%{npm_name} cp -pr index.js package.json test.js %{buildroot}%{nodejs_sitelib}/%{npm_name} %if 0%{?enable_tests} %check mocha --reporter spec --ui bdd test.js %endif %files %doc README.md %license LICENSE %{nodejs_sitelib}/%{npm_name} %changelog * Mon Feb 16 2015 Troy Dawson - 1.0.1-3 - Added upsteam license file as source1 * Fri Feb 13 2015 Troy Dawson - 1.0.1-2 - Removed Group: - Added a generic MIT license file as source1 * Tue Feb 03 2015 Troy Dawson - 1.0.1-1 - Initial spec file