I am a Java programmer. I use bash scripts to process text.
Utilities such as grep, sed, awk, tr, wc, find, as well as the connection between commands give such a powerful combination.
However, bash programming does not have the portability, testability, and more elegant programming constructs that exist in Java. It also makes integration with other Java products difficult.
I was wondering if anyone knows of any Java word processing libraries that can offer what I'm looking for.
It would be great to write:
Text.createFromFile("blah.txt).grep("-v","ERROR.*").sed("s/ERROR/blah/g").awk("print $1").writeTo("output.txt")
It could be pie material in the sky. But I thought I would leave the question anyway.
source share