From 87b89cad3cae8adcf98ef07f8b59d4b46332b7d1 Mon Sep 17 00:00:00 2001 From: Jonathan Chemla Date: Thu, 4 Jul 2024 18:27:58 +0200 Subject: [PATCH 1/7] Add jsonOnly option to merge This option is meant to avoid copying resources (tileset.json and tile contents) when merging multiple input tilesets. Results in a tileset.json that references input tilesets where they are stored. --- src/cli/ToolsMain.ts | 5 +++-- src/cli/main.ts | 13 +++++++++++-- src/tools/tilesetProcessing/TilesetMerger.ts | 17 ++++++++++++----- .../tilesetProcessing/TilesetOperations.ts | 6 ++++-- 4 files changed, 30 insertions(+), 11 deletions(-) diff --git a/src/cli/ToolsMain.ts b/src/cli/ToolsMain.ts index 57050f92..2ad2252d 100644 --- a/src/cli/ToolsMain.ts +++ b/src/cli/ToolsMain.ts @@ -553,14 +553,15 @@ export class ToolsMain { logger.debug(`Executing upgrade DONE`); } - static async merge(inputs: string[], output: string, force: boolean) { + static async merge(inputs: string[], output: string, force: boolean, jsonOnly: boolean) { logger.debug(`Executing merge`); logger.debug(` inputs: ${inputs}`); logger.debug(` output: ${output}`); logger.debug(` force: ${force}`); + logger.debug(` jsonOnly: ${jsonOnly}`); ToolsMain.ensureCanWrite(output, force); - await TilesetOperations.merge(inputs, output, force); + await TilesetOperations.merge(inputs, output, force, jsonOnly); logger.debug(`Executing merge DONE`); } diff --git a/src/cli/main.ts b/src/cli/main.ts index d5e41041..61477f78 100644 --- a/src/cli/main.ts +++ b/src/cli/main.ts @@ -257,7 +257,15 @@ function parseToolArgs(a: string[]) { .command( "merge", "Merge any number of tilesets together into a single tileset.", - { i: inputArrayDefinition, o: outputStringDefinition } + { + i: inputArrayDefinition, + o: outputStringDefinition, + jsonOnly: { + default: false, + description: "Whether to copy resources to output directory - tileset.json and tile contents", + type: "boolean", + }, + } ) .command( "upgrade", @@ -536,7 +544,8 @@ async function runCommand(command: string, toolArgs: any, optionArgs: any) { parsedOptionArgs ); } else if (command === "merge") { - await ToolsMain.merge(inputs, output, force); + const jsonOnly = toolArgs.jsonOnly === true; + await ToolsMain.merge(inputs, output, force, jsonOnly); } else if (command === "pipeline") { await ToolsMain.pipeline(input, force); } else if (command === "analyze") { diff --git a/src/tools/tilesetProcessing/TilesetMerger.ts b/src/tools/tilesetProcessing/TilesetMerger.ts index 7f640205..ee6ea0d5 100644 --- a/src/tools/tilesetProcessing/TilesetMerger.ts +++ b/src/tools/tilesetProcessing/TilesetMerger.ts @@ -72,6 +72,7 @@ export class TilesetMerger { * @param tilesetSourceNames - The tileset source names * @param tilesetTargetName - The tileset target name * @param overwrite - Whether target files should be overwritten + * @param jsonOnly - Whether to copy resources to output directory * @returns A promise that resolves when the process is finished * @throws TilesetError When the input could not be processed * @throws TilesetError When the output already exists @@ -80,7 +81,8 @@ export class TilesetMerger { async merge( tilesetSourceNames: string[], tilesetTargetName: string, - overwrite: boolean + overwrite: boolean, + jsonOnly: boolean ): Promise { // Create the sources and target for (const tilesetSourceName of tilesetSourceNames) { @@ -106,7 +108,11 @@ export class TilesetMerger { const tilesetSource = TilesetSources.createAndOpen(tilesetSourceName); this.tilesetSources.push(tilesetSource); this.tilesetSourceJsonFileNames.push(tilesetSourceJsonFileName); - this.tilesetSourceIdentifiers.push(tilesetSourceIdentifier); + this.tilesetSourceIdentifiers.push( + !jsonOnly ? + tilesetSourceIdentifier : + tilesetSourceName + ); } this.tilesetTargetJsonFileName = @@ -117,7 +123,7 @@ export class TilesetMerger { ); // Perform the actual merge - this.mergeInternal(); + this.mergeInternal(jsonOnly); // Clean up by closing the sources and the target for (const tilesetSource of this.tilesetSources) { @@ -134,7 +140,7 @@ export class TilesetMerger { /** * Internal method for `merge` */ - private mergeInternal() { + private mergeInternal(jsonOnly: boolean) { if ( this.tilesetSources.length == 0 || !this.tilesetTarget || @@ -192,7 +198,8 @@ export class TilesetMerger { ); // Copy the resources from the sources to the target - this.copyResources(); + if (!jsonOnly) + this.copyResources(); } /** diff --git a/src/tools/tilesetProcessing/TilesetOperations.ts b/src/tools/tilesetProcessing/TilesetOperations.ts index f05e4687..35770543 100644 --- a/src/tools/tilesetProcessing/TilesetOperations.ts +++ b/src/tools/tilesetProcessing/TilesetOperations.ts @@ -48,6 +48,7 @@ export class TilesetOperations { * @param tilesetTargetName - The tileset target name * @param overwrite - Whether the target should be overwritten if * it already exists + * @param jsonOnly - Whether to copy resources to output directory * @returns A promise that resolves when the process is finished * @throws TilesetError When the input could not be processed, * or when the output already exists and `overwrite` was `false`. @@ -55,10 +56,11 @@ export class TilesetOperations { static async merge( tilesetSourceNames: string[], tilesetTargetName: string, - overwrite: boolean + overwrite: boolean, + jsonOnly: boolean ): Promise { const tilesetMerger = new TilesetMerger(); - await tilesetMerger.merge(tilesetSourceNames, tilesetTargetName, overwrite); + await tilesetMerger.merge(tilesetSourceNames, tilesetTargetName, overwrite, jsonOnly); } /** From 80c87415299fd94e0c836f9edb4485e0a903e62e Mon Sep 17 00:00:00 2001 From: Jonathan Chemla Date: Thu, 4 Jul 2024 18:41:11 +0200 Subject: [PATCH 2/7] Run Prettier Need to convert CRLF to LF endings --- src/cli/ToolsMain.ts | 7 ++++++- src/cli/main.ts | 9 +++++---- src/tools/tilesetProcessing/TilesetMerger.ts | 9 +++------ src/tools/tilesetProcessing/TilesetOperations.ts | 9 +++++++-- 4 files changed, 21 insertions(+), 13 deletions(-) diff --git a/src/cli/ToolsMain.ts b/src/cli/ToolsMain.ts index 2ad2252d..afa16eba 100644 --- a/src/cli/ToolsMain.ts +++ b/src/cli/ToolsMain.ts @@ -553,7 +553,12 @@ export class ToolsMain { logger.debug(`Executing upgrade DONE`); } - static async merge(inputs: string[], output: string, force: boolean, jsonOnly: boolean) { + static async merge( + inputs: string[], + output: string, + force: boolean, + jsonOnly: boolean + ) { logger.debug(`Executing merge`); logger.debug(` inputs: ${inputs}`); logger.debug(` output: ${output}`); diff --git a/src/cli/main.ts b/src/cli/main.ts index 61477f78..bd5c6846 100644 --- a/src/cli/main.ts +++ b/src/cli/main.ts @@ -257,12 +257,13 @@ function parseToolArgs(a: string[]) { .command( "merge", "Merge any number of tilesets together into a single tileset.", - { - i: inputArrayDefinition, - o: outputStringDefinition, + { + i: inputArrayDefinition, + o: outputStringDefinition, jsonOnly: { default: false, - description: "Whether to copy resources to output directory - tileset.json and tile contents", + description: + "Whether to copy resources to output directory - tileset.json and tile contents", type: "boolean", }, } diff --git a/src/tools/tilesetProcessing/TilesetMerger.ts b/src/tools/tilesetProcessing/TilesetMerger.ts index ee6ea0d5..e85d2290 100644 --- a/src/tools/tilesetProcessing/TilesetMerger.ts +++ b/src/tools/tilesetProcessing/TilesetMerger.ts @@ -72,7 +72,7 @@ export class TilesetMerger { * @param tilesetSourceNames - The tileset source names * @param tilesetTargetName - The tileset target name * @param overwrite - Whether target files should be overwritten - * @param jsonOnly - Whether to copy resources to output directory + * @param jsonOnly - Whether to copy resources to output directory * @returns A promise that resolves when the process is finished * @throws TilesetError When the input could not be processed * @throws TilesetError When the output already exists @@ -109,9 +109,7 @@ export class TilesetMerger { this.tilesetSources.push(tilesetSource); this.tilesetSourceJsonFileNames.push(tilesetSourceJsonFileName); this.tilesetSourceIdentifiers.push( - !jsonOnly ? - tilesetSourceIdentifier : - tilesetSourceName + !jsonOnly ? tilesetSourceIdentifier : tilesetSourceName ); } @@ -198,8 +196,7 @@ export class TilesetMerger { ); // Copy the resources from the sources to the target - if (!jsonOnly) - this.copyResources(); + if (!jsonOnly) this.copyResources(); } /** diff --git a/src/tools/tilesetProcessing/TilesetOperations.ts b/src/tools/tilesetProcessing/TilesetOperations.ts index 35770543..f6b7ea01 100644 --- a/src/tools/tilesetProcessing/TilesetOperations.ts +++ b/src/tools/tilesetProcessing/TilesetOperations.ts @@ -48,7 +48,7 @@ export class TilesetOperations { * @param tilesetTargetName - The tileset target name * @param overwrite - Whether the target should be overwritten if * it already exists - * @param jsonOnly - Whether to copy resources to output directory + * @param jsonOnly - Whether to copy resources to output directory * @returns A promise that resolves when the process is finished * @throws TilesetError When the input could not be processed, * or when the output already exists and `overwrite` was `false`. @@ -60,7 +60,12 @@ export class TilesetOperations { jsonOnly: boolean ): Promise { const tilesetMerger = new TilesetMerger(); - await tilesetMerger.merge(tilesetSourceNames, tilesetTargetName, overwrite, jsonOnly); + await tilesetMerger.merge( + tilesetSourceNames, + tilesetTargetName, + overwrite, + jsonOnly + ); } /** From fe33e6ca26fdce09cb6410cec2f349d3296ac886 Mon Sep 17 00:00:00 2001 From: Jonathan Chemla Date: Thu, 4 Jul 2024 18:51:20 +0200 Subject: [PATCH 3/7] Update spec test for TilesetMergerSpec.ts --- specs/tools/tilesetProcessing/TilesetMergerSpec.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/specs/tools/tilesetProcessing/TilesetMergerSpec.ts b/specs/tools/tilesetProcessing/TilesetMergerSpec.ts index d7a6c54c..91cc4e89 100644 --- a/specs/tools/tilesetProcessing/TilesetMergerSpec.ts +++ b/specs/tools/tilesetProcessing/TilesetMergerSpec.ts @@ -15,6 +15,7 @@ const basicInputs = [ const basicOutput = SPECS_DATA_BASE_DIRECTORY + "/output/mergeTilesets/basicMerge"; const overwrite = true; +const jsonOnly = false; describe("TilesetMerger", function () { afterEach(function () { @@ -24,7 +25,7 @@ describe("TilesetMerger", function () { }); it("merges tilesets into a single tileset", async function () { - await TilesetOperations.merge(basicInputs, basicOutput, overwrite); + await TilesetOperations.merge(basicInputs, basicOutput, overwrite, jsonOnly); // Ensure that the output directory contains the expected files: // All files of the input, disambiguated for the same base name From a6830d9b134157d099223a9bc79f5d8b09e8b784 Mon Sep 17 00:00:00 2001 From: Jonathan Chemla Date: Thu, 4 Jul 2024 18:53:08 +0200 Subject: [PATCH 4/7] Prettier on TilesetMergerSpec --- specs/tools/tilesetProcessing/TilesetMergerSpec.ts | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/specs/tools/tilesetProcessing/TilesetMergerSpec.ts b/specs/tools/tilesetProcessing/TilesetMergerSpec.ts index 91cc4e89..44e74a30 100644 --- a/specs/tools/tilesetProcessing/TilesetMergerSpec.ts +++ b/specs/tools/tilesetProcessing/TilesetMergerSpec.ts @@ -25,7 +25,12 @@ describe("TilesetMerger", function () { }); it("merges tilesets into a single tileset", async function () { - await TilesetOperations.merge(basicInputs, basicOutput, overwrite, jsonOnly); + await TilesetOperations.merge( + basicInputs, + basicOutput, + overwrite, + jsonOnly + ); // Ensure that the output directory contains the expected files: // All files of the input, disambiguated for the same base name From 8e5829b79e47a12d6512a5db9bc8380cfa19bab7 Mon Sep 17 00:00:00 2001 From: Jonathan Chemla Date: Fri, 5 Jul 2024 10:40:10 +0200 Subject: [PATCH 5/7] Break out `merge` and `mergeJson` each into its own CLI method rather than using a `--jsonOnly` flag --- .../tilesetProcessing/TilesetMergerSpec.ts | 38 ++++++++++++++-- src/cli/ToolsMain.ts | 22 ++++++---- src/cli/main.ts | 19 ++++---- src/tools/tilesetProcessing/TilesetMerger.ts | 44 ++++++++++++++++++- .../tilesetProcessing/TilesetOperations.ts | 29 +++++++++--- 5 files changed, 126 insertions(+), 26 deletions(-) diff --git a/specs/tools/tilesetProcessing/TilesetMergerSpec.ts b/specs/tools/tilesetProcessing/TilesetMergerSpec.ts index 44e74a30..8e4cde90 100644 --- a/specs/tools/tilesetProcessing/TilesetMergerSpec.ts +++ b/specs/tools/tilesetProcessing/TilesetMergerSpec.ts @@ -15,7 +15,6 @@ const basicInputs = [ const basicOutput = SPECS_DATA_BASE_DIRECTORY + "/output/mergeTilesets/basicMerge"; const overwrite = true; -const jsonOnly = false; describe("TilesetMerger", function () { afterEach(function () { @@ -28,8 +27,7 @@ describe("TilesetMerger", function () { await TilesetOperations.merge( basicInputs, basicOutput, - overwrite, - jsonOnly + overwrite ); // Ensure that the output directory contains the expected files: @@ -73,4 +71,38 @@ describe("TilesetMerger", function () { ]; expect(actualContentUris).toEqual(expectedContentUris); }); + + it("merges tilesets into a single tileset for mergeJson", async function () { + await TilesetOperations.mergeJson( + basicInputs, + basicOutput, + overwrite + ); + + // Ensure that the output directory contains the expected files: + const actualRelativeFiles = + SpecHelpers.collectRelativeFileNames(basicOutput); + actualRelativeFiles.sort(); + const expectedRelativeFiles = [ + "tileset.json", + ]; + expect(actualRelativeFiles).toEqual(expectedRelativeFiles); + + // Ensure that the single 'tileset.json' contains the + // proper content URIs for the external tilesets: + const tilesetJsonBuffer = fs.readFileSync( + Paths.join(basicOutput, "tileset.json") + ); + const tileset = JSON.parse(tilesetJsonBuffer.toString()); + const actualContentUris = await SpecHelpers.collectExplicitContentUris( + tileset.root + ); + actualContentUris.sort(); + + const expectedContentUris = [ + "specs/data/mergeTilesets/basicMerge/TilesetA/tileset.json", + "specs/data/mergeTilesets/basicMerge/sub/TilesetA/tileset.json", + ]; + expect(actualContentUris).toEqual(expectedContentUris); + }); }); diff --git a/src/cli/ToolsMain.ts b/src/cli/ToolsMain.ts index afa16eba..72fcb862 100644 --- a/src/cli/ToolsMain.ts +++ b/src/cli/ToolsMain.ts @@ -553,20 +553,26 @@ export class ToolsMain { logger.debug(`Executing upgrade DONE`); } - static async merge( - inputs: string[], - output: string, - force: boolean, - jsonOnly: boolean - ) { + static async merge(inputs: string[], output: string, force: boolean) { logger.debug(`Executing merge`); logger.debug(` inputs: ${inputs}`); logger.debug(` output: ${output}`); logger.debug(` force: ${force}`); - logger.debug(` jsonOnly: ${jsonOnly}`); ToolsMain.ensureCanWrite(output, force); - await TilesetOperations.merge(inputs, output, force, jsonOnly); + await TilesetOperations.merge(inputs, output, force); + + logger.debug(`Executing merge DONE`); + } + + static async mergeJson(inputs: string[], output: string, force: boolean) { + logger.debug(`Executing mergeJson`); + logger.debug(` inputs: ${inputs}`); + logger.debug(` output: ${output}`); + logger.debug(` force: ${force}`); + + ToolsMain.ensureCanWrite(output, force); + await TilesetOperations.mergeJson(inputs, output, force); logger.debug(`Executing merge DONE`); } diff --git a/src/cli/main.ts b/src/cli/main.ts index bd5c6846..337dfadb 100644 --- a/src/cli/main.ts +++ b/src/cli/main.ts @@ -260,12 +260,14 @@ function parseToolArgs(a: string[]) { { i: inputArrayDefinition, o: outputStringDefinition, - jsonOnly: { - default: false, - description: - "Whether to copy resources to output directory - tileset.json and tile contents", - type: "boolean", - }, + } + ) + .command( + "mergeJson", + "Merge any number of tilesets together into a single tileset without copying resources to output directory.", + { + i: inputArrayDefinition, + o: outputStringDefinition, } ) .command( @@ -545,8 +547,9 @@ async function runCommand(command: string, toolArgs: any, optionArgs: any) { parsedOptionArgs ); } else if (command === "merge") { - const jsonOnly = toolArgs.jsonOnly === true; - await ToolsMain.merge(inputs, output, force, jsonOnly); + await ToolsMain.merge(inputs, output, force); + } else if (command === "mergeJson") { + await ToolsMain.mergeJson(inputs, output, force); } else if (command === "pipeline") { await ToolsMain.pipeline(input, force); } else if (command === "analyze") { diff --git a/src/tools/tilesetProcessing/TilesetMerger.ts b/src/tools/tilesetProcessing/TilesetMerger.ts index e85d2290..1cf7d9ef 100644 --- a/src/tools/tilesetProcessing/TilesetMerger.ts +++ b/src/tools/tilesetProcessing/TilesetMerger.ts @@ -72,13 +72,55 @@ export class TilesetMerger { * @param tilesetSourceNames - The tileset source names * @param tilesetTargetName - The tileset target name * @param overwrite - Whether target files should be overwritten - * @param jsonOnly - Whether to copy resources to output directory * @returns A promise that resolves when the process is finished * @throws TilesetError When the input could not be processed * @throws TilesetError When the output already exists * and `overwrite` was `false`. */ async merge( + tilesetSourceNames: string[], + tilesetTargetName: string, + overwrite: boolean + ): Promise { + return this.mergeOperation( + tilesetSourceNames, + tilesetTargetName, + overwrite, + false + ); + } + + /** + * Merges the tileset from the specified sources into one tileset + * that refers to the sources as external ones, and writes the + * result into the given target without copying resources to + * output directory. + * + * @param tilesetSourceNames - The tileset source names + * @param tilesetTargetName - The tileset target name + * @param overwrite - Whether target files should be overwritten + * @returns A promise that resolves when the process is finished + * @throws TilesetError When the input could not be processed + * @throws TilesetError When the output already exists + * and `overwrite` was `false`. + */ + async mergeJson( + tilesetSourceNames: string[], + tilesetTargetName: string, + overwrite: boolean + ): Promise { + return this.mergeOperation( + tilesetSourceNames, + tilesetTargetName, + overwrite, + true + ); + } + + /** + * Internal method to differentiate between `merge` and `mergeJson` + */ + async mergeOperation( tilesetSourceNames: string[], tilesetTargetName: string, overwrite: boolean, diff --git a/src/tools/tilesetProcessing/TilesetOperations.ts b/src/tools/tilesetProcessing/TilesetOperations.ts index f6b7ea01..892878ac 100644 --- a/src/tools/tilesetProcessing/TilesetOperations.ts +++ b/src/tools/tilesetProcessing/TilesetOperations.ts @@ -48,7 +48,6 @@ export class TilesetOperations { * @param tilesetTargetName - The tileset target name * @param overwrite - Whether the target should be overwritten if * it already exists - * @param jsonOnly - Whether to copy resources to output directory * @returns A promise that resolves when the process is finished * @throws TilesetError When the input could not be processed, * or when the output already exists and `overwrite` was `false`. @@ -56,15 +55,33 @@ export class TilesetOperations { static async merge( tilesetSourceNames: string[], tilesetTargetName: string, - overwrite: boolean, - jsonOnly: boolean + overwrite: boolean + ): Promise { + const tilesetMerger = new TilesetMerger(); + await tilesetMerger.merge(tilesetSourceNames, tilesetTargetName, overwrite); + } + + /** + * Performs the `mergeJson` command line operation. + * + * @param tilesetSourceName - The tileset source name + * @param tilesetTargetName - The tileset target name + * @param overwrite - Whether the target should be overwritten if + * it already exists + * @returns A promise that resolves when the process is finished + * @throws TilesetError When the input could not be processed, + * or when the output already exists and `overwrite` was `false`. + */ + static async mergeJson( + tilesetSourceNames: string[], + tilesetTargetName: string, + overwrite: boolean ): Promise { const tilesetMerger = new TilesetMerger(); - await tilesetMerger.merge( + await tilesetMerger.mergeJson( tilesetSourceNames, tilesetTargetName, - overwrite, - jsonOnly + overwrite ); } From 573afc45dfa6d4338b8e9eb757e35d962e99ecb7 Mon Sep 17 00:00:00 2001 From: Jonathan Chemla Date: Fri, 5 Jul 2024 10:41:48 +0200 Subject: [PATCH 6/7] Prettier on TilesetMergerSpec --- package.json | 4 ++-- .../tools/tilesetProcessing/TilesetMergerSpec.ts | 16 +++------------- 2 files changed, 5 insertions(+), 15 deletions(-) diff --git a/package.json b/package.json index 7b1ac2be..cbcc9233 100644 --- a/package.json +++ b/package.json @@ -94,7 +94,7 @@ "test": "npx ts-node node_modules/jasmine/bin/jasmine.js --config=specs/jasmine.json", "coverage": "npx c8 --clean npm run test", "prettier-check": "prettier --check \"**/*\"", - "prettier": "prettier --write \"**/*\"", + "prettier": "prettier --end-of-line lf --write \"**/*\"", "generate-third-party": "node generateThirdParty.js", "docs-prepare-directory": "mkdirp etc", "docs-extract-api": "api-extractor run --config api-extractor.jsonc --local --verbose", @@ -105,4 +105,4 @@ "package-prepare": "npm run eslint && npm run prettier-check && npm run build && npm run test && npm run coverage && npm run docs-generate && npm run generate-third-party", "package": "npm run package-clean && npm run package-prepare && npm pack" } -} +} \ No newline at end of file diff --git a/specs/tools/tilesetProcessing/TilesetMergerSpec.ts b/specs/tools/tilesetProcessing/TilesetMergerSpec.ts index 8e4cde90..bd7467e8 100644 --- a/specs/tools/tilesetProcessing/TilesetMergerSpec.ts +++ b/specs/tools/tilesetProcessing/TilesetMergerSpec.ts @@ -24,11 +24,7 @@ describe("TilesetMerger", function () { }); it("merges tilesets into a single tileset", async function () { - await TilesetOperations.merge( - basicInputs, - basicOutput, - overwrite - ); + await TilesetOperations.merge(basicInputs, basicOutput, overwrite); // Ensure that the output directory contains the expected files: // All files of the input, disambiguated for the same base name @@ -73,19 +69,13 @@ describe("TilesetMerger", function () { }); it("merges tilesets into a single tileset for mergeJson", async function () { - await TilesetOperations.mergeJson( - basicInputs, - basicOutput, - overwrite - ); + await TilesetOperations.mergeJson(basicInputs, basicOutput, overwrite); // Ensure that the output directory contains the expected files: const actualRelativeFiles = SpecHelpers.collectRelativeFileNames(basicOutput); actualRelativeFiles.sort(); - const expectedRelativeFiles = [ - "tileset.json", - ]; + const expectedRelativeFiles = ["tileset.json"]; expect(actualRelativeFiles).toEqual(expectedRelativeFiles); // Ensure that the single 'tileset.json' contains the From 903bd2c37e4b57d1040072bb4a0fc7815da425c2 Mon Sep 17 00:00:00 2001 From: Jonathan Chemla Date: Fri, 5 Jul 2024 14:02:31 +0200 Subject: [PATCH 7/7] Remove line-endings enforcing from prettier command in package.json --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index cbcc9233..b59e800e 100644 --- a/package.json +++ b/package.json @@ -94,7 +94,7 @@ "test": "npx ts-node node_modules/jasmine/bin/jasmine.js --config=specs/jasmine.json", "coverage": "npx c8 --clean npm run test", "prettier-check": "prettier --check \"**/*\"", - "prettier": "prettier --end-of-line lf --write \"**/*\"", + "prettier": "prettier --write \"**/*\"", "generate-third-party": "node generateThirdParty.js", "docs-prepare-directory": "mkdirp etc", "docs-extract-api": "api-extractor run --config api-extractor.jsonc --local --verbose",