Even more fun with vim and cygwin

The last time I used cygwin at work on a Win7 x64 machine it worked great, but now I tried it at home on Win8 x64 and vim is just fucked up in the standard configuration. In the insert mode when you press the arrow buttons it inserts characters like A,B, whatever. Quick google, a there is a fix for this. Overwrite your default vimrc with the supplied one from cygwin – well that could have been done automatically to save me some stress.

But it doesn’t end there, copy and paste from Windows back and forth doesn’t quite seem to work, at least not with the mouse and also the keys don’t seem to work always. In cygwin shell everything is fine, but not in vim. Again ask google and again we need to modify our vimrc file – wtf? Shouldn’t this work out of the box?

Ok then lets use notepad++ to write the bash scripts and just cygwin to execute it – but then what:

$ ./split-cap.sh Captain1.mkv
./split-cap.sh: line 2: $’\r’: command not found
./split-cap.sh: line 4: $’\r’: command not found
./split-cap.sh: line 6: $’\r’: command not found

Ah damn it – windows line break and linux line break is different….so spending another 5 minutes looking how to change this in notepad++ then I went for the simple solution:

touch newfile.sh in cygwin and then edit it with notepad++.

God sometimes I wish I would just stick with one OS 🙂

Leave a Reply

Your email address will not be published. Required fields are marked *