added support for working directory