Skip to content

Commit 5e36e1f

Browse files
committed
fix: cat line numbering is per file, not on the concatanation of files
1 parent 98c1c43 commit 5e36e1f

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

  • implement-shell-tools/cat

implement-shell-tools/cat/cat.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,9 @@ if (paths.length === 0) {
2626
}
2727

2828
// starting file number, if lines need to be prepended
29-
let lineNum = 1;
3029

3130
for (const path of paths) {
31+
let lineNum = 1;
3232
let file;
3333
try {
3434
// using sync as it's a simple short program

0 commit comments

Comments
 (0)