| Post Reply | RetroFed Forum Forum Index » Linux |
| Author | Message | ||
|---|---|---|---|
zarkanian
sh.itjust.works
zarkanian@sh.itjust.worksJoined: 2024-01-11 |
Today, I was doing some command-line stuff and then this happened:
It's rendering Is This has absolutely no bearing on my work and my life in general except for the fact that I'll go absolutely batshit trying to figure this out, because that's how my brain is. So far, all of my web searches just confirm that |
||
| 27 Original | |||
|
testman
lemmy.ml
testman@lemmy.ml Joined: 2020-10-28 |
From what I see you are missing spaces around pipe (the | character). It should be |
||
| -10 | |||
zarkanian
sh.itjust.works
zarkanian@sh.itjust.worksJoined: 2024-01-11 |
From what I see you are missing spaces around pipe (the | character). It should be ls --help | less
That doesn't make any difference. |
||
| 12 | |||
|
solrize
lemmy.ml
solrize@lemmy.ml Joined: 2023-06-22 |
Yeah use less -r. You can set that in your environment
is what I use. |
||
| 1 | |||
|
quarrel4you
piefed.social
quarrel4you@piefed.social Joined: 2026-02-26 |
One option is to use |
||
| 5 | |||
darklamer
feddit.org
darklamer@feddit.orgJoined: 2026-02-19 |
Yeah use less -r. You can set that in your environment export LESS="-EX -r" is what I use.
Capital |
||
| 4 | |||
|
tangeli
piefed.social
tangeli@piefed.social Joined: 2024-11-21 |
I would say your edit: what is the output from |
||
| 5 | |||
zarkanian
sh.itjust.works
zarkanian@sh.itjust.worksJoined: 2024-01-11 |
I would say your ls shouldn't be working that way: when it detects that it's standard output isn't a terminal, it shouldn't be outputting the control codes. Which makes me wonder what version of ls you are running. edit: what is the output from alias ls and what happens if you run \ls --help | less?
I'm using the fish shell. I checked, and there are no aliases for |
||
| 1 | |||
|
tangeli
piefed.social
tangeli@piefed.social Joined: 2024-11-21 |
I'm using the fish shell. I checked, and there are no aliases for ls or less. \ls --help | less gives me the same result as ls --help | less.
That's surprising. I have an older version of coreutils (9.7 from Debian 13) that doesn't produce the links and formatting. I'm running bash and the behaviour you're experiencing isn't reproduced. Aliases aside, I wouldn't expect the shell to be the cause. None the less, I installed version 4.0.2 of the fish shell and ran the same command in it and didn't see any control characters. But that's not really surprising - my old version of ls doesn't produce them. So I ran If I run You might check your environment variables to see if CLICOLOR_FORCE is set. Otherwise, I am out of ideas. |
||
| 1 | |||
|
elmicha
feddit.org
elmicha@feddit.org Joined: 2024-06-27 |
What's the value of $LESSOPEN? These URLs in a manual page look strange. |
||
| 1 | |||
|
Dultas
lemmy.world
Dultas@lemmy.world Joined: 2023-08-03 |
I'm using the fish shell. I checked, and there are no aliases for ls or less. \ls --help | less gives me the same result as ls --help | less.
What terminal are you using? |
||
| 1 | |||
thingsiplay
lemmy.ml
thingsiplay@lemmy.mlJoined: 2026-01-09 |
Ah ls has an option for this: Looks like an issue with ls. I feel helpless. |
||
| 1 | |||
CallMeAl (like Alan)
piefed.zip
CallMeAl@piefed.zipJoined: 2025-12-14 |
Per the Gnu Coreutils NEWS file:
This has nothing to do with less (or bash or fish). It is a new behavior as of Coreutils 9.10. It is to preserve the hyperlinks in the help output of ls, cp, rm, mv, etc. In default mode, less catches these control codes and escapes them so you see the visual escape codes. If you use Debian 13, which ships Coreutils 9.7 does not have the change and cannot reproduce the behavior. |
||
| 14 | |||
|
esa
discuss.tchncs.de
syklemil@discuss.tchncs.de Joined: 2024-12-16 |
/usr/bin/ls --color=never --help | /usr/bin/less and /usr/bin/ls --color=never --help > ~/Desktop/lshelp.txt produces and contains the same characters, BTW. This happens in Bash and Zsh, using Kitty and Konsole terminals. So its not an issue with less, the shell or terminal. Meaning it might be an issue with ls itself. I have "ls (GNU coreutils) 9.11" from ls --version. Ah ls has an option f...
|
||
| 2 | |||
|
esa
discuss.tchncs.de
syklemil@discuss.tchncs.de Joined: 2024-12-16 |
Per the Gnu Coreutils NEWS file: All commands now markup option names in --help and man pages, with bold attributes, and hyperlinks into the online manual on gnu.org. The links can be configured with the --enable-manual-url configure option, and the bold highlighting with --disable-bold-man-page-references. At runtime all markup can be disabled with the TERM=dumb env var value. This has nothing...
You may want to tag your triple-backtick with something like
|
||
| 2 | |||
|
esa
discuss.tchncs.de
syklemil@discuss.tchncs.de Joined: 2024-12-16 |
You've gotten a longer reply to this, but just to make it clear: No, that's how it's supposed to work.
|
||
| 4 | |||
CallMeAl (like Alan)
piefed.zip
CallMeAl@piefed.zipJoined: 2025-12-14 |
You may want to tag your triple-backtick with something like text or plain so you don't get auto-inferred syntax highlighting. E.g: All commands now markup option names in --help and man pages,
good one, thanks! |
||
| 2 | |||
|
TrollAccount69
lemmy.ml
TrollAccount69@lemmy.ml Joined: 2026-08-10 |
Sounds like it was more trouble than it was worth! |
||
| 7 | |||
| Post Reply |
Back to top |