Fixed the external-command-file argumment handling, make sure we add newlines at the end of additions to the command file