91400: Fix for line indentation on empty lines

This commit is contained in:
Alexandre Vryghem
2022-05-26 09:53:07 +02:00
parent bb898022e3
commit d44253ea86

View File

@@ -1,4 +1,5 @@
import { projectRoot } from '../webpack/helpers';
const commander = require('commander');
const fs = require('fs');
const JSON5 = require('json5');
@@ -119,7 +120,7 @@ function syncFileWithSource(pathToTargetFile, pathToOutputFile) {
outputChunks.forEach(function (chunk) {
progressBar.increment();
chunk.split("\n").forEach(function (line) {
file.write(" " + line + "\n");
file.write((line === '' ? '' : ` ${line}`) + "\n");
});
});
file.write("\n}");