%global enable_tests 0 Name: nodejs-hawk Version: 4.1.2 Release: 2 Summary: HTTP Hawk authentication scheme License: BSD-3-Clause URL: https://github.com/hueniverse/hawk Source0: https://registry.npmjs.org/hawk/-/hawk-%{version}.tgz BuildArch: noarch ExclusiveArch: %{nodejs_arches} noarch BuildRequires: nodejs-packaging npm(boom) npm(cryptiles) npm(hoek) npm(sntp) %if 0%{?enable_tests} BuildRequires: npm(lab) npm(code) %endif %description Hawk is an HTTP authentication scheme using a message authentication code (MAC) algorithm to provide partial HTTP request cryptographic verification. %prep %autosetup -n package %nodejs_fixdep cryptiles "^2.0.5" %nodejs_fixdep boom "^2.10.1" %nodejs_fixdep hoek "^0.9.1" chmod a-x README.md LICENSE package.json client.js example/* images/* lib/* sed -i 's/\r$//' README.md sed -i 's/\r$//' example/usage.js %build %install mkdir -p %{buildroot}%{nodejs_sitelib}/hawk cp -pr package.json lib %{buildroot}%{nodejs_sitelib}/hawk %nodejs_symlink_deps %check %nodejs_symlink_deps --check %__nodejs -e "require('./')" %if 0%{?enable_tests} %{nodejs_sitelib}/lab/bin/lab -a code -t 100 -L %endif %files %doc README.md example images %license LICENSE %{nodejs_sitelib}/hawk %changelog * Mon May 9 2022 liyanan - 4.1.2-2 - License compliance rectification * Thu Aug 20 2020 wangxiao - 4.1.2-1 - Package init