If the OS is windows, convert line endings from LF to CRLF when saving

Fix for #136 

Sorry, no unit tests, but a pretty simple fix. I have tested on my Windows system.