Executing shell script from java
Posted on 2013-06-13
I need to execute a shell script from java code by passing the parameters. In short, the following command works perfect from a terminal and I need to get this executed from java code:
tom@tom-Inspiron-N4050:~/Downloads/myscripts$ ./test_final_6jun.sh test com/abc
In the above code "./test_final_6jun.sh" is the script and "test com/abc" is the parameter to be passed. How can I accomplish this using java code? Any help is much appreciated.