commit
3ba1e2bef1
43
nodejs-package.spec
Normal file
43
nodejs-package.spec
Normal file
@ -0,0 +1,43 @@
|
||||
%{?nodejs_find_provides_and_requires}
|
||||
%global enable_tests 1
|
||||
Name: nodejs-package
|
||||
Version: 1.0.1
|
||||
Release: 1
|
||||
Summary: Provides an easy way to export package.json data
|
||||
License: MIT
|
||||
URL: https://github.com/vesln/package
|
||||
Source0: http://registry.npmjs.org/package/-/package-%{version}.tgz
|
||||
BuildArch: noarch
|
||||
ExclusiveArch: %{nodejs_arches} noarch
|
||||
BuildRequires: nodejs-packaging
|
||||
%if 0%{?enable_tests}
|
||||
BuildRequires: npm(mocha) npm(should)
|
||||
%endif
|
||||
%description
|
||||
%{summary}.
|
||||
|
||||
%prep
|
||||
%setup -q -n package
|
||||
|
||||
%build
|
||||
|
||||
%install
|
||||
mkdir -p %{buildroot}%{nodejs_sitelib}/package
|
||||
cp -pr package.json lib/ \
|
||||
%{buildroot}%{nodejs_sitelib}/package
|
||||
%nodejs_symlink_deps
|
||||
%if 0%{?enable_tests}
|
||||
|
||||
%check
|
||||
%nodejs_symlink_deps --check
|
||||
NODE_ENV=test %{nodejs_sitelib}/mocha/bin/mocha -R spec --require should \
|
||||
$(find test -iname '*.test.js')
|
||||
%endif
|
||||
|
||||
%files
|
||||
%doc Readme.md examples/
|
||||
%{nodejs_sitelib}/package
|
||||
|
||||
%changelog
|
||||
* Thu Aug 20 2020 wangchong <wangchong56@huawei.com> - 1.0.1-1
|
||||
- package init
|
||||
4
nodejs-package.yaml
Normal file
4
nodejs-package.yaml
Normal file
@ -0,0 +1,4 @@
|
||||
version_control: github
|
||||
src_repo: vesln/package
|
||||
tag_prefix: ^
|
||||
seperator: .
|
||||
BIN
package-1.0.1.tgz
Normal file
BIN
package-1.0.1.tgz
Normal file
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user