From time to time I have wanted to use latest version for gstreamer and its plugins in one of the systems I admin. I think that would be really useful if I was able to run eix with some option that would output with format =<category>/<name>-<latest_version_in_tree> (currently, only " --only-names" option exist) Then, I could simply run: eix -I gst --latest-version (for example) > /etc/portage/package.keywords/gst It could also be useful for other cases :-) Thanks Reproducible: Always
With >=eix-0.18.0 you can specify such things in the FORMAT string, see e.g. the discussion starting from http://forums.gentoo.org/viewtopic-t-278819-postdays-0-postorder-asc-start450.html (if the link gets posted broken: It should be one line without spaces).
Another attempt for the link (a "-" was missing): http://forums.gentoo.org/viewtopic-t-278819-postdays-0-postorder-asc-start-450.html
I am reading it just now, thanks
So should this report be closed?
I would prefer to keep it opened as I still think that an option would be better than current way to handle this situation, because it seems to be a bit hard to find (at least for me, maybe other people more familiarized with eix will disagree but...)
Such an option will not be added: There are just too many variants which different people might consider the most reasonable. For example, "latest_version_in_the_tree" means perhaps for you the really latest version in the tree, which however, might be a -9999 live ebuild. So for another person it should mean the latest non-masked version; or the latest ~arch version; or the latest stable version? Moreover, it could mean the latest such a version for each slot of a package. Or it could mean the latest version of each slot from which you have installed something or installed something with a strictly smaller version; and then how about "higher" slots? The list of possibilities is close to infinite - that's why I think, people should program in a (usually rather tiny) script what they really want; eix should only provide the means to do this. Actually, I was even thinking about removing the --only-names option, since it is now some sort of anachronism.
My initial suggestion was to do it for showing latest version in ~arch, since they are usually the candidates to go to stable "soon"
(In reply to comment #7) > My initial suggestion was to do it for showing latest version in ~arch This is really simple: eix --pure-packages --format '<bestversion*:NAMEVERSION>' eix --pure-packages --format '<bestversion*:EQNAMEVERSION>' eix --pure-packages --format '<bestslotversions*:NAMEVERSION>' Adding additional switches would not make it much easier, only harder to modify if you want some slight variations (like the three variants): Better make an alias (or a tiny scriptfile) if you need in frequently, but probably you will need such things only in scripts, anyway.
(In reply to comment #8) > This is really simple: > > eix --pure-packages --format '<bestversion*:NAMEVERSION>' > eix --pure-packages --format '<bestversion*:EQNAMEVERSION>' > eix --pure-packages --format '<bestslotversions*:NAMEVERSION>' > Yes, you are true, thanks a lot for the info and sorry for the inconvenience Only a few final suggestions/questions: - Are "bestversion" and "best" the same? I say that because I am unable to find "bestversion" in eix manpage, and "best" seems to work similar for me - NAMEVERSION and EQNAMEVERSION seems to output the same for me, also, I couldn't find any reference to them in eix manpage - For now, I think that I will use this line: $ eix -I gst --format '=<category>/<name>-<bestshort*:NAMEVERSION>' | sed -e s/"(~)"// | cut -f1 -d! is there any other way for dropping "!t" (or similar) and "(~)"? If not, no problem, I have no problem in use sed/cut for that Thanks and best regards
I was talking about eix-0.18.*. It seems you had tried with an earlier version - the examples will not work there properly. Only in eix-0.18.* the powerful approach to the formatstring was added: All things like <...:VAR> and the example variables VARVERSION and EQVARVERSION have been introduced only here. Definitely, "bestversion", VARVERSION, and EQVARVERSION are documented in the manpage of eix-0.18.*. Moreover, VARVERSION and EQVARVERSION only output the pure version number, no stability/mask tags or other things (if you would want the latter you would have to call other variables). This should answer your question how to get rid of these tags - they just do not occur in the examples I gave (if you use them with the correct eix version). Moreover, with eix-0.18.* your example will do something completely else. (Actually, neither my nor your example are valid syntax on earlier versions of eix - it is just by pure accident and due to sloppy syntax checking of earlier eix versions that they accept these formats without throwing an error). Yes, indeed, all these things have completely changed in eix-0.18.* ...
OK Indeed, I am using current stable eix, usually I used to install testing eix always, but since it started to use xz-utils, I got blockers due other apps still requiring lzma-utils. Then, I will wait a bit until install it Thanks :-)
(In reply to comment #11) > OK > > Indeed, I am using current stable eix, usually I used to install testing eix > always, but since it started to use xz-utils, I got blockers due other apps > still requiring lzma-utils. Then, I will wait a bit until install it > > Thanks :-) > Sorry, this will be off topic. But if any package still needs solely lzma-utils, then it is a bug. wrt bug 279871 Considering that but is closed, it means that you can safely unmerge lzma-utils and emerge xz-utils. Portage will do this for you if lzma-utils is not in your world file.