%global npmname winston-transport Name: nodejs-%{npmname} Version: 4.3.0 Release: 1%{?dist} Summary: Base stream implementations for winston@3 and up License: MIT URL: https://www.npmjs.com/package/%{npmname} Source0: https://github.com/winstonjs/winston-transport/archive/%{version}/%{name}-%{version}.tar.gz # Stop the tests from trying to test the transpiled nodejs # We can't ship it because it needs the babel compiler, and # I'm not going to package that just for this. #Patch0: nodejs-logform-no-transpiled-tests.patch BuildRequires: nodejs-packaging BuildRequires: mocha BuildRequires: nodejs-abstract-winston-transport BuildRequires: nodejs-assume BuildRequires: nodejs-logform BuildRequires: nodejs-readable-stream BuildRequires: nodejs-triple-beam BuildArch: noarch ExclusiveArch: %{nodejs_arches} noarch %description The base TransportStream implementation for winston >= 3. Use these to write ecosystem Transports for winston. %prep %autosetup -n %{npmname}-%{version} # Remove legacy test which requires winston-compat # (and thus recursively depends on this!) rm test/legacy.test.js %build # Nothing to build, this is a noarch package %install mkdir -p %{buildroot}%{nodejs_sitelib}/%{npmname} cp -a *.js %{buildroot}%{nodejs_sitelib}/%{npmname}/ cp -a package.json %{buildroot}%{nodejs_sitelib}/%{npmname}/ %nodejs_symlink_deps %check %nodejs_symlink_deps --check %{__nodejs} -e 'require("./")' mocha test/*.test.js %files %{nodejs_sitelib}/%{npmname}/ %license LICENSE %doc README.md CHANGELOG.md %changelog * Tue Apr 28 2020 Ben Rosser - 4.3.0-1 - Initial package for Fedora.