langium-cli
Advanced tools
Comparing version 3.0.3 to 3.1.0-next.c8e01a2
@@ -47,5 +47,4 @@ /****************************************************************************** | ||
} | ||
else { | ||
console.log(`Langium generator finished ${chalk.green.bold('successfully')} in ${elapsedTime()}ms`); | ||
} | ||
// Outside of watch mode, report elapsed time for successful generation. | ||
printSuccess(result); | ||
return result.success; | ||
@@ -52,0 +51,0 @@ } |
@@ -34,5 +34,9 @@ /****************************************************************************** | ||
// We need to translate these line endings to the OS specific line ending | ||
const json = normalizeEOL(serializedGrammar | ||
let json = normalizeEOL(serializedGrammar | ||
.replace(/\\/g, '\\\\') | ||
.replace(new RegExp(delimiter, 'g'), '\\' + delimiter)); | ||
if (!production) { | ||
// Escape ${ in template strings | ||
json = json.replace(/\${/g, '\\${'); | ||
} | ||
return expandToNode ` | ||
@@ -39,0 +43,0 @@ |
@@ -18,3 +18,11 @@ /****************************************************************************** | ||
.action((options) => { | ||
generate(options).catch(err => { | ||
generate(options) | ||
.then(success => { | ||
if (!success) { | ||
process.exit(2); | ||
} | ||
else { | ||
process.exit(0); | ||
} | ||
}).catch(err => { | ||
console.error(err); | ||
@@ -21,0 +29,0 @@ process.exit(1); |
{ | ||
"name": "langium-cli", | ||
"version": "3.0.3", | ||
"version": "3.1.0-next.c8e01a2", | ||
"description": "CLI for Langium - the language engineering tool", | ||
@@ -50,4 +50,4 @@ "homepage": "https://langium.org", | ||
"jsonschema": "~1.4.1", | ||
"langium": "~3.0.0", | ||
"langium-railroad": "~3.0.0", | ||
"langium": "3.1.0-next.c8e01a2", | ||
"langium-railroad": "3.1.0-next.c8e01a2", | ||
"lodash": "~4.17.21" | ||
@@ -54,0 +54,0 @@ }, |
@@ -50,5 +50,5 @@ /****************************************************************************** | ||
await runWatcher(config, options, await allGeneratorFiles(result)); | ||
} else { | ||
console.log(`Langium generator finished ${chalk.green.bold('successfully')} in ${elapsedTime()}ms`); | ||
} | ||
// Outside of watch mode, report elapsed time for successful generation. | ||
printSuccess(result); | ||
return result.success; | ||
@@ -55,0 +55,0 @@ } |
@@ -44,5 +44,9 @@ /****************************************************************************** | ||
// We need to translate these line endings to the OS specific line ending | ||
const json = normalizeEOL(serializedGrammar | ||
let json = normalizeEOL(serializedGrammar | ||
.replace(/\\/g, '\\\\') | ||
.replace(new RegExp(delimiter, 'g'), '\\' + delimiter)); | ||
if (!production) { | ||
// Escape ${ in template strings | ||
json = json.replace(/\${/g, '\\${'); | ||
} | ||
return expandToNode` | ||
@@ -49,0 +53,0 @@ |
@@ -22,6 +22,14 @@ /****************************************************************************** | ||
.action((options: GenerateOptions) => { | ||
generate(options).catch(err => { | ||
console.error(err); | ||
process.exit(1); | ||
}); | ||
generate(options) | ||
.then(success => { | ||
if(!success) { | ||
process.exit(2); | ||
} | ||
else { | ||
process.exit(0); | ||
} | ||
}).catch(err => { | ||
console.error(err); | ||
process.exit(1); | ||
}); | ||
}); | ||
@@ -28,0 +36,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
Unidentified License
License(Experimental) Something that seems like a license was found, but its contents could not be matched with a known license.
Found 6 instances in 1 package
Unidentified License
License(Experimental) Something that seems like a license was found, but its contents could not be matched with a known license.
Found 6 instances in 1 package
243477
3862
1
+ Addedlangium@3.1.0-next.c8e01a2(transitive)
+ Addedlangium-railroad@3.1.0-next.c8e01a2(transitive)
- Removedlangium@3.0.0(transitive)
- Removedlangium-railroad@3.0.0(transitive)
Updatedlangium@3.1.0-next.c8e01a2