added support for path for unix (under /tmp) and windows (under user dir)