in reply to Move files between directories
Anyway, you might just want to create two lists, one for all the data files under BIG_1, and another for all the data files under BIG_2 (File::Find or one of its variants could help with that, or the gnu "find" command-line utility). Then, the files to move are the ones in the BIG_2 list that are not in the BIG_1 list.
Writing your script to store the lists in memory as separate hashes (with "SMALL_n/filename" as the hash keys) would make it quick and easy to tell which files need to be moved. Or, if the lists are sorted, you could just use the gnu "diff" and "grep" to compare the lists and get the files that appear only in BIG_2.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Move files between directories
by Anonymous Monk on Sep 01, 2009 at 06:54 UTC |