From 7c327798923f5a797319c379c875d09f800150d4 Mon Sep 17 00:00:00 2001 From: Benson Muite Date: Mon, 13 Feb 2023 16:37:23 +0300 Subject: [PATCH] Do not overwrite a file that is used later Make a copy of the file. --- _episodes/04-pipefilter.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/_episodes/04-pipefilter.md b/_episodes/04-pipefilter.md index 53999df81..485635cee 100644 --- a/_episodes/04-pipefilter.md +++ b/_episodes/04-pipefilter.md @@ -286,7 +286,8 @@ the output of `head` must be the file with the fewest lines. > to the same file. For example: > > ~~~ -> $ sort -n lengths.txt > lengths.txt +> $ cp lengths.txt lengths-copy.txt +> $ sort -n lengths-copy.txt > lengths-copy.txt > ~~~ > {: .language-bash} >