Fix bug: directory args incorrectly parsed. fix regex.
Fix bug: new file tries to use undefined variable, throws error
Clarify Windows support and replace "~" with $HOME