aspose file tools*
The moose likes General Computing and the fly likes Tool to Change Text on multiple files Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » General Computing
Bookmark "Tool to Change Text on multiple files" Watch "Tool to Change Text on multiple files" New topic
Author

Tool to Change Text on multiple files

Jesus Angeles
Ranch Hand

Joined: Feb 26, 2005
Posts: 2046
Hi,

Let's say, instead of changing text in just 1 file, say, change all 'aaa' to 'bbb' in file ccc.txt, I want to change all 'aaa' to 'bbb', in all files in all subfolders in folder 'ddd'.

Do you know of such useful tool?

(I apparently didnt include the non-java codes during refactoring by eclipse, so I am now faced with this headache.)
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 39549
    
  27
If you want to do this programmatically in Java, check out TextTools and AwkTools.

Otherwise, I'd use sed or awk from the command line (available in CygWin and UnxUtils on Windows)


Ping & DNS - updated with new look and Ping home screen widget
Jesus Angeles
Ranch Hand

Joined: Feb 26, 2005
Posts: 2046
Thanks for the reply. I am currently trying out windows-based 'Neo Replace'. It seems useful so far.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Tool to Change Text on multiple files
 
Similar Threads
Using class with 'main' method
copy recursivley specific file
Request url forwarding
Arrays of strings from a Vector
Ned help with "XPath"