nodejs-minimatch/nodejs-minimatch.spec
‘jiangpeng’ a8f01693ef CVE-2022-3517
modified:   nodejs-minimatch.spec

	modified:   nodejs-minimatch.spec

(cherry picked from commit 41840763d0f7e00f1f5ff73e0fbbe3215d678ab5)
2022-10-25 17:51:48 +08:00

50 lines
1.3 KiB
RPMSpec

%{?nodejs_find_provides_and_requires}
%global enable_tests 0
Name: nodejs-minimatch
Version: 3.0.4
Release: 2
Summary: JavaScript glob matcher
License: MIT
URL: https://github.com/isaacs/minimatch
Source0: https://github.com/isaacs/minimatch/archive/v%{version}/%{name}-%{version}.tar.gz
Patch1: CVE-2022-3517.patch
BuildArch: noarch
ExclusiveArch: %{nodejs_arches} noarch
BuildRequires: nodejs-packaging
BuildRequires: npm(tap) npm(brace-expansion)
%description
Converts glob expressions to JavaScript "RegExp" objects.
%prep
%autosetup -n minimatch-%{version} -p1
%build
%install
mkdir -p %{buildroot}%{nodejs_sitelib}/minimatch
cp -p package.json minimatch.js %{buildroot}%{nodejs_sitelib}/minimatch
%nodejs_symlink_deps
%check
%nodejs_symlink_deps --check
%{__nodejs} -e 'require("./")'
%if 0%{?enable_tests}
%{_bindir}/tap test/*.js
%else
%{_bindir}/echo -e "\e[101m -=#=- Tests disabled -=#=- \e[0m"
%endif
%files
%{!?_licensedir:%global license %doc}
%doc README.md
%license LICENSE
%{nodejs_sitelib}/minimatch
%changelog
* Tue Oct 25 2022 jiangpeng <jiangpeng01@ncti-gba.cn> - 3.0.4-2
- Fix CVE-2022-3517
* Mon Aug 17 2020 wutao <wutao61@huawei.com> - 3.0.4-1
- Package init