MacMost Q&A Forum • View All Forum QuestionsAsk a Question

How Do I Save the Find Duplicates Script Result Data Into a Text File?

with the script that you provide last week:

find . -type f -size +1M -exec cksum {} \; | tee /tmp/filelist.tmp | cut -f 1,2 -d ‘ ‘ | sort | uniq -d | grep -hif – /tmp/filelist.tmp | sort -nrk2

i’m trying to recover from the exiting data and put it in a text file and save it automatically…

i dont know what command at the end of the script to do that…
—–
Eric Dyrda

Comments: One Response to “How Do I Save the Find Duplicates Script Result Data Into a Text File?”

    2 years ago

    A super easy way to do it is to just copy and paste from the Terminal window to a text file in TextEdit, a note or whatever you want.

    If you want to add it to the command, just use > followed by the filename at the end.

    ... | sort -nrk2 > duplicatelist.txt

Comments Closed.