diff --git a/build/gulpfile.editor.js b/build/gulpfile.editor.js index 938c82f57beab64752fca026b5a6e4c9c6070751..7f52fbff35510fde884ac2484cf42c7c972a1f9e 100644 --- a/build/gulpfile.editor.js +++ b/build/gulpfile.editor.js @@ -17,14 +17,14 @@ const compilation = require('./lib/compilation'); const monacoapi = require('./monaco/api'); const fs = require('fs'); -var root = path.dirname(__dirname); -var sha1 = util.getVersion(root); -var semver = require('./monaco/package.json').version; -var headerVersion = semver + '(' + sha1 + ')'; +let root = path.dirname(__dirname); +let sha1 = util.getVersion(root); +let semver = require('./monaco/package.json').version; +let headerVersion = semver + '(' + sha1 + ')'; // Build -var editorEntryPoints = [ +let editorEntryPoints = [ { name: 'vs/editor/editor.main', include: [], @@ -40,11 +40,11 @@ var editorEntryPoints = [ } ]; -var editorResources = [ +let editorResources = [ 'out-editor-build/vs/base/browser/ui/codiconLabel/**/*.ttf' ]; -var BUNDLED_FILE_HEADER = [ +let BUNDLED_FILE_HEADER = [ '/*!-----------------------------------------------------------', ' * Copyright (c) Microsoft Corporation. All rights reserved.', ' * Version: ' + headerVersion, @@ -263,7 +263,7 @@ const finalEditorResourcesTask = task.define('final-editor-resources', () => { // package.json gulp.src('build/monaco/package.json') .pipe(es.through(function (data) { - var json = JSON.parse(data.contents.toString()); + let json = JSON.parse(data.contents.toString()); json.private = false; data.contents = Buffer.from(JSON.stringify(json, null, ' ')); this.emit('data', data); @@ -307,10 +307,10 @@ const finalEditorResourcesTask = task.define('final-editor-resources', () => { return; } - var relativePathToMap = path.relative(path.join(data.relative), path.join('min-maps', data.relative + '.map')); + let relativePathToMap = path.relative(path.join(data.relative), path.join('min-maps', data.relative + '.map')); - var strContents = data.contents.toString(); - var newStr = '//# sourceMappingURL=' + relativePathToMap.replace(/\\/g, '/'); + let strContents = data.contents.toString(); + let newStr = '//# sourceMappingURL=' + relativePathToMap.replace(/\\/g, '/'); strContents = strContents.replace(/\/\/# sourceMappingURL=[^ ]+$/, newStr); data.contents = Buffer.from(strContents); diff --git a/build/gulpfile.reh.js b/build/gulpfile.reh.js index a956fba979ef6563ac47fe0b355006df9c5cb891..f2ea1bd37010b1eb8a43ce9beaae4a88810f6e2d 100644 --- a/build/gulpfile.reh.js +++ b/build/gulpfile.reh.js @@ -118,7 +118,7 @@ function mixinServer(watch) { const packageJSONPath = path.join(path.dirname(__dirname), 'package.json'); function exec(cmdLine) { console.log(cmdLine); - cp.execSync(cmdLine, { stdio: "inherit" }); + cp.execSync(cmdLine, { stdio: 'inherit' }); } function checkout() { const packageJSON = JSON.parse(fs.readFileSync(packageJSONPath).toString()); diff --git a/build/gulpfile.vscode.js b/build/gulpfile.vscode.js index bb504fc09e97072a5d712a2143da2cec0855d1d0..4906bfdb1a24ce928c8362de33fb61a50bdfd211 100644 --- a/build/gulpfile.vscode.js +++ b/build/gulpfile.vscode.js @@ -121,9 +121,9 @@ gulp.task(minifyVSCodeTask); * @return {Object} A map of paths to checksums. */ function computeChecksums(out, filenames) { - var result = {}; + let result = {}; filenames.forEach(function (filename) { - var fullPath = path.join(process.cwd(), out, filename); + let fullPath = path.join(process.cwd(), out, filename); result[filename] = computeChecksum(fullPath); }); return result; @@ -136,9 +136,9 @@ function computeChecksums(out, filenames) { * @return {string} The checksum for `filename`. */ function computeChecksum(filename) { - var contents = fs.readFileSync(filename); + let contents = fs.readFileSync(filename); - var hash = crypto + let hash = crypto .createHash('md5') .update(contents) .digest('base64') @@ -428,7 +428,7 @@ gulp.task('vscode-translations-pull', function () { }); gulp.task('vscode-translations-import', function () { - var options = minimist(process.argv.slice(2), { + let options = minimist(process.argv.slice(2), { string: 'location', default: { location: '../vscode-translations-import' diff --git a/build/gulpfile.vscode.linux.js b/build/gulpfile.vscode.linux.js index 9d3a7caa07e683b571224c8bfcc86665d1c5a98a..51c7002f5b12cf82fbb82b3b9ccceb1bdf283a7f 100644 --- a/build/gulpfile.vscode.linux.js +++ b/build/gulpfile.vscode.linux.js @@ -23,7 +23,7 @@ const commit = util.getVersion(root); const linuxPackageRevision = Math.floor(new Date().getTime() / 1000); function getDebPackageArch(arch) { - return { x64: 'amd64', arm: 'armhf', arm64: "arm64" }[arch]; + return { x64: 'amd64', arm: 'armhf', arm64: 'arm64' }[arch]; } function prepareDebPackage(arch) { @@ -117,7 +117,7 @@ function getRpmBuildPath(rpmArch) { } function getRpmPackageArch(arch) { - return { x64: 'x86_64', arm: 'armhf', arm64: "arm64" }[arch]; + return { x64: 'x86_64', arm: 'armhf', arm64: 'arm64' }[arch]; } function prepareRpmPackage(arch) {