User Tools

Site Tools


ubuntu:file:remove_duplicate_lines_from_a_files

This is an old revision of the document!


Ubuntu - File - Remove Duplicate Lines from a files

#! /bin/sh
 
echo -n "Enter Filename-> "
read filename
if [ -f "$filename" ]; then
sort $filename | uniq | tee sorted.txt
else
echo "No $filename in $pwd...try again"
fi
 
exit 0
ubuntu/file/remove_duplicate_lines_from_a_files.1576615555.txt.gz · Last modified: 2020/07/15 09:30 (external edit)

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki