Answer the question
In order to leave comments, you need to log in
How to remove duplicate lines in a file?
There is a txt file with the history of terminal commands,
673 sudo mysql-workbanch
674 sudo mysql-workbench
675 poweroff
676 sudo mysql -u root -p
677 sudo mysql-workbench
678 poweroff
вывод sort -u
Answer the question
In order to leave comments, you need to log in
If a "manual" solution is suitable, then you can convert the test one to csv.
1. Replacing two spaces with ;
2. Change the resolution of the .csv file
3. Compare 2 columns in Libre Office Calc and remove repetitions
In principle, quickly done) And sorting and numbers are saved.
If sorting is not important, then as an option:sort history.txt | uniq -u
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question