I have a huge text file (a few million lines) with 7z output that looks like the code section below.
In this I need to find files with the same filename or crc, coupled with filesize, then return the name of the .zip.
Lets say I searched for DOOM.EXE (size 709905) here. I would first need to find DOOM.EXE, then find the first occurance of "Size = " after, which is easy. But then I would have to reverse the search to find the first "Listing Archive: " prior. Since there are thousands of "Listing Archive: " prior and after this tiny section of the text file I do not know how I can do it.
Any idea or custom function for this?
Code: Select all
Listing archive: C:\Games\DOOM (1993).zip
--
Path = C:\Games\DOOM (1993).zip
Type = zip
Physical Size = 5531066
Comment = TORRENTZIPPED-826F22B9
----------
Path = DOOM\DMFAQ66D.TXT
Folder = -
Size = 34572
Packed Size = 11768
Modified = 1996-12-24 23:32:00
Created =
Accessed =
Attributes =
Encrypted = -
Comment =
CRC = 4FB284FF
Method = Deflate:Maximum
Characteristics =
Host OS = FAT
Version = 20
Volume Index = 0
Offset = 148750
Path = DOOM\DOOM.EXE
Folder = -
Size = 709905
Packed Size = 360317
Modified = 1996-12-24 23:32:00
Created =
Accessed =
Attributes =
Encrypted = -
Comment =
CRC = BE91C727
Method = Deflate:Maximum
Characteristics =
Host OS = FAT
Version = 20
Volume Index = 0
Offset = 160674