50 lines
1.2 KiB
RPMSpec
50 lines
1.2 KiB
RPMSpec
%{?nodejs_find_provides_and_requires}
|
|
%global packagename spdx-correct
|
|
%global enable_tests 1
|
|
Name: nodejs-spdx-correct
|
|
Version: 2.0.4
|
|
Release: 1
|
|
Summary: Correct invalid SPDX identifiers
|
|
License: ASL 2.0
|
|
URL: https://github.com/jslicense/spdx-correct.js
|
|
Source0: https://github.com/jslicense/spdx-correct.js/archive/v%{version}.tar.gz
|
|
ExclusiveArch: %{nodejs_arches} noarch
|
|
BuildArch: noarch
|
|
BuildRequires: nodejs-packaging
|
|
%if 0%{?enable_tests}
|
|
BuildRequires: npm(tape) npm(spdx-expression-parse)
|
|
%endif
|
|
%description
|
|
correct invalid SPDX identifiers
|
|
|
|
%prep
|
|
%autosetup -n spdx-correct.js-%{version}
|
|
|
|
%build
|
|
|
|
%install
|
|
mkdir -p %{buildroot}%{nodejs_sitelib}/%{packagename}
|
|
cp -pr package.json *.js \
|
|
%{buildroot}%{nodejs_sitelib}/%{packagename}
|
|
%nodejs_symlink_deps
|
|
|
|
%check
|
|
%nodejs_symlink_deps --check
|
|
%{__nodejs} -e 'require("./")'
|
|
%if 0%{?enable_tests}
|
|
%__nodejs test.js
|
|
%endif
|
|
|
|
%files
|
|
%{!?_licensedir:%global license %doc}
|
|
%doc *.md
|
|
%license LICENSE
|
|
%{nodejs_sitelib}/%{packagename}
|
|
|
|
%changelog
|
|
* Mon Oct 30 2023 wulei <wu_lei@hoperun.com> - 2.0.4-1
|
|
- Update to 2.0.4
|
|
|
|
* Wed Aug 12 2020 zhanghua <zhanghua40@huawei.com> - 1.0.2-1
|
|
- package init
|