chore: allow private build-only packages (#10893)
This commit is contained in:
parent
f166c67707
commit
d8abb18c57
8
package-lock.json
generated
8
package-lock.json
generated
|
|
@ -4807,6 +4807,10 @@
|
||||||
"node": ">=6"
|
"node": ">=6"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"node_modules/html-reporter": {
|
||||||
|
"resolved": "packages/html-reporter",
|
||||||
|
"link": true
|
||||||
|
},
|
||||||
"node_modules/html-webpack-plugin": {
|
"node_modules/html-webpack-plugin": {
|
||||||
"version": "5.3.2",
|
"version": "5.3.2",
|
||||||
"resolved": "https://registry.npmjs.org/html-webpack-plugin/-/html-webpack-plugin-5.3.2.tgz",
|
"resolved": "https://registry.npmjs.org/html-webpack-plugin/-/html-webpack-plugin-5.3.2.tgz",
|
||||||
|
|
@ -9047,6 +9051,7 @@
|
||||||
"url": "https://github.com/sponsors/sindresorhus"
|
"url": "https://github.com/sponsors/sindresorhus"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"packages/html-reporter": {},
|
||||||
"packages/playwright": {
|
"packages/playwright": {
|
||||||
"version": "1.18.0-next",
|
"version": "1.18.0-next",
|
||||||
"hasInstallScript": true,
|
"hasInstallScript": true,
|
||||||
|
|
@ -12888,6 +12893,9 @@
|
||||||
"terser": "^4.6.3"
|
"terser": "^4.6.3"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"html-reporter": {
|
||||||
|
"version": "file:packages/html-reporter"
|
||||||
|
},
|
||||||
"html-webpack-plugin": {
|
"html-webpack-plugin": {
|
||||||
"version": "5.3.2",
|
"version": "5.3.2",
|
||||||
"resolved": "https://registry.npmjs.org/html-webpack-plugin/-/html-webpack-plugin-5.3.2.tgz",
|
"resolved": "https://registry.npmjs.org/html-webpack-plugin/-/html-webpack-plugin-5.3.2.tgz",
|
||||||
|
|
|
||||||
2
packages/html-reporter/build.js
Normal file
2
packages/html-reporter/build.js
Normal file
|
|
@ -0,0 +1,2 @@
|
||||||
|
// write something to playwright-core/lib/web/ with webpack
|
||||||
|
|
||||||
4
packages/html-reporter/package.json
Normal file
4
packages/html-reporter/package.json
Normal file
|
|
@ -0,0 +1,4 @@
|
||||||
|
{
|
||||||
|
"name": "html-reporter",
|
||||||
|
"private": true
|
||||||
|
}
|
||||||
|
|
@ -35,4 +35,10 @@ function* internalDependencies(packagePath) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
module.exports = { packages, packageNameToPath };
|
const packagesToPublish = packages.filter(packagePath => !packagePathToJSON.get(packagePath).private);
|
||||||
|
|
||||||
|
module.exports = {
|
||||||
|
packages,
|
||||||
|
packageNameToPath,
|
||||||
|
packagesToPublish,
|
||||||
|
};
|
||||||
|
|
|
||||||
|
|
@ -55,6 +55,9 @@ const PACKAGES = {
|
||||||
browsers: ['chromium', 'ffmpeg'],
|
browsers: ['chromium', 'ffmpeg'],
|
||||||
files: LICENSE_FILES,
|
files: LICENSE_FILES,
|
||||||
},
|
},
|
||||||
|
'html-reporter': {
|
||||||
|
files: [],
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
const dirtyFiles = [];
|
const dirtyFiles = [];
|
||||||
|
|
@ -92,6 +95,8 @@ async function lintPackage(packageName) {
|
||||||
// 4. Generate package.json
|
// 4. Generate package.json
|
||||||
const pwInternalJSON = require(path.join(ROOT_PATH, 'package.json'));
|
const pwInternalJSON = require(path.join(ROOT_PATH, 'package.json'));
|
||||||
const currentPackageJSON = require(path.join(packagePath, 'package.json'));
|
const currentPackageJSON = require(path.join(packagePath, 'package.json'));
|
||||||
|
if (currentPackageJSON.private)
|
||||||
|
return;
|
||||||
currentPackageJSON.version = pwInternalJSON.version;
|
currentPackageJSON.version = pwInternalJSON.version;
|
||||||
currentPackageJSON.repository = pwInternalJSON.repository;
|
currentPackageJSON.repository = pwInternalJSON.repository;
|
||||||
currentPackageJSON.engines = pwInternalJSON.engines;
|
currentPackageJSON.engines = pwInternalJSON.engines;
|
||||||
|
|
|
||||||
|
|
@ -92,7 +92,7 @@ fi
|
||||||
|
|
||||||
echo "==================== Publishing version ${VERSION} ================"
|
echo "==================== Publishing version ${VERSION} ================"
|
||||||
node ./utils/prepare_packages.js
|
node ./utils/prepare_packages.js
|
||||||
node -e "console.log(require('./utils/list_packages').packages.join('\\n'))" | while read package
|
node -e "console.log(require('./utils/list_packages').packagesToPublish.join('\\n'))" | while read package
|
||||||
do
|
do
|
||||||
npm publish ${package} --tag="${NPM_PUBLISH_TAG}"
|
npm publish ${package} --tag="${NPM_PUBLISH_TAG}"
|
||||||
done
|
done
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue