fix(core): Fix incorrect logging and directory preparation
This commit is contained in:
		| @@ -1,5 +1,11 @@ | ||||
| # Changelog | ||||
|  | ||||
| ## 2024-10-28 - 1.5.3 - fix(core) | ||||
| Fix incorrect logging and directory preparation | ||||
|  | ||||
| - Corrected logging to accurately report the number of detected publish modules. | ||||
| - Ensured the publish directory is emptied before creating package.json. | ||||
|  | ||||
| ## 2024-10-28 - 1.5.2 - fix(core) | ||||
| Add logging for found publish modules | ||||
|  | ||||
|   | ||||
| @@ -3,6 +3,6 @@ | ||||
|  */ | ||||
| export const commitinfo = { | ||||
|   name: '@git.zone/tspublish', | ||||
|   version: '1.5.2', | ||||
|   version: '1.5.3', | ||||
|   description: 'A tool to publish multiple, concise, and small packages from monorepos, specifically for TypeScript projects within a git environment.' | ||||
| } | ||||
|   | ||||
| @@ -142,9 +142,9 @@ export class PublishModule { | ||||
|       this.options.monoRepoDir, | ||||
|       `dist_publish_${this.options.packageSubFolder}` | ||||
|     ); | ||||
|     await plugins.smartfile.fs.ensureEmptyDir(this.options.publishModDirFullPath); | ||||
|  | ||||
|     // package.json | ||||
|     await plugins.smartfile.fs.ensureEmptyDir(this.options.publishModDirFullPath); | ||||
|     const packageJson = await plugins.smartfile.SmartFile.fromString( | ||||
|       plugins.path.join(this.options.publishModDirFullPath, 'package.json'), | ||||
|       await this.createPackageJson(), | ||||
|   | ||||
| @@ -9,8 +9,8 @@ export class TsPublish { | ||||
|  | ||||
|   public async publish (monorepoDirArg: string) { | ||||
|     const publishModules = await this.getModuleSubDirs(monorepoDirArg); | ||||
|     console.log(`Found ${publishModules.length} publish modules:`); | ||||
|     console.log(publishModules); | ||||
|     console.log(`Found ${Object.keys(publishModules).length} publish modules:`); | ||||
|     console.log(Object.keys(publishModules)); | ||||
|     for (const publishModule of Object.keys(publishModules)) { | ||||
|       const publishModuleInstance = new PublishModule({ | ||||
|         monoRepoDir: monorepoDirArg, | ||||
|   | ||||
		Reference in New Issue
	
	Block a user