Skip to main content
The 2024 Developer Survey results are live! See the results

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

8
  • 23
    Also works on OSX. Good solution. Simple and worked for me while the accepted answer did not. (Note: was not a .txt file)
    – dlsso
    Commented Aug 18, 2016 at 17:23
  • 21
    is the display of M$ an easteregg/windows bashing?
    – Tom M
    Commented Feb 21, 2018 at 13:25
  • 1
    Does not work with Solaris, but man says tthat it should have worked
    – Zeus
    Commented Mar 15, 2019 at 0:18
  • 1
    @TomM no. The caret in ^M$ inverts this into an easter egg for Microsoft cultists.
    – Bob Stein
    Commented Jan 20, 2021 at 17:54
  • 2
    I find that I have to use cat -vE <filename> to see the \r characters (displayed as ^M) and the \n characters (displayed as a $). This is using GNU cat on Linux.
    – xmnboy
    Commented Mar 25, 2021 at 18:29