|
|
|
@ -1,5 +1,5 @@
|
|
|
|
|
const glob = require('glob');
|
|
|
|
|
const fse = require('fs-extra');
|
|
|
|
|
const glob = require("glob");
|
|
|
|
|
const fse = require("fs-extra");
|
|
|
|
|
|
|
|
|
|
function replace(filePath) {
|
|
|
|
|
const pkg = fse.readJsonSync(filePath);
|
|
|
|
@ -9,17 +9,17 @@ function replace(filePath) {
|
|
|
|
|
if (!dependencies) return;
|
|
|
|
|
|
|
|
|
|
Object.keys(dependencies).forEach((key) => {
|
|
|
|
|
if (key.includes('@abp/') && key !== '@abp/utils') {
|
|
|
|
|
dependencies[key] = dependencies[key].replace('^', '~');
|
|
|
|
|
if (key.includes("@abp/")) {
|
|
|
|
|
dependencies[key] = dependencies[key].replace("^", "~");
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
fse.writeJsonSync(filePath, { ...pkg, dependencies }, { spaces: 2 });
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
glob('./packs/**/package.json', {}, (er, files) => {
|
|
|
|
|
glob("./packs/**/package.json", {}, (er, files) => {
|
|
|
|
|
files.forEach((path) => {
|
|
|
|
|
if (path.includes('node_modules')) {
|
|
|
|
|
if (path.includes("node_modules")) {
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|