|
|
b04156 |
%{?scl:%scl_package nodejs-supports-color}
|
|
|
b04156 |
%{!?scl:%global pkg_name %{name}}
|
|
|
b04156 |
|
|
|
b04156 |
# This macro is needed at the start for building on EL6
|
|
|
b04156 |
%{?nodejs_find_provides_and_requires}
|
|
|
b04156 |
|
|
|
b04156 |
%global enable_tests 0
|
|
|
b04156 |
|
|
|
b04156 |
%global barename supports-color
|
|
|
b04156 |
|
|
|
b04156 |
Name: %{?scl_prefix}nodejs-supports-color
|
|
|
b04156 |
Version: 3.1.1
|
|
|
b04156 |
Release: 5%{?dist}
|
|
|
b04156 |
Summary: Detect whether a terminal supports color
|
|
|
b04156 |
License: MIT
|
|
|
b04156 |
URL: https://www.npmjs.org/package/supports-color
|
|
|
b04156 |
Source0: http://registry.npmjs.org/%{barename}/-/%{barename}-%{version}.tgz
|
|
|
b04156 |
#Source2: https://raw.githubusercontent.com/sindresorhus/supports-color/master/test.js
|
|
|
b04156 |
Source2: test.js
|
|
|
b04156 |
|
|
|
b04156 |
BuildArch: noarch
|
|
|
b04156 |
%if 0%{?fedora} >= 19
|
|
|
b04156 |
ExclusiveArch: %{nodejs_arches} noarch
|
|
|
b04156 |
%else
|
|
|
b04156 |
ExclusiveArch: %{ix86} x86_64 %{arm} noarch
|
|
|
b04156 |
%endif
|
|
|
b04156 |
|
|
|
b04156 |
BuildRequires: %{?scl_prefix}runtime
|
|
|
b04156 |
|
|
|
b04156 |
%if 0%{?enable_tests}
|
|
|
b04156 |
BuildRequires: %{?scl_prefix}npm(require-uncached)
|
|
|
b04156 |
BuildRequires: %{?scl_prefix}npm(mocha)
|
|
|
b04156 |
%endif
|
|
|
b04156 |
|
|
|
b04156 |
%description
|
|
|
b04156 |
Detect whether a terminal supports color
|
|
|
b04156 |
|
|
|
b04156 |
%prep
|
|
|
b04156 |
%setup -q -n package
|
|
|
b04156 |
cp %{SOURCE2} .
|
|
|
b04156 |
|
|
|
b04156 |
# Remove bundled node_modules if there are any..
|
|
|
b04156 |
rm -rf node_modules/
|
|
|
b04156 |
|
|
|
b04156 |
#%%nodejs_fixdep --caret
|
|
|
b04156 |
|
|
|
b04156 |
%build
|
|
|
b04156 |
# This causes warnings when running the tests
|
|
|
b04156 |
#%nodejs_symlink_deps --build
|
|
|
b04156 |
|
|
|
b04156 |
%install
|
|
|
b04156 |
mkdir -p %{buildroot}%{nodejs_sitelib}/supports-color
|
|
|
b04156 |
cp -pr browser.js index.js package.json \
|
|
|
b04156 |
%{buildroot}%{nodejs_sitelib}/supports-color
|
|
|
b04156 |
|
|
|
b04156 |
%nodejs_symlink_deps
|
|
|
b04156 |
|
|
|
b04156 |
%check
|
|
|
b04156 |
%if 0%{?enable_tests}
|
|
|
b04156 |
%nodejs_symlink_deps --check
|
|
|
b04156 |
mocha
|
|
|
b04156 |
%endif
|
|
|
b04156 |
|
|
|
b04156 |
%files
|
|
|
b04156 |
%{!?_licensedir:%global license %doc}
|
|
|
b04156 |
%license license
|
|
|
b04156 |
%doc readme.md
|
|
|
b04156 |
%{nodejs_sitelib}/supports-color/
|
|
|
b04156 |
|
|
|
b04156 |
%changelog
|
|
|
b04156 |
* Tue Feb 16 2016 Zuzana Svetlikova <zsvetlik@redhat.com> - 3.1.1-5
|
|
|
b04156 |
- Use macro in -runtime dependency
|
|
|
b04156 |
- Rebuilt with updated metapackage
|
|
|
b04156 |
|
|
|
b04156 |
* Thu Jan 07 2016 Tomas Hrcka <thrcka@redhat.com> - 3.1.1-2
|
|
|
b04156 |
- Enable scl macros
|
|
|
b04156 |
|
|
|
b04156 |
* Mon Sep 14 2015 Troy Dawson <tdawson@redhat.com> - 3.1.1-1
|
|
|
b04156 |
- Update to 3.1.1 (no longer has a binary)
|
|
|
b04156 |
- Remove tests until all dependencies are built
|
|
|
b04156 |
|
|
|
b04156 |
* Tue Feb 10 2015 Ralph Bean <rbean@redhat.com> - 1.2.0-2
|
|
|
b04156 |
- Include license from github.
|
|
|
b04156 |
- Enable tests.
|
|
|
b04156 |
- Make cli.js into a symlink.
|
|
|
b04156 |
- Comment out nodejs_symlink_deps --build, as per review.
|
|
|
b04156 |
|
|
|
b04156 |
* Tue Dec 02 2014 Ralph Bean <rbean@redhat.com> - 1.2.0-1
|
|
|
b04156 |
- Initial packaging for Fedora.
|