laziness, impatience, and hubris | |
PerlMonks |
comment on |
( [id://3333]=superdoc: print w/replies, xml ) | Need Help?? |
I'll be your Good Samaritan. First, let's cleanup your post.
Dear Monks: I'm running into a fairly simple problem, but I have not been able to solve it. I have decided to look for some help. I'm not very good at scripting, and I was hoping that I would find a Good Samaritan on this website. I have files in the following format:
I want to copy all nnn.dat files that are located in every subfolder into a /newfolder/nnn.dat in such a way that each nnn.dat gets renamed according to its location. For example:
I don't know where to start. What would be a good starting point? Thank you for your help. ===============================================================How did you do that? For "Dear Monks:", I wrapped the expression in paragraph and italic tags:For each paragraph, use tags like this: For your list of files, I wrapped the paths with code tags. Looking good... Now what? You'll need to follow Grandfather's advice and try to put a script together. You can start by studying the documentation for:
glob Also, read and reread Writeup Formatting Tips Now it's up to you. Good luck and keep trying! In reply to Re: copy and rename depending on location
by Khen1950fx
|
|