fix(format): Remove redundant package.json property checks

This commit is contained in:
Philipp Kunz 2024-10-23 22:11:18 +02:00
parent 924470407a
commit b98dc7a9fa
4 changed files with 3440 additions and 5011 deletions

View File

@ -1,5 +1,11 @@
# Changelog
## 2024-10-23 - 1.9.126 - fix(format)
Remove redundant package.json property checks
- Removed property checks for `main`, `typings`, and `browserslist` from format.packagejson.ts
- This change streamlines the formatting process by removing unnecessary exits
## 2024-09-29 - 1.9.125 - fix(cli)
Fix package version configuration and formatting issues

File diff suppressed because it is too large Load Diff

View File

@ -3,6 +3,6 @@
*/
export const commitinfo = {
name: '@git.zone/cli',
version: '1.9.125',
version: '1.9.126',
description: 'A CLI toolbelt to streamline local development cycles by using various gitzone utilities.'
}

View File

@ -70,23 +70,6 @@ export const run = async (projectArg: Project) => {
packageJson.scripts.buildDocs = `tsdoc`;
}
// check package.json
if (!packageJson.main) {
logger.log('error', 'no "main" property');
process.exit(0);
}
if (!packageJson.typings) {
logger.log('error', 'no "typings" property');
process.exit(0);
}
if (!packageJson.browserslist) {
packageJson.browserslist = ['last 1 chrome versions'];
}
if (!packageJson.main.includes('dist_') || !packageJson.typings.includes('dist_')) {
logger.log('error', 'check packagesJson main and typings');
process.exit(0);
}
// check for files
packageJson.files = [
'ts/**/*',