Merge pull request #4 from agorararmard/rid-off-shell-calls

Remove unnecessary shell calls and reduce reliance on shell calls.