Skip to content

Commit

Permalink
Added file path space trimming
Browse files Browse the repository at this point in the history
Added file path space trimming to avoid copy paste fails.
Example: microsoft/vscode#40760
  • Loading branch information
mxschmitt authored Dec 23, 2017
1 parent 69764b3 commit ebbbbcb
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion generators/app/grammarConverter.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ function convertGrammar(location, extensionConfig) {
} else {
// load from disk
var body = null;
// trim the spaces of the location path
location = location.trim()
try {
body = fs.readFileSync(location);
} catch (error) {
Expand Down Expand Up @@ -107,4 +109,4 @@ function processContent(extensionConfig, fileName, body) {
extensionConfig.languageContent = body;
};

exports.convertGrammar = convertGrammar;
exports.convertGrammar = convertGrammar;

0 comments on commit ebbbbcb

Please sign in to comment.