commit
10f94c8789
43
nodejs-clone.spec
Normal file
43
nodejs-clone.spec
Normal file
@ -0,0 +1,43 @@
|
|||||||
|
%global enable_tests 1
|
||||||
|
%global srcname clone
|
||||||
|
Name: nodejs-%{srcname}
|
||||||
|
Version: 1.0.2
|
||||||
|
Release: 1
|
||||||
|
Summary: Deep cloning of objects and arrays
|
||||||
|
License: MIT
|
||||||
|
URL: https://github.com/pvorb/clone
|
||||||
|
Source0: https://github.com/pvorb/clone/archive/v%{version}.tar.gz
|
||||||
|
BuildArch: noarch
|
||||||
|
ExclusiveArch: %{nodejs_arches} noarch
|
||||||
|
BuildRequires: nodejs-packaging
|
||||||
|
%if 0%{?enable_tests}
|
||||||
|
BuildRequires: nodeunit npm(underscore)
|
||||||
|
%endif
|
||||||
|
%description
|
||||||
|
Offers foolproof deep cloning of variables in JavaScript.
|
||||||
|
|
||||||
|
%prep
|
||||||
|
%autosetup -n clone-%{version}
|
||||||
|
rm -rf node_modules/
|
||||||
|
|
||||||
|
%build
|
||||||
|
|
||||||
|
%install
|
||||||
|
mkdir -p %{buildroot}%{nodejs_sitelib}/%{srcname}
|
||||||
|
cp -pr package.json clone.js %{buildroot}%{nodejs_sitelib}/%{srcname}
|
||||||
|
%nodejs_symlink_deps
|
||||||
|
%if 0%{?enable_tests}
|
||||||
|
|
||||||
|
%check
|
||||||
|
%nodejs_symlink_deps --check
|
||||||
|
nodeunit test.js
|
||||||
|
%endif
|
||||||
|
|
||||||
|
%files
|
||||||
|
%doc README.md
|
||||||
|
%license LICENSE
|
||||||
|
%{nodejs_sitelib}/%{srcname}
|
||||||
|
|
||||||
|
%changelog
|
||||||
|
* Mon Aug 17 2020 Anan Fu <fuanan3@huawei.com> - 1.0.2-1
|
||||||
|
- package init
|
||||||
4
nodejs-clone.yaml
Normal file
4
nodejs-clone.yaml
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
version_control: github
|
||||||
|
src_repo: pvorb/clone
|
||||||
|
tag_prefix: "^v"
|
||||||
|
seperator: "."
|
||||||
BIN
v1.0.2.tar.gz
Normal file
BIN
v1.0.2.tar.gz
Normal file
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user