fix Windows case
allow working dir to be set, too