2020-09-01 10:20:03 +08:00
|
|
|
%{?nodejs_find_provides_and_requires}
|
|
|
|
|
%global enable_tests 0
|
|
|
|
|
Name: nodejs-estraverse
|
|
|
|
|
Version: 4.2.0
|
2022-05-09 18:17:26 +08:00
|
|
|
Release: 2
|
2020-09-01 10:20:03 +08:00
|
|
|
Summary: ECMAScript JS AST traversal functions
|
2022-05-09 18:17:26 +08:00
|
|
|
License: BSD-2-Clause
|
2020-09-01 10:20:03 +08:00
|
|
|
URL: https://github.com/Constellation/estraverse
|
2020-09-07 20:18:47 +08:00
|
|
|
Source0: https://github.com/Constellation/estraverse/archive/%{version}.tar.gz
|
2020-09-01 10:20:03 +08:00
|
|
|
Source10: dl-tests.sh
|
|
|
|
|
BuildArch: noarch
|
|
|
|
|
ExclusiveArch: %{nodejs_arches} noarch
|
|
|
|
|
ExclusiveArch: %{ix86} x86_64 %{arm} noarch
|
|
|
|
|
BuildRequires: nodejs-packaging
|
|
|
|
|
BuildRequires: npm(coffee-script)
|
|
|
|
|
%if 0%{?enable_tests}
|
|
|
|
|
BuildRequires: npm(chai) npm(espree) npm(mocha)
|
|
|
|
|
%endif
|
|
|
|
|
%description
|
|
|
|
|
%{summary}.
|
|
|
|
|
|
|
|
|
|
%prep
|
2020-09-07 20:18:47 +08:00
|
|
|
%autosetup -n estraverse-%{version}
|
2020-09-01 10:20:03 +08:00
|
|
|
|
|
|
|
|
%build
|
|
|
|
|
|
|
|
|
|
%install
|
|
|
|
|
mkdir -p %{buildroot}%{nodejs_sitelib}/estraverse
|
|
|
|
|
cp -pr package.json estraverse.js \
|
|
|
|
|
%{buildroot}%{nodejs_sitelib}/estraverse
|
|
|
|
|
%nodejs_symlink_deps
|
|
|
|
|
|
|
|
|
|
%check
|
|
|
|
|
%nodejs_symlink_deps --check
|
|
|
|
|
%{__nodejs} -e 'require("./")'
|
|
|
|
|
%if 0%{?enable_tests}
|
|
|
|
|
%{_bindir}/mocha --compilers coffee:coffee-script/register
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%files
|
|
|
|
|
%{!?_licensedir:%global license %doc}
|
|
|
|
|
%doc LICENSE.BSD
|
|
|
|
|
%{nodejs_sitelib}/estraverse
|
|
|
|
|
|
|
|
|
|
%changelog
|
2022-05-09 18:17:26 +08:00
|
|
|
* Mon May 9 2022 liyanan <liyanan32@h-partners.com> - 4.2.0-2
|
|
|
|
|
- License compliance rectification
|
|
|
|
|
|
2020-09-01 10:20:03 +08:00
|
|
|
* Thu Aug 20 2020 Anan Fu <fuanan3@huawei.com> - 4.2.0-1
|
|
|
|
|
- package init
|