diff --git a/0001-fix-package.json-make-the-rpm-can-provides-npm-requi.patch b/0001-fix-package.json-make-the-rpm-can-provides-npm-requi.patch new file mode 100644 index 0000000..1746785 --- /dev/null +++ b/0001-fix-package.json-make-the-rpm-can-provides-npm-requi.patch @@ -0,0 +1,47 @@ +From acd254fc434874d6a5d9600922a5455e1b743cf2 Mon Sep 17 00:00:00 2001 +From: wangxiao +Date: Wed, 9 Sep 2020 16:16:55 +0800 +Subject: [PATCH] fix package.json, make the rpm can provides npm(requirejs) + +--- + package.json | 27 +++++++++++++++++++++++++-- + 1 file changed, 25 insertions(+), 2 deletions(-) + +diff --git a/package.json b/package.json +index a4f0e80..c4f4583 100644 +--- a/package.json ++++ b/package.json +@@ -1,5 +1,28 @@ + { +- "volo": { +- "url": "https://raw.github.com/jrburke/r.js/{version}/dist/r.js" ++ "name": "requirejs", ++ "description": "Node adapter for RequireJS, for loading AMD modules. Includes RequireJS optimizer", ++ "version": "2.1.11", ++ "homepage": "http://github.com/jrburke/r.js", ++ "author": "James Burke (http://github.com/jrburke)", ++ "licenses": [ ++ { ++ "type": "BSD", ++ "url": "https://github.com/jrburke/r.js/blob/master/LICENSE" ++ }, ++ { ++ "type": "MIT", ++ "url": "https://github.com/jrburke/r.js/blob/master/LICENSE" ++ } ++ ], ++ "repository": { ++ "type": "git", ++ "url": "https://github.com/jrburke/r.js.git" ++ }, ++ "main": "./bin/r.js", ++ "bin": { ++ "r.js": "./bin/r.js" ++ }, ++ "engines": { ++ "node": ">=0.4.0" + } + } +-- +2.23.0 + diff --git a/nodejs-requirejs.spec b/nodejs-requirejs.spec index 9995f27..513f14e 100644 --- a/nodejs-requirejs.spec +++ b/nodejs-requirejs.spec @@ -4,11 +4,12 @@ Name: nodejs-requirejs Version: 2.1.11 -Release: 1 +Release: 2 Summary: Node.js adapter for RequireJS, for loading AMD modules License: MIT or BSD URL: https://github.com/jrburke/r.js Source0: https://github.com/jrburke/r.js/archive/%{version}.tar.gz +Patch0000: 0001-fix-package.json-make-the-rpm-can-provides-npm-requi.patch BuildArch: noarch ExclusiveArch: %{nodejs_arches} noarch BuildRequires: nodejs-packaging @@ -21,7 +22,7 @@ improve the speed and quality of your code. %prep -%autosetup -n r.js-%{version} +%autosetup -p1 -n r.js-%{version} %build @@ -57,5 +58,7 @@ popd %changelog +* Fri Sep 11 2020 wangxiao - 2.1.11-2 +- fix package.json * Wed Aug 19 2020 wangxiao - 2.1.11-1 - package init