data-lessons / library-shell-DEPRECATED

Unix shell lesson for librarians NOW MOVED > https://github.com/LibraryCarpentry/lc-shell
https://github.com/LibraryCarpentry/lc-shell
Other
9 stars 19 forks source link

Deal with total line in exercise #78

Open mawds opened 6 years ago

mawds commented 6 years ago

The cut, sort and print faded example exercise in episode two doesn't take account of the "total" line that's output by wc when dealing with multiple files (and so would print the 9 biggest files and the total).

This PR deals with this by taking the final 11 lines of output, and then using head -n 10 to remove the total line. This may introduce too much complexity; I'm happy to rework to instruct learners to ignore the total line if that's preferable.