Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I have an archive which, for reasons beyond my comprehension, contains 900 files all with the same name. That means that if I ask 7zip to extract them all, at the end there is just one file. The solution, of course, is to ask 7zip to extract the files one at a time, and rename each one to something else.

But how, pray tell, do you ask 7zip to extract one particular file when they all have the same name??

Is there some way to ask 7zip to extract the Nth file in the archive? That would work...

(I want to do this from a script, so I don't really want to use 7zip's interactive mode.)

share|improve this question

1 Answer 1

By supplying the -aou switch, you can make 7zip extract all the files, but give each one a unique name. Now you just have to somehow guess which file on disk corresponds to which metadata from the file listing...

share|improve this answer
    
ok, to give names for 900 files - no problem, sort them by date and take the names from the origin. –  user55518 Mar 19 at 16:24
    
Nice idea, but... they have the dates from the archive. Which are all identical. –  MathematicalOrchid Mar 19 at 16:26
    
you have access,modify and change dates they are not all unique. check with stat file –  user55518 Mar 19 at 16:28

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.