Skip to content
This repository has been archived by the owner on Dec 23, 2021. It is now read-only.

Commit

Permalink
removed unecessary whitespace diffs
Browse files Browse the repository at this point in the history
  • Loading branch information
andreamah committed Mar 17, 2020
1 parent 520fec4 commit 0ec5989
Show file tree
Hide file tree
Showing 4 changed files with 511 additions and 511 deletions.
160 changes: 80 additions & 80 deletions gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,122 +23,122 @@ const outDest = "out";
const languages = [{ folderName: "en", id: "en" }];

gulp.task("clean", () => {
return del(
[
"out/*",
"package.nls.*.json",
"../../dist/*0.0.0-UNTRACKEDVERSION.vsix",
],
{ force: true }
);
return del(
[
"out/*",
"package.nls.*.json",
"../../dist/*0.0.0-UNTRACKEDVERSION.vsix",
],
{ force: true }
);
});

const pythonToMove = [
"./src/adafruit_circuitplayground/*.*",
"./src/microbit/*.*",
"./src/microbit/!(test)/**/*",
"./src/clue/*.*",
"./src/clue/!(test)/**/*",
"./src/*.py",
"./src/common/*.py",
"./src/dev-requirements.txt",
"./src/requirements.txt",
"./src/templates/*.*",
"./src/*.sh"
"./src/adafruit_circuitplayground/*.*",
"./src/microbit/*.*",
"./src/microbit/!(test)/**/*",
"./src/clue/*.*",
"./src/clue/!(test)/**/*",
"./src/*.py",
"./src/common/*.py",
"./src/dev-requirements.txt",
"./src/requirements.txt",
"./src/templates/*.*",
"./src/*.sh"
];

gulp.task("python-compile", () => {
// the base option sets the relative root for the set of files,
// preserving the folder structure
return gulp.src(pythonToMove, { base: "./src/" }).pipe(gulp.dest("out"));
// the base option sets the relative root for the set of files,
// preserving the folder structure
return gulp.src(pythonToMove, { base: "./src/" }).pipe(gulp.dest("out"));
});

gulp.task("internal-compile", () => {
return compile(false);
return compile(false);
});

gulp.task("internal-nls-compile", () => {
return compile(true);
return compile(true);
});

gulp.task("add-locales", () => {
return gulp
.src(["package.nls.json"])
.pipe(nls.createAdditionalLanguageFiles(languages, "locales"))
.pipe(gulp.dest("."));
return gulp
.src(["package.nls.json"])
.pipe(nls.createAdditionalLanguageFiles(languages, "locales"))
.pipe(gulp.dest("."));
});

gulp.task("vsce:publish", () => {
return vsce.publish();
return vsce.publish();
});

gulp.task("vsce:package", () => {
return vsce.createVSIX({
packagePath:
"../../dist/deviceSimulatorExpress-0.0.0-UNTRACKEDVERSION.vsix",
});
return vsce.createVSIX({
packagePath:
"../../dist/deviceSimulatorExpress-0.0.0-UNTRACKEDVERSION.vsix",
});
});

gulp.task(
"compile",
gulp.series("clean", "internal-compile", "python-compile", callback => {
callback();
})
"compile",
gulp.series("clean", "internal-compile", "python-compile", callback => {
callback();
})
);

gulp.task(
"build",
gulp.series(
"clean",
"internal-nls-compile",
"python-compile",
"add-locales",
callback => {
callback();
}
)
"build",
gulp.series(
"clean",
"internal-nls-compile",
"python-compile",
"add-locales",
callback => {
callback();
}
)
);

gulp.task(
"publish",
gulp.series("compile", "vsce:publish", callback => {
callback();
})
"publish",
gulp.series("compile", "vsce:publish", callback => {
callback();
})
);

gulp.task(
"package",
gulp.series("compile", "vsce:package", callback => {
callback();
})
"package",
gulp.series("compile", "vsce:package", callback => {
callback();
})
);

//---- internal

function compile(buildNls) {
var r = tsProject
.src()
.pipe(sourcemaps.init())
.pipe(tsProject())
.js.pipe(buildNls ? nls.rewriteLocalizeCalls() : es.through())
.pipe(
buildNls
? nls.createAdditionalLanguageFiles(languages, "locales", "out")
: es.through()
);

if (inlineMap && inlineSource) {
r = r.pipe(sourcemaps.write());
} else {
r = r.pipe(
sourcemaps.write("../out", {
// no inlined source
includeContent: inlineSource,
// Return relative source map root directories per file.
sourceRoot: "../src",
})
);
}

return r.pipe(gulp.dest(outDest));
var r = tsProject
.src()
.pipe(sourcemaps.init())
.pipe(tsProject())
.js.pipe(buildNls ? nls.rewriteLocalizeCalls() : es.through())
.pipe(
buildNls
? nls.createAdditionalLanguageFiles(languages, "locales", "out")
: es.through()
);

if (inlineMap && inlineSource) {
r = r.pipe(sourcemaps.write());
} else {
r = r.pipe(
sourcemaps.write("../out", {
// no inlined source
includeContent: inlineSource,
// Return relative source map root directories per file.
sourceRoot: "../src",
})
);
}

return r.pipe(gulp.dest(outDest));
}
42 changes: 21 additions & 21 deletions locales/en/package.i18n.json
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
{
"deviceSimulatorExpressExtension.commands.common.installDependencies": "Install Extension Dependencies",
"deviceSimulatorExpressExtension.commands.common.label": "Device Simulator Express",
"deviceSimulatorExpressExtension.commands.common.runSimulator": "Run Simulator",
"deviceSimulatorExpressExtension.commands.common.changeBaudRate": "Change Baud Rate",
"deviceSimulatorExpressExtension.commands.common.closeSerialMonitor": "Close Serial Monitor",
"deviceSimulatorExpressExtension.commands.common.openSerialMonitor": "Open Serial Monitor",
"deviceSimulatorExpressExtension.commands.common.selectSerialPort": "Select Serial Port",
"deviceSimulatorExpressExtension.commands.cpx.openSimulator": "[Circuit Playground Express] Open Simulator",
"deviceSimulatorExpressExtension.commands.cpx.newFile": "[Circuit Playground Express] New File",
"deviceSimulatorExpressExtension.commands.cpx.deployToDevice": "[Circuit Playground Express] Deploy to Device",
"deviceSimulatorExpressExtension.commands.microbit.deployToDevice": "[micro:bit] Deploy to Device",
"deviceSimulatorExpressExtension.commands.microbit.openSimulator": "[micro:bit] Open Simulator",
"deviceSimulatorExpressExtension.commands.microbit.newFile": "[micro:bit] New File",
"deviceSimulatorExpressExtension.commands.clue.openSimulator": "[Clue] Open Simulator",
"deviceSimulatorExpressExtension.commands.clue.newFile": "[Clue] New File",
"deviceSimulatorExpressExtension.configuration.title": "Device Simulator Express configuration",
"deviceSimulatorExpressExtension.configuration.properties.configEnvOnChange": "When you change the Python interpreter, the Device Simulator Express will automatically configure itself for the required dependencies.",
"deviceSimulatorExpressExtension.configuration.properties.debuggerPort": "The port the Server will listen on for communication with the debugger.",
"deviceSimulatorExpressExtension.configuration.properties.dependencyChecker": "Whether or not to ask if we can download dependencies. If unchecked, the extension will default to never download dependencies, except when automatically creating a virtual environment in the extension files.",
"deviceSimulatorExpressExtension.configuration.properties.previewMode": "Enable this to test out and play with the new micro:bit simulator!"
}
"deviceSimulatorExpressExtension.commands.common.installDependencies": "Install Extension Dependencies",
"deviceSimulatorExpressExtension.commands.common.label": "Device Simulator Express",
"deviceSimulatorExpressExtension.commands.common.runSimulator": "Run Simulator",
"deviceSimulatorExpressExtension.commands.common.changeBaudRate": "Change Baud Rate",
"deviceSimulatorExpressExtension.commands.common.closeSerialMonitor": "Close Serial Monitor",
"deviceSimulatorExpressExtension.commands.common.openSerialMonitor": "Open Serial Monitor",
"deviceSimulatorExpressExtension.commands.common.selectSerialPort": "Select Serial Port",
"deviceSimulatorExpressExtension.commands.cpx.openSimulator": "[Circuit Playground Express] Open Simulator",
"deviceSimulatorExpressExtension.commands.cpx.newFile": "[Circuit Playground Express] New File",
"deviceSimulatorExpressExtension.commands.cpx.deployToDevice": "[Circuit Playground Express] Deploy to Device",
"deviceSimulatorExpressExtension.commands.microbit.deployToDevice": "[micro:bit] Deploy to Device",
"deviceSimulatorExpressExtension.commands.microbit.openSimulator": "[micro:bit] Open Simulator",
"deviceSimulatorExpressExtension.commands.microbit.newFile": "[micro:bit] New File",
"deviceSimulatorExpressExtension.commands.clue.openSimulator": "[Clue] Open Simulator",
"deviceSimulatorExpressExtension.commands.clue.newFile": "[Clue] New File",
"deviceSimulatorExpressExtension.configuration.title": "Device Simulator Express configuration",
"deviceSimulatorExpressExtension.configuration.properties.configEnvOnChange": "When you change the Python interpreter, the Device Simulator Express will automatically configure itself for the required dependencies.",
"deviceSimulatorExpressExtension.configuration.properties.debuggerPort": "The port the Server will listen on for communication with the debugger.",
"deviceSimulatorExpressExtension.configuration.properties.dependencyChecker": "Whether or not to ask if we can download dependencies. If unchecked, the extension will default to never download dependencies, except when automatically creating a virtual environment in the extension files.",
"deviceSimulatorExpressExtension.configuration.properties.previewMode": "Enable this to test out and play with the new micro:bit simulator!"
}
Loading

0 comments on commit 0ec5989

Please sign in to comment.