5 comments

  • Cyykratahk11 minutes ago
    A stray &quot;J&quot; I encountered years ago: a certain client&#x27;s support tickets would often end with a single &quot;J&quot;, which was a little confusing as it was not one of their name initials. After a brief investigation, the original email source contained this:<p><pre><code> &lt;font face=&quot;Wingdings&quot;&gt;J&lt;&#x2F;font&gt; </code></pre> Which renders as a smiley face.
  • mike_hock3 hours ago
    &gt; but in ANSI newline delimiter is translated as &quot;j&quot;<p>?
    • ralferoo3 hours ago
      \n is ^J (ctrl-J) so there&#x27;s some logic there, but I wonder if something has been lost in the message. I&#x27;d guess it either displays ^J or an inverse-colour J, rather than just a plain lowercase j.<p>Also possible that the j is a red herring and just some random character that&#x27;s always there. Pasting a URL containing a newline into most browsers just truncates it at the newline, regardless of how much text is after. I only know this from occasionally copying links from a terminal window where the copy somehow added newlines every 80 characters (even though copying this way normally works fine). I&#x27;d have to copy the URL with newlines into a text editor, remove the new lines and copy again to be able to paste it.
      • randallsquared1 hour ago
        Some tool or library is interpreting the newline as two characters (as you note), and then a subsequent step is removing unprintable characters. Things like this used to frequently happen in shells, Perl, PHP, and so on.
      • rgoulter48 minutes ago
        &gt; \n is ^J (ctrl-J) so there&#x27;s some logic there<p>The same &#x27;j&#x27; as vi uses for &#x27;hjkl&#x27;. <a href="https:&#x2F;&#x2F;vi.stackexchange.com&#x2F;questions&#x2F;42426&#x2F;why-did-vi-use-hjkl-instead-of-jikl&#x2F;42428#42428" rel="nofollow">https:&#x2F;&#x2F;vi.stackexchange.com&#x2F;questions&#x2F;42426&#x2F;why-did-vi-use-...</a>
      • thaumasiotes2 hours ago
        &gt; \n is ^J (ctrl-J) so there&#x27;s some logic there<p>Specifically, J is the 10th letter of the alphabet and therefore ctrl-J is code for ascii 10. Same reason ctrl-D sends EOF and ctrl-I sends tab.
        • mike_hock2 hours ago
          Yes, but piping output containing newlines into wl-copy does not result in j&#x27;s in the clipboard.
  • baruchel2 hours ago
    <a href="https:&#x2F;&#x2F;zippythepinhead.com&#x2F;Merchant2&#x2F;merchant.mv?Screen=PROD&amp;Product_Code=28-Sept-98&amp;Category_Code=s1998&amp;Product_Count=23" rel="nofollow">https:&#x2F;&#x2F;zippythepinhead.com&#x2F;Merchant2&#x2F;merchant.mv?Screen=PRO...</a>
  • meindnoch3 hours ago
    So this is a bug in that Signal TUI he was using? I.e. it mangles newlines in pasted text.
    • neonz802 hours ago
      Impossible, Signal TUI is written in Rust.
  • benj1113 hours ago
    I like how -j fixed the stray j problem....
    • rav2 hours ago
      Today I learned that jq -Rrj is a shorter command line for doing the same as tr -d &#x27;\n&#x27;.