Stories
Slash Boxes
Comments

SoylentNews is people

posted by mrpg on Saturday May 12 2018, @06:19PM   Printer-friendly
from the so-long-linux!!!11!!!1!!!\r\n dept.

Submitted via IRC for TheMightyBuzzard

For many years, Windows Notepad only supported text documents containing Windows End of Line (EOL) characters - Carriage Return (CR) & Line Feed (LF). This means that Notepad was unable to correctly display the contents of text files created in Unix, Linux and macOS.

[...] Starting with the current Windows 10 Insider build, Notepad will support Unix/Linux line endings (LF), Macintosh line endings (CR), and Windows Line endings (CRLF) as usual. New files created within Notepad will use Windows line ending (CRLF) by default, but it will now be possible to view, edit, and print existing files, correctly maintaining the file's current line ending format.

It's about damned time.

Source: Introducing extended line endings support in Notepad


Original Submission

This discussion has been archived. No new comments can be posted.
Display Options Threshold/Breakthrough Mark All as Read Mark All as Unread
The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
(1)
  • (Score: -1, Troll) by Anonymous Coward on Saturday May 12 2018, @07:06PM (2 children)

    by Anonymous Coward on Saturday May 12 2018, @07:06PM (#678906)

    Riiiiiight. So why is there still a Notepad and a WordPad and why have the two programs not been merged into one program by now.

    Why if you care about line endings are you not using WordPad anyway?

    Oh I get it. Uzzard is a fucking moron.

    • (Score: 0) by Anonymous Coward on Sunday May 13 2018, @01:21AM (1 child)

      by Anonymous Coward on Sunday May 13 2018, @01:21AM (#679013)

      Well, it's not that hard to understand. Notepad only handles plaintext. WordPad handles RTF as well as plaintext, tough Notepad is better for plaintext.

      The right tool for the right job.

      • (Score: 4, Informative) by Nerdfest on Sunday May 13 2018, @02:57AM

        by Nerdfest (80) on Sunday May 13 2018, @02:57AM (#679046)

        To be fair, neither are really the right tool for any job.

  • (Score: 4, Informative) by BsAtHome on Saturday May 12 2018, @07:13PM (11 children)

    by BsAtHome (889) on Saturday May 12 2018, @07:13PM (#678907)

    This has been a non-issue for a very long time. You install an editor, symlink it to notepad and be done with it. Then again, dump people are praising the bloody obvious inferiority of notepad by highlighting the minimal improvement a de facto abandoned program has become. Smart people already have replaced the entire operating system with something more preferable.

    Can we please go back to stuff that actually matters? Like the Vi vs Emacs debate ;-)

    • (Score: 2) by Gaaark on Saturday May 12 2018, @07:16PM (2 children)

      by Gaaark (41) on Saturday May 12 2018, @07:16PM (#678910) Journal

      Yeah, i'm thinking "Meh...who gives a shit!"

      Abandon hope all ye who continue to use MS shite.

      --
      --- Please remind me if I haven't been civil to you: I'm channeling MDC. ---Gaaark 2.0 ---
      • (Score: 0) by Anonymous Coward on Saturday May 12 2018, @07:22PM (1 child)

        by Anonymous Coward on Saturday May 12 2018, @07:22PM (#678912)

        But... MS is godly!

        • (Score: 4, Interesting) by Gaaark on Sunday May 13 2018, @12:14AM

          by Gaaark (41) on Sunday May 13 2018, @12:14AM (#678994) Journal

          ANOTHER reason i don't believe in God(s)!

          --
          --- Please remind me if I haven't been civil to you: I'm channeling MDC. ---Gaaark 2.0 ---
    • (Score: 0) by Anonymous Coward on Saturday May 12 2018, @07:28PM (6 children)

      by Anonymous Coward on Saturday May 12 2018, @07:28PM (#678914)

      I remember back in the old days when we had these things called computer viruses that actually infected actual executable files by inserting actual machine code. This was back before every piece of malware is a whole fucking app that installs itself and needs to carry around its own copy of a python interpreter because malware coders are fucking idiots. Back in the day the easy way to keep virus samples for study was to infect notepad.exe and rar each infected notepad in a separate archive.

      • (Score: 2, Informative) by Anonymous Coward on Saturday May 12 2018, @08:09PM (5 children)

        by Anonymous Coward on Saturday May 12 2018, @08:09PM (#678925)

        Edlin is out to be enought for anybody.

        • (Score: 0) by Anonymous Coward on Saturday May 12 2018, @09:53PM (4 children)

          by Anonymous Coward on Saturday May 12 2018, @09:53PM (#678947)

          When I was a boy we used COPY CON uphill both ways in the snow, and we liked it. (shamelessly riffed from the great Bill Cosby)

          • (Score: 2) by MostCynical on Saturday May 12 2018, @10:34PM

            by MostCynical (2589) on Saturday May 12 2018, @10:34PM (#678962) Journal

            Bill Cosby, Grandparents from album "Himself", 1983: https://www.youtube.com/watch?v=4kwz6lGriR0 [youtube.com]

            Monty Python, Four Yorkshiremen, 1976: https://www.youtube.com/watch?v=ue7wM0QC5LE [youtube.com]

            --
            "I guess once you start doubting, there's no end to it." -Batou, Ghost in the Shell: Stand Alone Complex
          • (Score: 0) by Anonymous Coward on Saturday May 12 2018, @11:50PM (2 children)

            by Anonymous Coward on Saturday May 12 2018, @11:50PM (#678977)

            > the great Bill Cosby

            Uh, you might want to check his Wikipedia page.

            • (Score: 3, Insightful) by jmorris on Sunday May 13 2018, @01:35AM (1 child)

              by jmorris (4844) on Sunday May 13 2018, @01:35AM (#679016)

              So he has an asterisk on his record. If he hadn't wandered off the plantation he would have been allowed to die quietly with all of his sins carefully buried with him. Guy still created a huge body of quality work that will probably endure long past the scandals. Most of us understand that if we actually looked, (more accurately were allowed to look) we would find almost the entirety of Hollywood to be diseased. We don't plan to discard the century of shared culture those people created when we finally learn the truth.

              • (Score: 2) by lentilla on Sunday May 13 2018, @06:43AM

                by lentilla (1770) on Sunday May 13 2018, @06:43AM (#679110)

                Guy still created a huge body of quality work that will probably endure long past the scandals.

                I'm not so sure of that.

                The Internet is barely a generation old (counting from the Eternal September) and we don't yet understand how cultural memory is going to work. Our cultural output isn't carved in granite, it isn't written down in books and stored in private libraries. Ten years ago I might have said our cultural heritage was going to be stored in distributed "god boxes" - simplistically: every song, every movie ever produced would be stored on a hard drive. Today, I realise our cultural heritage is stored "on the Cloud".

                Now the "Cloud" is a fickle thing. Yes, we have access to Shakespeare, but we don't have access to Mickey Mouse, nor to the speeches of Martin Luther King Jr. In the case of Cosby, I would be entirely surprised if his entire oeuvre wasn't memory hole'd. For the next sixty years people will feel such disgust that they won't watch his work. Television stations won't rebroadcast (advertisers will make sure of that). The following generations won't grow up watching or hearing of his work. The Cloud may indeed forget him - if nobody watches his work, artificial intelligence may conclude his work is unimportant, and thus will not make an effort to promote his work to others.

                So he has an asterisk on his record.

                An asterisk; so large that it eclipses all of the good things. Society has always been fairly tolerant of artists but there is a tipping point.

    • (Score: 3, Informative) by Azuma Hazuki on Sunday May 13 2018, @03:04AM

      by Azuma Hazuki (5086) on Sunday May 13 2018, @03:04AM (#679048) Journal

      The vi vs emacs debate has already long since been settled. The answer is "nano." /me runs like hell

      --
      I am "that girl" your mother warned you about...
  • (Score: 5, Funny) by KritonK on Saturday May 12 2018, @07:26PM (2 children)

    by KritonK (465) on Saturday May 12 2018, @07:26PM (#678913)

    At last! I can finally switch to Windows, getting rid of both vi and emacs, and embracing the simplicity of notepad. 2018 is shaping up to become the year of Windows on the desktop.

    • (Score: 5, Funny) by Snotnose on Saturday May 12 2018, @09:01PM (1 child)

      by Snotnose (1623) on Saturday May 12 2018, @09:01PM (#678935)

      CSB. Back in the early 90s the big thing was Computer Aided Software Engineering (CASE). Management bought us one (without asking I might add) and during training we were told "You'll love our editor! It's so simple to use you'll be an expert in 30 minutes". He wasn't lying. The editor did diddly squat, it was basically Nopepad wishing it knew where the steroids were kept. It was universally despised by us vi and Emacs experts.

      I figured out how to pull the files out of the CASE tool (Cadre, I think it was) and put them back in. I even wrote a script to pull all the files out and put them back in. Had I charged a nickle anytime anyone wanted to use my script I'd have been making about $1/day.

      The cherry on top was discovered after I'd left the company. Turns out every time I pulled a file out I effectively deleted it, and when I put it back effectively created a new file. Which wiped out all version history, which was something we were required to keep according to our contract. Oops.

      --
      When the dust settled America realized it was saved by a porn star.
      • (Score: 5, Funny) by Snotnose on Saturday May 12 2018, @10:44PM

        by Snotnose (1623) on Saturday May 12 2018, @10:44PM (#678966)

        Heh. Nopepad. Now there's a typo I wish I'd made on purpose.

        --
        When the dust settled America realized it was saved by a porn star.
  • (Score: 4, Insightful) by PinkyGigglebrain on Saturday May 12 2018, @07:46PM (4 children)

    by PinkyGigglebrain (4458) on Saturday May 12 2018, @07:46PM (#678919)

    number of average users this will effect or who will care: 0%

    The only people who might have cared at some point are the admin types who frequently move plain text files between Window and *nix systems. The same people who would have installed a different editor on their Windows box long, long ago.

    --
    "Beware those who would deny you Knowledge, For in their hearts they dream themselves your Master."
    • (Score: 4, Insightful) by The Mighty Buzzard on Saturday May 12 2018, @08:59PM (2 children)

      Having to download a real text editor for windows to edit one file on a computer you'll likely never touch again is an unnecessary pain in the ass. I doubt it took them any longer to improve the code than it has cost just me in wasted time.

      --
      My rights don't end where your fear begins.
    • (Score: 1, Informative) by Anonymous Coward on Saturday May 12 2018, @09:49PM

      by Anonymous Coward on Saturday May 12 2018, @09:49PM (#678946)

      The only people who might have cared at some point are the admin types who frequently move plain text files between Window and *nix systems. The same people who would have installed a different editor on their Windows box long, long ago.

      I've been using todos and fromdos for ages. I always run fromdos on anything that might have been touched on a Windows machine.

  • (Score: 3, Informative) by edIII on Saturday May 12 2018, @07:49PM

    by edIII (791) on Saturday May 12 2018, @07:49PM (#678921)

    When I was using Windows, Notepad was my favorite. For a long time, just due to the simplicity. Wordpad was a bit too complicated, and if I needed those features, would use Office instead. Notepad was perfectly lightweight.

    However, that CRLF business made it very difficult, and progressively more so, to view normal files. That was because a LOT of normal files were coming to me from Mac/Linux.

    I ended up switching to Notepad++ some years ago, purely for the line ending support.

    --
    Technically, lunchtime is at any moment. It's just a wave function.
  • (Score: 3, Informative) by MichaelDavidCrawford on Saturday May 12 2018, @08:29PM (3 children)

    by MichaelDavidCrawford (2339) Subscriber Badge <mdcrawford@gmail.com> on Saturday May 12 2018, @08:29PM (#678929) Homepage Journal

    That was a Classic Mac OS thing. OSX uses \n

    I've still got lots of source code with \r

    --
    Yes I Have No Bananas. [gofundme.com]
    • (Score: -1, Troll) by Anonymous Coward on Sunday May 13 2018, @03:17AM (2 children)

      by Anonymous Coward on Sunday May 13 2018, @03:17AM (#679056)

      I've still got lots of source code with \r

      Sure you do and I believe you too. So where exactly did you store "lots of source code" while you were allegedly homeless? On a USB stick up your ass? Did your mother pay to keep your antique source code in a storage locker somewhere? Or did your alter ego Eris upload everything to the cloud for you while you were in the mental hospital? I really want to know which lie you will choose this time.

  • (Score: 2) by corey on Saturday May 12 2018, @10:31PM

    by corey (2202) on Saturday May 12 2018, @10:31PM (#678961)

    Coincidence - I commented on notepad not being able to interpret Unix newlines in a story last week.

    I was thinking notepad was on the death bed with mspaint.

    Good because at work I use notepad all the time for "plaintexting" text I've copied from a template document before pasting into another, plus for scratchpad notes and reminders/TODO.

  • (Score: 3, Funny) by Anonymous Coward on Sunday May 13 2018, @02:09AM

    by Anonymous Coward on Sunday May 13 2018, @02:09AM (#679026)

    They are putting so much AI and machine learning into their products, that even Notepad can understand line endings.

  • (Score: 2, Insightful) by Anonymous Coward on Sunday May 13 2018, @08:56PM

    by Anonymous Coward on Sunday May 13 2018, @08:56PM (#679303)

    unix2win.bat

    ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
    :: unix2win.bat
    :: converts line endings from Unix (LF) to Win (CRLF)
    :: place this batch file in your system path.
    :: usage: unix2win inputfile > outputfile
    :: more info: https://www.dostips.com/forum/viewtopic.php?t=3897
    ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::

    @echo off
    type %~1 | more /p

    REM     alternatively this also works:
    REM     for /f "tokens=*" %%i in ('type "%~1"') do echo.%%i

     
    win2unix.bat

    ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
    :: win2unix.bat
    :: converts line endings from Win (CRLF) to Unix (LF)
    :: place this batch file in your system path.
    :: usage: win2unix2 inputfile > outputfile
    :: more info: https://www.dostips.com/forum/viewtopic.php?t=3897
    ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::

    @echo off
    :init
    for /f %%c in ('copy /z "%~dpnx0" nul') do set cr=%%c
    (set lf=^

    )
    del file.tmp 2>nul
    for /f "delims=" %%i in ('findstr /n "^" "%~1"') do (
    set "line=%%i"
    setlocal enabledelayedexpansion
    set "line=!line:*:=!!lf!"
    echo(!line!
    endlocal
    )>>file.tmp
    setlocal enabledelayedexpansion
    findstr /v "!cr!!lf!" file.tmp
    endlocal
    del file.tmp 2>nul

(1)