5

How to make sure that a source file is in UNIX mode?

In other words, how to check that every line in a text file is ended by LF rather then CR+LF? I am asking because a package intended for uploading to CTAN should be saved in UNIX mode. Earlier, it was possible to emulate UNIX mode in WinEdt, but after upgrading to WinEdt 7 I don't see UNIX in a list of WinEdt's submodes.

P.S. I am using Windows 7.

  • 2
    I post-process files when making the zip file (zip -r -q -X -ll using InfoZIP): is that an option for you? – Joseph Wright Apr 8 '13 at 11:48
  • 5
    Notepad++ can handle that. Both an indicator in the status bar, and a set of menus under Edit / EOL Conversion – Mike Renfro Apr 8 '13 at 11:55
  • @JosephWright, thank you, unfortunetely, most links to infozip (including Wikipwdia) are not active. – Igor Kotelnikov Apr 8 '13 at 12:18
  • @Igor Probably the easiest way to install it as part of GNU on Windows. – Joseph Wright Apr 8 '13 at 12:33
  • 1
    @JosephWright, please transform your comment to answer. – Igor Kotelnikov Apr 8 '13 at 13:28
3

Nothing has changed in WinEdt 7. Simply add :UNIX at the end of your document's mode in Document Settings dialog (accessible via the Document menu) and press OK. Your document's EOL will be changed to LF.

  • Hi Karl Nice to see you here :-) – user11232 Apr 20 '13 at 5:56
1

This Answer won't help using windows, however: The line breaker problem for users of Mac OSX can be solved by the linebreak application. http://code.google.com/p/linebreak/ Works via drag and drop, takes presets or asks what todo. Transfers Mac, Unix, and Windows/DOS formats in all directions. Can preserve original file.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.