cli: put a newline character at the end of grammar.json files
This commit is contained in:
parent
d19c875134
commit
2de54c101e
1 changed files with 3 additions and 1 deletions
|
|
@ -143,7 +143,9 @@ fn load_js_grammar_file(grammar_path: &Path) -> Result<String> {
|
|||
Some(code) => return Err(Error(format!("Node process exited with status {}", code))),
|
||||
}
|
||||
|
||||
Ok(String::from_utf8(output.stdout).expect("Got invalid UTF8 from node"))
|
||||
let mut result = String::from_utf8(output.stdout).expect("Got invalid UTF8 from node");
|
||||
result.push('\n');
|
||||
Ok(result)
|
||||
}
|
||||
|
||||
fn ensure_file<T: AsRef<[u8]>>(path: &PathBuf, f: impl Fn() -> T) -> Result<()> {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue