How to get rid of Windows \r\n as the line terminator ?

General questions about using TextPad

Moderators: AmigoJack, helios, bbadmin, Bob Hansen, MudGuard

Post Reply
rogergravel
Posts: 4
Joined: Tue Dec 13, 2016 9:07 pm

How to get rid of Windows \r\n as the line terminator ?

Post by rogergravel »

I understand that I can set TextPad to save new files in UTF-8 Code and UNIX file type.
How do I convert many files registered in a particular CODE/FILE TYPE setup to another CODE/FILE TYPE setup ?

Or, how do I recognize a line has \r\n as a line terminator
and change it so it ends with just \n alone ?

I know the command line in linux is : sed -i 's/\r//g' «filename.txt»
but is there a way with TextPad ?

Thanks
ben_josephs
Posts: 2456
Joined: Sun Mar 02, 2003 9:22 pm

Post by ben_josephs »

The HOW-TOs forum is not the the right place to ask questions. As it says in one place:
    Instructional HowTos, posted by users. No questions here please
and in another:
    PLEASE DO NOT POST QUESTIONS HERE

But anyway:

You can change the line endings and encoding when you save a file:

    File | Save As...
        Line ending: UNIX
        Encoding: UTF-8

You would have to do this on each file you want to change. TextPad is not designed to perform bulk edits on multiple files.
rogergravel
Posts: 4
Joined: Tue Dec 13, 2016 9:07 pm

PLEASE DO NOT POST QUESTIONS HERE

Post by rogergravel »

Please let me know where I can ask questions.
Thank you
ben_josephs
Posts: 2456
Joined: Sun Mar 02, 2003 9:22 pm

Post by ben_josephs »

Visit https://forums.textpad.com/ and choose General
or go there directly:
https://forums.textpad.com/viewforum.php?f=8

Do you have further questions?
rogergravel
Posts: 4
Joined: Tue Dec 13, 2016 9:07 pm

No more questions for now

Post by rogergravel »

No more questions for now
Thank you.
Post Reply