We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8566cc4 commit 984e653Copy full SHA for 984e653
1 file changed
implement-shell-tools/cat/cat.js
@@ -11,7 +11,6 @@ let content = files.map(f => fs.readFileSync(f, "utf8")).join("");
11
12
let lines = content.split("\n");
13
14
-// remove ONLY final empty line caused by trailing newline
15
if (lines[lines.length - 1] === "") {
16
lines.pop();
17
}
@@ -38,5 +37,4 @@ if (showN) {
38
37
output = lines;
39
40
41
-// IMPORTANT: add final newline like real cat
42
process.stdout.write(output.join("\n") + "\n");
0 commit comments