BTW, is it just lack of coffee or both the online manual page and the
GNU info manual section for GNU diff do not explain/specify the default output format? (Compare with IEEE 1003.1 [1].)
[1] https://pubs.opengroup.org/onlinepubs/9799919799/utilities/diff.html
On Sun, 17 Aug 2025 00:44:26 -0000 (UTC), Lawrence D’Oliveiro wrote:
I had to recheck “info diff” (the man page being insufficient inThe man page is little more than an option summary. The texinfo
this case) to refresh my memory of what context-diff looked like; I
would agree with the vast majority of open-source software
developers, that unified-diff is preferable.
manual describes the default output format here:
https://www.gnu.org/software/diffutils/manual/html_node/Detailed-Normal.html
Stéphane CARPENTIER <sc@fiat-linux.fr> wrote:
I never use "diff". I really don't like the way it's displayed. I'm using
"vimdiff" or "nvim -d" a lot, because at the same time it's easier to
see what I want and it's easier to make the right changes.
diff's default output is an 'ed script' which is not very human
readable at all.
The unified output (-u option) provides a 'diff' view that is much more ameniable to being understood by humans.
Lawrence D'Oliveiro <ldo@nz.invalid> wrote at 22:45 this Thursday (GMT):
On Thu, 14 Aug 2025 14:50:06 +0300, Anssi Saari wrote:
Lawrence D'Oliveiro <ldo@nz.invalid> writes:
What’s an obvious omission from his list? To me, it’s the “find” >>>> command.
Possibly or something like it. I just started looking into rawhide which >>> is another search tool. My interest is rawhide's ability to search for
tags in extended attributes. I've started adding tags to videos and
photos so I can search for those with rawhide.
The “find” command has the ability to execute external commands. Those can
produce output on their own, and/or their success/failure exit status can
be used as a filter on matching files.
To be fair, "find" can be a bit of a rabbithole to learn. I personally
only know the basics of -name, -iname, and -type.
On Sat, 16 Aug 2025 00:20:08 -0000 (UTC), candycanearter07 wrote:
Lawrence D'Oliveiro <ldo@nz.invalid> wrote at 22:45 this Thursday (GMT):
The “find” command has the ability to execute external commands.
Those can produce output on their own, and/or their success/failure
exit status can be used as a filter on matching files.
To be fair, "find" can be a bit of a rabbithole to learn.
The term for that is “deep” software: it doesn’t scare you with a
whole lot of complexity up front. Instead, it offers some initial
features that aren’t that hard to use, but the more you dig beneath
the surface, the more capabilities you find. This is why it’s good
that the man page is always handy: you can keep going back to it and discovering new things as you need them.
But lately what I use is "meld".
Laicolasse:~ # time find / -type d -newermt "2025-07-28" \
! -newermt "2025-07-31" 2>/dev/null | tee busqueda
Turned out that an automount was happening of an external nfs mount on "/mnt/nfs/Isengard/xfsRaid/", and that raid is big and slow, the search
took for ever.
On Fri, 15 Aug 2025 04:55:04 -0000 (UTC), Rene Kita wrote:
Charlie Gibbs <cgibbs@kltpzyxm.invalid> wrote:
Favourite one-liner:
grep foo * | cut -d: -f1 | uniq
Why not 'grep -l foo *'?
To “UUOC” (“Useless Use Of Cat”), we can add a new category: How about
“UUOCP” (“Useless Use Of Complicated Pipelines”)?
On Tue, 19 Aug 2025 12:06:04 +0200, Carlos E.R. wrote:
But lately what I use is "meld".
<https://meldmerge.org/> -- seems to do a lot.
On Tue, 19 Aug 2025 12:28:49 +0200, Carlos E.R. wrote:
Laicolasse:~ # time find / -type d -newermt "2025-07-28" \
! -newermt "2025-07-31" 2>/dev/null | tee busqueda
I never knew about -newermt. Why? Because it’s not listed in the man page, though it is documented in the info file.
Nope. Scratch that. It *is* documented in the man page, in the form of “- newerXY” with explanations of what “X” and “Y” can be.
Turned out that an automount was happening of an external nfs mount on
"/mnt/nfs/Isengard/xfsRaid/", and that raid is big and slow, the search
took for ever.
Wouldn’t “-xdev” (“don’t descend directories on other filesystems”) have
fixed that?
For example, after an update an rpm based system there are a lot of
.rpmold or .rpmorig files. I compare the config files with the other
version and easily copy over the new or the old lines into the
active file.
On 2025-08-20 02:59, Lawrence D’Oliveiro wrote:
Wouldn’t “-xdev” (“don’t descend directories on other filesystems”)
have fixed that?
But I need to scan both root and home, which are separate filesystems.
I just saw:
-xautofs
Don't descend directories on autofs filesystems.
which I have tested now and works! I feared it might work with the
classic automount but not with systemd. It does work. Nice!
On Wed, 20 Aug 2025 12:32:16 +0200, Carlos E.R. wrote:
On 2025-08-20 02:59, Lawrence D’Oliveiro wrote:
Wouldn’t “-xdev” (“don’t descend directories on other filesystems”)
have fixed that?
But I need to scan both root and home, which are separate filesystems.
I was going to say, explicitly list both / and /home (and whatever else)
as directories to search in, with -xdev to avoid entering any other mount points, but ...
I just saw:
-xautofs
Don't descend directories on autofs filesystems.
which I have tested now and works! I feared it might work with the
classic automount but not with systemd. It does work. Nice!
... that is probably simpler. ;)
However, it’s not present on my “find” version (findutils 4.10.0-3, part
of Debian Unstable as of last month).
On 2025-08-21 00:21, Lawrence D’Oliveiro wrote:
However, it’s not present on my “find” version (findutils 4.10.0-3,
part of Debian Unstable as of last month).
Wow. And I'm using openSUSE Leap 15.6, which has ancient versions of
almost everything.
Telcontar:~ # rpm -q findutils
findutils-4.8.0-150300.3.3.2.x86_64
Weird.
How about a list of favourite options to common commands?
Mine is "ls -ltr", which shows files in chronological order.
On Thu, 21 Aug 2025 02:29:57 +0200, Carlos E.R. wrote:
On 2025-08-21 00:21, Lawrence D’Oliveiro wrote:
However, it’s not present on my “find” version (findutils 4.10.0-3, >>> part of Debian Unstable as of last month).
Wow. And I'm using openSUSE Leap 15.6, which has ancient versions of
almost everything.
Telcontar:~ # rpm -q findutils
findutils-4.8.0-150300.3.3.2.x86_64
Weird.
The patch is actually older than that, dating from 2009 <http://fedora.riscv.rocks:3000/rpms/findutils/commit/29ef88d6c3ded9300b7c0c1b1a29321b287cab7a?style=unified&whitespace=ignore-all&show-outdated=>.
But it looks like it was never upstreamed into the GNU version <https://www.gnu.org/software/findutils/manual/html_mono/find.html>.
Nuno Silva <nunojsilva@invalid.invalid> writes:
BTW, is it just lack of coffee or both the online manual page and the
GNU info manual section for GNU diff do not explain/specify the default
output format? (Compare with IEEE 1003.1 [1].)
[1] https://pubs.opengroup.org/onlinepubs/9799919799/utilities/diff.html
The man page is little more than an option summary. The texinfo manual describes the default output format here:
https://www.gnu.org/software/diffutils/manual/html_node/Detailed-Normal.html
Sysop: | DaiTengu |
---|---|
Location: | Appleton, WI |
Users: | 1,064 |
Nodes: | 10 (0 / 10) |
Uptime: | 152:43:24 |
Calls: | 13,691 |
Calls today: | 1 |
Files: | 186,936 |
D/L today: |
2,522 files (731M bytes) |
Messages: | 2,411,051 |