Discussion:
[tex-live] "tlmgr list" became unusable
jack
2017-12-10 16:44:04 UTC
Permalink
For years, "tlmgr list" would output a list of all packages and
collections, on one line each. Those that were installed had their line
begin with an "i".

Today I needed "tlmgr list", and when I did it, I found that it now spits
out so much verbose information that it's unusuable. For each item, it
displays the same thing that "tlmgr info [item]" would display. I.e., the
whole record for it, "longdesc" and all.

I think this is breakage, and should be fixed. The old output is useful
for quickly scanning for things. Also, you can easily use it to get a
list of all your installed/uninstalled packages and collections. (Just
grep for those that start with "i", and then sed out the colon and
everything after it.)

I can't imagine what the point of the new output is. If one wanted to see
*all* of that, one would just examine the file "texlive.tlpd", or run
"tlmgr info" with no arguments.

Moreover, the new out put is severely slow, because the amount of
information to be processed and displayed is now so large.

-jack
jack
2017-12-10 16:57:41 UTC
Permalink
Post by jack
If one wanted to
see *all* of that, one would just examine the file "texlive.tlpd", or run
"tlmgr info" with no arguments.
I see that according to "man tlmgr", even the latter is supposed to do the
one-line-each output.

Bisection of my local git repo reveals that this change was introduced
with whatever the last update that required "tlmgr update --self" was. It
appears that this is the one that changed the version of tlmgr to 45838.

-jack
Siep Kroonenberg
2017-12-10 19:42:38 UTC
Permalink
Post by jack
For years, "tlmgr list" would output a list of all packages and
collections, on one line each. Those that were installed had their line
begin with an "i".
Today I needed "tlmgr list", and when I did it, I found that it now spits
out so much verbose information that it's unusuable. For each item, it
displays the same thing that "tlmgr info [item]" would display. I.e., the
whole record for it, "longdesc" and all.
Try

tlmgr info --data "name,localrev,shortdesc"

instead. Installed packages have a non-zero value for localrev. The
output is in csv format.
--
Siep Kroonenberg
Enrico Gregorio
2017-12-10 20:01:58 UTC
Permalink
Post by Siep Kroonenberg
Post by jack
For years, "tlmgr list" would output a list of all packages and
collections, on one line each. Those that were installed had their line
begin with an "i".
Today I needed "tlmgr list", and when I did it, I found that it now spits
out so much verbose information that it's unusuable. For each item, it
displays the same thing that "tlmgr info [item]" would display. I.e., the
whole record for it, "longdesc" and all.
Try
tlmgr info --data "name,localrev,shortdesc"
instead. Installed packages have a non-zero value for localrev. The
output is in csv format.
This somewhat works, but is not the same as the documentation
advertises:

info [option...] [collections|schemes|pkg…]

With no argument, lists all packages available at the package repository, prefixing those already installed with i.
[…]
The former actions show and list are merged into this action, but are still supported for backward compatibility.

Ciao
Enrico
Norbert Preining
2017-12-11 01:54:00 UTC
Permalink
Post by jack
For years, "tlmgr list" would output a list of all packages and
collections, on one line each. Those that were installed had their line
begin with an "i".
Today I needed "tlmgr list", and when I did it, I found that it now spits
out so much verbose information that it's unusuable. For each item, it
Sorry, a feature loss during rewrite. Fixed in the repository. If you
want to fix it yourself till the next texlive.infra update, patch
texmf-dist/scripts/texlive/tlmgr.pl
with the following patch:
--- a/Master/texmf-dist/scripts/texlive/tlmgr.pl
+++ b/Master/texmf-dist/scripts/texlive/tlmgr.pl
@@ -1537,6 +1537,8 @@ sub action_info {
}
# loading of tlpdb is done below
}
+ } elsif (!$what || $what =~ m/^(collections|schemes)$/i) {
+ $fmt = "list";
} else {
$fmt = "detail";
}

Norbert

--
PREINING Norbert http://www.preining.info
Accelia Inc. + JAIST + TeX Live + Debian Developer
GPG: 0x860CDC13 fp: F7D8 A928 26E3 16A1 9FA0 ACF0 6CAC A448 860C DC13
jack
2017-12-11 18:11:40 UTC
Permalink
Post by Norbert Preining
Post by jack
For years, "tlmgr list" would output a list of all packages and
collections, on one line each. Those that were installed had their line
begin with an "i".
Today I needed "tlmgr list", and when I did it, I found that it now
spits out so much verbose information that it's unusuable. For each
item, it
Sorry, a feature loss during rewrite. Fixed in the repository. If you
want to fix it yourself till the next texlive.infra update, patch
texmf-dist/scripts/texlive/tlmgr.pl with the following patch: ---
a/Master/texmf-dist/scripts/texlive/tlmgr.pl +++
action_info { }
# loading of tlpdb is done below
}
+ } elsif (!$what || $what =~ m/^(collections|schemes)$/i) {
+ $fmt = "list";
} else {
$fmt = "detail";
}
Thanks, but the patch does not apply to tlmgr.pl. E.g., the original file
contains no "is done below" string. Perhaps this patch is against master
rather than what is available to users.

-jack
Siep Kroonenberg
2017-12-11 19:42:05 UTC
Permalink
Post by jack
Post by Norbert Preining
Post by jack
For years, "tlmgr list" would output a list of all packages and
collections, on one line each. Those that were installed had their line
begin with an "i".
Today I needed "tlmgr list", and when I did it, I found that it now
spits out so much verbose information that it's unusuable. For each
item, it
Sorry, a feature loss during rewrite. Fixed in the repository. If you
want to fix it yourself till the next texlive.infra update, patch
texmf-dist/scripts/texlive/tlmgr.pl with the following patch: ---
a/Master/texmf-dist/scripts/texlive/tlmgr.pl +++
action_info { }
# loading of tlpdb is done below
}
+ } elsif (!$what || $what =~ m/^(collections|schemes)$/i) {
+ $fmt = "list";
} else {
$fmt = "detail";
}
Thanks, but the patch does not apply to tlmgr.pl. E.g., the original file
contains no "is done below" string. Perhaps this patch is against master
rather than what is available to users.
Yes. The svn repository is available at
http://www.tug.org/svn/texlive/trunk/
--
Siep Kroonenberg
Norbert Preining
2017-12-12 00:11:15 UTC
Permalink
Post by jack
Thanks, but the patch does not apply to tlmgr.pl. E.g., the original file
Still, reading the code it would have been easy to find the place ;-)
--- tlmgr.pl.old 2017-12-12 09:09:44.385345881 +0900
+++ tlmgr.pl 2017-12-12 09:09:22.814532289 +0900
@@ -1524,6 +1524,8 @@
$fmt = "csv";
# the 1 is the silent mode!
init_tlmedia_or_die(1);
+ } elsif (!$what || $what =~ m/^(collections|schemes)$/i) {
+ $fmt = "list";
} else {
$fmt = "detail";
}


There are more changes in this area done, they will be pushed out from
tlcritical sooner or later.

Norbert

--
PREINING Norbert http://www.preining.info
Accelia Inc. + JAIST + TeX Live + Debian Developer
GPG: 0x860CDC13 fp: F7D8 A928 26E3 16A1 9FA0 ACF0 6CAC A448 860C DC13
Norbert Preining
2017-12-12 03:38:03 UTC
Permalink
Post by jack
Thanks, but the patch does not apply to tlmgr.pl. E.g., the original file
After today's update of texlive.infra this should be fixed for all
users.

Norbert

--
PREINING Norbert http://www.preining.info
Accelia Inc. + JAIST + TeX Live + Debian Developer
GPG: 0x860CDC13 fp: F7D8 A928 26E3 16A1 9FA0 ACF0 6CAC A448 860C DC13
Enrico Gregorio
2017-12-12 21:52:49 UTC
Permalink
Post by Norbert Preining
Post by jack
Thanks, but the patch does not apply to tlmgr.pl. E.g., the original file
After today's update of texlive.infra this should be fixed for all
users.
Indeed! Thanks!

Ciao
Enrico

Loading...