Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
What is the difference between the file formats of a plain text file in Linux and in Windows? For example, if I create a file using, say gedit in Fedora and then look at it in kwrite, everything is fine. If I look at it in Windows Notepad, all the CR/LF line endings seem to have disappeared and I get a fairly difficult to follow jumble of text.
That is because Windows use a different character for carriage return than Linux and Unix in general uses. Your best bet is to use a decent text editor in Windows, such as Scite, Notepad2, Texpad, Ultraedit or Notepad++. Remember that Notepad has not been update in years, pretty much like IE6 and should be avoided at all costs.
My reason for asking is that from time to time I want to cut and paste data between Linux and Windows and I have noticed that a Windows text file seems to be fine in Linux but not the reverse.
I was labouring under the naive assumption that the concept of an ASCII file with lines terminated by CR/LF hadn't changed since the days of DOS Version 2.0. I'll see what I can find for an editor when I'm on the wrong side of the wire!
My reason for asking is that from time to time I want to cut and paste data between Linux and Windows and I have noticed that a Windows text file seems to be fine in Linux but not the reverse.
I was labouring under the naive assumption that the concept of an ASCII file with lines terminated by CR/LF hadn't changed since the days of DOS Version 2.0. I'll see what I can find for an editor when I'm on the wrong side of the wire!
Thanks again. :study:
John
Wordpad actually does the trick. And yes, DOS (and hence Windows)
uses CR/LF, Unix (and hence Linux) is using a LF (has been for almost
40 years, btw ;} - again, DOS is the deviation), and the Mac uses CR ...
You're right - my test file (a Grub Menu) which looked terrible in Notepad looks fine in Wordpad so all that hunting for Scite - it took all of ten minutes! - was unnecessary. Funny, somehow I think that my editing in Windows will use Scite rather than Wordpad - I want a Text Editor, not a baby Word Processor. :-)
I absolutely hate VIM - I've never been able to get my head round using it even for things when you have to like visudo! I'm sure there must be a way of shifting the editor default away from VIM and when I figure it out....
I absolutely hate VIM - I've never been able to get my head round using it even for things when you have to like visudo! I'm sure there must be a way of shifting the editor default away from VIM and when I figure it out....
John
To change the editor used with visudo, ensure that you have the EDITOR environment variable set to you favorite editor, example:
You might also want to check out pico text editor if you're comming from windows and are new to linux, so when you hit the backspace key it actually does a backspace vs ESC,x in vi.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.