Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

iterating through a hierarchy with a filter

Greetings -- I have a series of XML files scattered around a hierarchy. I also have a filter script which reads stdin and writes stdout in a standard Unix way.

I need to create a mirror hierarchy where files are results of applying the filter to the originals, replacing the original extension, say .xml, with the result extension, say .txt. Except for the extension change, the hierarchy should be preserved.

Ideally, my script would not know anything about this whole process, so I can take any filter and use it for my transforms. The hierarchy for the transformed tree must be created anew so I can easily throw it away (i.e. we do not output the results next to the originals). The original and result extensions should be provided as a parameter to the process.

Which zshfoo can I use for it above and beyond find with exec helper script?


Messages sorted by: Reverse Date, Date, Thread, Author