Also perform minor code cleanup.
To help with compatibility
Make options not required, add support for working directory and skipGitRepoCheck options on the turn
Executable detection uses the same rules as the codex wrapper.