Blame SPECS/nodejs-is-plain-obj.spec

ab718c
%{?scl:%scl_package nodejs-%{module_name}}
ab718c
%{!?scl:%global pkg_name %{name}}
ab718c
%{?nodejs_find_provides_and_requires}
ab718c
ab718c
# ava is not in fedora yet
ab718c
%global enable_tests 0
ab718c
%global module_name is-plain-obj
ab718c
%global commit0 ca2adca4deadaa0a632d8abc40e1e4654ccd4c1b
ab718c
%global shortcommit0 %(c=%{commit0}; echo ${c:0:7})
ab718c
ab718c
Name:           %{?scl_prefix}nodejs-%{module_name}
ab718c
Version:        1.0.0
ab718c
Release:        6%{?dist}
ab718c
Summary:        Check if a value is a plain object
ab718c
ab718c
License:        MIT
ab718c
URL:            https://github.com/sindresorhus/is-plain-obj
ab718c
Source0:        https://github.com/sindresorhus/%{module_name}/archive/%{commit0}.tar.gz#/%{module_name}-%{shortcommit0}.tar.gz
ab718c
ab718c
BuildArch:      noarch
ab718c
ExclusiveArch:  %{nodejs_arches} noarch
ab718c
ab718c
BuildRequires:  %{?scl_prefix}nodejs-devel
ab718c
ab718c
%if 0%{?enable_tests}
ab718c
BuildRequires:  %{?scl_prefix}npm(ava)
ab718c
%endif
ab718c
ab718c
%description
ab718c
%{summary}.
ab718c
ab718c
%prep
ab718c
%setup -q -n %{module_name}-%{commit0}
ab718c
rm -rf node_modules
ab718c
ab718c
%build
ab718c
# nothing to build
ab718c
ab718c
%install
ab718c
mkdir -p %{buildroot}%{nodejs_sitelib}/%{module_name}
ab718c
cp -p package.json index.js %{buildroot}%{nodejs_sitelib}/%{module_name}
ab718c
%nodejs_symlink_deps
ab718c
ab718c
%if 0%{?enable_tests}
ab718c
ab718c
%check
ab718c
%nodejs_symlink_deps --check
ab718c
node test.js
ab718c
%endif
ab718c
ab718c
%files
ab718c
%{!?_licensedir:%global license %doc}
ab718c
%doc readme.md
ab718c
%license license
ab718c
%{nodejs_sitelib}/%{module_name}
ab718c
ab718c
%changelog
ab718c
* Fri Jul 07 2017 Zuzana Svetlikova <zsvetlik@redhat.com> - 1.0.0-6
ab718c
- rh-nodejs8 rebuild
ab718c
ab718c
* Tue Feb 16 2016 Zuzana Svetlikova <zsvetlik@redhat.com> - 1.0.0-5
ab718c
- Use macro in -runtime dependency
ab718c
ab718c
* Sun Feb 14 2016 Zuzana Svetlikova <zsvetlik@redhat.com> - 1.0.0-4
ab718c
- Rebuilt with updated metapackage
ab718c
ab718c
* Tue Jan 12 2016 Tomas Hrcka <thrcka@redhat.com> - 1.0.0-3
ab718c
- Use macro to find provides and requires
ab718c
ab718c
* Tue Jan 12 2016 Tomas Hrcka <thrcka@redhat.com> - 1.0.0-2
ab718c
- Enable scl macros, fix license macro for el6
ab718c
ab718c
* Fri Jul 31 2015 Parag Nemade <pnemade AT redhat DOT com> - 1.0.0-1
ab718c
- Initial packaging