22 January 2008 10:30
ASPN : Python Cookbook : sed/awk : Python script to rename subdirectories of a directory tree, replace strings in files
(via)I needed to write a sed/awk Python equivalent for walking into a directory tree and renaming certain subdirectories, while also looking into all xml files on the way and replacing/modifying certain strings in those files.
Frequently-Asked Questions about sed, the stream editor
(via)ssed and Perl solution
The best solution for multiple files in a single directory is to use ssed
1
(2 marks)