How do I run cygwin from Java?
Instead of using Java to run Cygwin to call nutch, you should probably look into integrating Nutch directly with your Java application. There's documentation here :
"While the Nutch web app is a great way to start searching, most projects using Nutch require the search functionality to be more tightly integrated with their app. There are different ways to accomplish this depending on the app. We'll cover two ways here. using the Nutch API and using the OpenSearch API.
source to share
If you are trying to run a binary that requires cygwin1.dll
(which includes most of the commands you can run from the cygwin bash shell), you can run it by specifying the cygwin \ bin directory in your path environment variable e.g .:
Process p = Runtime.getRuntime().exec(
"C:/path/to/cygwin/binary.exe", new String[] { "PATH=C:\\cygwin\\bin" });
This assumes you have installed cygwin in C:\cygwin
source to share