Add support for working-dir global option.