[Tex/LaTex] How to install and use arara package

araratexlivewindows

I am interested in using "arara" package.
According to it's manual my below code should run without any error:

% arara: pdflatex
\documentclass{article}

\begin{document}
Hello world.
\end{document}

but I get nothing and have problem with this code.
It should be mentioned that I install Java after installing LaTeX.
Error:

Process started: "C:/texlive/2015/bin/win32/arara.exe"

C:\texlive\2015\bin\win32\runscript.tlu:680:
C:\texlive\2015\bin\win32\runscript.tlu:650: program not found (not
part of TeX Live): java.exe

Process exited with error(s)

Best Answer

I am composing this answer after gathering the comments of daleif, hossein-behboodi, nicola-talbot, cmhughes

Basically, if arara fails to work, one must check if we can run Java from the command line (DOS prompt for Windows).

java -version

If it fails install Java. Things will start working. If not, see How to get arara working with TeXstudio.

nicola-talbot says Only JRE is required. JDK is for compiling the Java code. The JRE is just for running pre-compiled Java code.

cmhughes says it would be nice to see java-is-not-recognized-as-an-internal-or-external-command