Post B7YfCC9WYfjaAIvga8 by kabel42@polymaths.social
(DIR) More posts by kabel42@polymaths.social
(DIR) Post #B7YfCBRvAmr7z4WrcO by rl_dane@polymaths.social
0 likes, 0 repeats
LOL NOPE. There was a ticksy '^M' / '\r' hiding in the text, Precious!!! Tricksy carriage return, we hates them, Precious!!!P.S. using the "l" command could have saved me a few minutes of consternation 😅 —rld@prometheus:~$ echo -e 'sneaky\rhello there'hello thererld@prometheus:~$ echo -e 'sneaky\rhello there' |snarfirld@prometheus:~$ edP*H*r !snarfo19*,nhello thereaky*,phello there*,lsneaky\rhello there*GUYS,I think I just found a bug in #FreeBSD's #ed(1):*,n1a 1-bit bi-level (#4254772 and 3#9fabcd*1a 1-bit bi-level (#425477*j*p and it bi-level (#425477*WHAT??!??unexpected command suffix*,n and a 1-bit bi-level (#4254772#9fabcd**,p and it bi-level (#425477#9fabcd*u*,n1a 1-bit bi-level (#4254772 and 3#9fabcd*,pa 1-bit bi-level (#425477 and #9fabcd*
(DIR) Post #B7YfCBje6t2As2p1FI by kabel42@polymaths.social
0 likes, 0 repeats
@rl_dane can't you print control characters escaped, like pythons repr?In [7]: print("asd\rqwe")qweIn [8]: print(repr("asd\rqwe"))'asd\rqwe'
(DIR) Post #B7YfCBwlK7WfWixUgq by rl_dane@polymaths.social
0 likes, 0 repeats
@kabel42Yep, that's what I forgot to do. See the latest edited version of the toot. ;)
(DIR) Post #B7YfCC9WYfjaAIvga8 by kabel42@polymaths.social
0 likes, 0 repeats
@rl_dane ok, I'm too dumb for ed :)
(DIR) Post #B7YfCCMHnDwUnstsTQ by mirabilos@toot.mirbsd.org
0 likes, 0 repeats
@kabel42 @rl_dane ed(1) is easy if you know re_format(7)See also 09.edtut(USD) and 10.edadv(USD)
(DIR) Post #B7Yih4LpugxcoE6NXs by ed1conf@bsd.network
0 likes, 0 repeats
@rl_dane It's also how I managed to make it look like ed(1) had added syntax highlighting functionality a while back::flan_wink:
(DIR) Post #B7Yipdr3nORpEpnJR2 by rl_dane@polymaths.social
0 likes, 1 repeats
@mirabilos @kabel42The cool thing is that you don't have to use subsitution (,s///) for everything. You can even break up lines based on commas like s/, */, \ /g, and then work on the line fragments individually, and then re-join them, like 1,3j.I do 99% of my tooting (when not squinting at a piece of glass) from ed now. :D
(DIR) Post #B7YjgtfXjHE3dJnjuq by rl_dane@polymaths.social
0 likes, 0 repeats
@kabel42Not a chance! It's actually really quite simple.
(DIR) Post #B7Yjgtt0vC08J66Uue by rl_dane@polymaths.social
0 likes, 0 repeats
@kabel42You can get @mwl's #ed Mastery book, and/or check out this YT vid:https://www.youtube.com/watch?v=GoyNMFccbow
(DIR) Post #B7Yjgu54CNdsuTk7hQ by kabel42@polymaths.social
0 likes, 0 repeats
@rl_dane @mwl I don't think I can remember that many one letter commands without having to use ed for some time :)
(DIR) Post #B7YjguEzbTa9PGO3Ae by kabel42@polymaths.social
0 likes, 0 repeats
@rl_dane @mwl I totally get the appeal, especially for inputting code (changes) you made on a printout
(DIR) Post #B7YjguPGzFnzv9CGC8 by rl_dane@polymaths.social
0 likes, 0 repeats
@kabel42 @mwlFor editing code, I honestly do use vi (nvi) most of the time. Also for editing long text like markdown.But for writing quick notes and toots? ed is beautifully minimalistic. It's like all those fancy-pants "distraction-free" writers, except:rld@Intrepid:~$ ll $(which ed)-r-xr-xr-x 2 root wheel 51,912 Jun 6 2025 /bin/edrld@Intrepid:~$ Yeah. EAT THAT, #Electron. 🤣
(DIR) Post #B7Yjguc2Do0uYjAS5Q by rl_dane@polymaths.social
0 likes, 0 repeats
@kabel42 @mwlAlso, I use ed for editing my bookmarks file, because that's a use case where I definitely don't need to see anything that came before. I just open the file, then0a#(append text from the beginning of the file (line zero))#some cool linkhttps://coolness.example.com/something-cool.#(end insertion mode)wq#(you already know what this means. ;)
(DIR) Post #B7YjguqvKRvJIu8LIG by mirabilos@toot.mirbsd.org
0 likes, 0 repeats
@rl_dane @mwl @kabel42 ah I use lynx for my bookmark file ;)
(DIR) Post #B7Yk5HoLcaflSTY7Ye by rl_dane@polymaths.social
0 likes, 0 repeats
@mirabilos @mwl @kabel42I could never figure out how to get lynx to leave my terminal light theme alone.The best I could manage was a black-on-gray theme, which is not what I want. :P
(DIR) Post #B7Yk5I2Wls10ASBRey by mirabilos@toot.mirbsd.org
0 likes, 0 repeats
@rl_dane @kabel42 @mwl eh, there’s a black and white wrapper and several lss files and you can write your own as well(also, lynx cannot change the terminal emulator’s colour theme, it merely uses it)
(DIR) Post #B7Ylc6sXOADt3viynY by rl_dane@polymaths.social
0 likes, 0 repeats
@mirabilos @kabel42 @mwlI mean, it always paints with white-on-black colors, so in effect, it's ignoring/overriding my theme. (I know "theme" is a very nebulous concept in the terminal, unfortunately).I tried messing with a custom lss file, but didn't get the desired result. But fortunately, there are other terminal browsers I like.
(DIR) Post #B7Ylc79uLa7LvnqqsC by mirabilos@toot.mirbsd.org
0 likes, 0 repeats
@kabel42 @mwl @rl_dane it doesn’t
(DIR) Post #B7Ym5da4siPAsuAajQ by mirabilos@toot.mirbsd.org
0 likes, 0 repeats
@rl_dane @kabel42 @mwl try some of the lss files from the sample directory of the lynx source; possibly the [oldlynx] script (which at least has a white background, but is uglish)
(DIR) Post #B7YmMc0hyQmqw8iiIK by rl_dane@polymaths.social
0 likes, 0 repeats
@mirabilos @kabel42 @mwlI don't understand what you're saying. When I open a url in lynx, it redraws my entire terminal with a black background and white text.
(DIR) Post #B7YmMcGf17XzjcBS9w by mirabilos@toot.mirbsd.org
0 likes, 0 repeats
@kabel42 @mwl @rl_dane that’s just one of the possible lynx stylesheets
(DIR) Post #B7YsBFsKWy0QpElka8 by rl_dane@polymaths.social
0 likes, 0 repeats
@mirabilos @kabel42 @mwlNone of the lss files had a plain white background, they were all black or blue. XDoldlynx came close, but had a gray background.I might futz with it some more later.
(DIR) Post #B7YsBGEJDFaRvP3Iq8 by mirabilos@toot.mirbsd.org
0 likes, 0 repeats
@rl_dane @kabel42 @mwl you can insert the keyword for the default bg/fg there, too (currently on a trip so cannot help precisely)
(DIR) Post #B7cskSiWDoEoyFAbWC by rl_dane@polymaths.social
0 likes, 0 repeats
@mirabilos @kabel42 @mwlI saw mention of default in the .lss file, but couldn't figure out where/how the default was set.Safe travels, holler back later if you remember when you're back in front of a proper unix machine 😄
(DIR) Post #B7cskSxPKS9DiQ8Uj2 by mirabilos@toot.mirbsd.org
0 likes, 0 repeats
@rl_dane @kabel42 @mwl so… /etc/lynx/lynx.lss on a Debian has this near the top:# If you really want the terminal's default colors, and if lynx is built using# ncurses' default-color support, remove these two lines:Comment out the two lines below. Now lynx is keeping the white background in an experimental terminal I used for it.(Not for all things, e.g. tt is still defined with an explicit black background, and most of the other colours, like yellow for the selected element, are too bright. But it’s a start.)I played a bit with the other .lss files, but even the most promising one (blue-background.lss) seems harder to adapt to a bright scheme than the default one, so maybe go on from there.
(DIR) Post #B7dOyLvBTwA4TulH5U by rl_dane@polymaths.social
0 likes, 0 repeats
@mirabilos @kabel42 @mwlThat was one of the first things I tried (commenting out the normal: and default: lines). No change. :/
(DIR) Post #B7dOyMDcNOuHP5Nzou by mirabilos@toot.mirbsd.org
0 likes, 0 repeats
@rl_dane @kabel42 @mwl using the standard lynx build in Debian/Devuan?Then your terminal emulator is broken. Try xterm.You can get by by specifying foreground and background colours everywhere manually, of course.