16.23 Comparing Filenames in Two Directory Trees
Do you have two directory trees full of subdirectories and files?
Would you like to compare the filenames to see if there are some files only
in one tree or the other?
If you don't have
dircmp
(16.22
)
,
look at the quick-and-dirty substitute in the example below.
The
numbered prompts (7.2
)
like
The comm (28.12 ) command will give you two columns: files in the left-hand column are only in directory1 . Files in the right-hand column are only in directory2 . You can get other information, too, like a list of files in both trees.
This works nicely for directory trees on other computers, too.
Run one
The - |
|