commit
1d94b90639
49
nodejs-os-homedir.spec
Normal file
49
nodejs-os-homedir.spec
Normal file
@ -0,0 +1,49 @@
|
|||||||
|
%{?nodejs_find_provides_and_requires}
|
||||||
|
%global packagename os-homedir
|
||||||
|
%global enable_tests 0
|
||||||
|
Name: nodejs-os-homedir
|
||||||
|
Version: 1.0.1
|
||||||
|
Release: 1
|
||||||
|
Summary: An io.js 2.3.0 os.homedir() ponyfill
|
||||||
|
License: MIT
|
||||||
|
URL: https://github.com/sindresorhus/os-homedir
|
||||||
|
Source0: https://registry.npmjs.org/%{packagename}/-/%{packagename}-%{version}.tgz
|
||||||
|
Source1: https://raw.githubusercontent.com/sindresorhus/os-homedir/v%{version}/test.js
|
||||||
|
ExclusiveArch: %{nodejs_arches} noarch
|
||||||
|
BuildArch: noarch
|
||||||
|
BuildRequires: nodejs-packaging
|
||||||
|
%if 0%{?enable_tests}
|
||||||
|
BuildRequires: ava
|
||||||
|
%endif
|
||||||
|
Requires: nodejs
|
||||||
|
%description
|
||||||
|
An io.js 2.3.0 os.homedir() ponyfill
|
||||||
|
|
||||||
|
%prep
|
||||||
|
%setup -q -n package
|
||||||
|
cp -p %{SOURCE1} .
|
||||||
|
|
||||||
|
%build
|
||||||
|
|
||||||
|
%install
|
||||||
|
mkdir -p %{buildroot}%{nodejs_sitelib}/%{packagename}
|
||||||
|
cp -pr package.json index.js \
|
||||||
|
%{buildroot}%{nodejs_sitelib}/%{packagename}
|
||||||
|
%nodejs_symlink_deps
|
||||||
|
%if 0%{?enable_tests}
|
||||||
|
|
||||||
|
%check
|
||||||
|
%nodejs_symlink_deps --check
|
||||||
|
%{__nodejs} -e 'require("./")'
|
||||||
|
%__nodejs test.js
|
||||||
|
%endif
|
||||||
|
|
||||||
|
%files
|
||||||
|
%{!?_licensedir:%global license %doc}
|
||||||
|
%doc *.md
|
||||||
|
%license license
|
||||||
|
%{nodejs_sitelib}/%{packagename}
|
||||||
|
|
||||||
|
%changelog
|
||||||
|
* Mon Aug 17 2020 wutao <wutao61@huawei.com> - 1.0.1-1
|
||||||
|
- Package init
|
||||||
4
nodejs-os-homedir.yaml
Normal file
4
nodejs-os-homedir.yaml
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
version_control: github
|
||||||
|
src_repo: sindresorhus/os-homedir
|
||||||
|
tag_prefix: "^v"
|
||||||
|
seperator: "."
|
||||||
BIN
os-homedir-1.0.1.tgz
Normal file
BIN
os-homedir-1.0.1.tgz
Normal file
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user