Find text and remove entire line?

Tool for Search and Replace across multiple files.
Post Reply
StryfeWalker
Posts: 1
Joined: Sun Aug 07, 2016 3:30 am

Find text and remove entire line?

Post by StryfeWalker »

I have been a user of Duplicate Cleaner for some time and stumbled upon TextCrawler while visiting the website. I'm curious if TextCrawler might work to do something I've been contemplating for a while now.

I have an archive of files in many multiple directories (thousands of files in hundreds of directories). I used a hash program a long time back to store the hash for every file in the directory structure I was using at that time. Since then, I've renamed and moved many of the directories. The files within the directories are the same and the hashes should still work, but since the directory structure is no longer the same, the hash check program I have won't match them up.

What I have done is run a new hash check on the new directory structure. Now I have two text files, the old one with the hash and the old directory structure/name and a new text file with the hash and the new directory structure/name. What I would like to do is use the new text file to find the matching hash in the second text file and upon doing so delete the entire line of that hash in the second text file. What I should have left then of the second text file are the list of files that didn't match and therefore are potentially corrupted.

Is this something that TextCrawler can possibly do?
User avatar
DigitalVolcano
Site Admin
Posts: 1717
Joined: Thu Jun 09, 2011 10:04 am

Re: Find text and remove entire line?

Post by DigitalVolcano »

I don't think TextCrawler would do this, off the top of my head. I would probably approach this using a spreadsheet (e.g. Excel), pasting the data in and using one of the lookup functions to flag the matching lines. You can then export the flagged lines.
Post Reply