MINOR Added parse of input

Changes:
 -- -p and -w options are mandatory now;
 -- check workdir for existance.