<div dir="ltr"><div>I rather like this idea. I'm not sure of the complexity but it would come in handy in a number of places.</div><br clear="all"><div><div dir="ltr" class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div>—Mark<br></div><div>_______________________<br>Mark E. Anderson <<a href="mailto:mark@macports.org" target="_blank">mark@macports.org</a>><br></div><div><a href="https://trac.macports.org/wiki/mark" target="_blank">MacPorts Trac WikiPage</a><br></div><div><a href="https://github.com/markemer" target="_blank">GitHub Profile</a><br></div><div><br></div></div></div></div><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Dec 2, 2021 at 3:25 PM Gregory Anders <<a href="mailto:greg@gpanders.com">greg@gpanders.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">A feature I would personally like to see in MacPorts is the ability to create <br>
my own select groups and add arbitrary programs to it. I am happy to create a <br>
prototype PR for review, but wanted to see if this had been proposed or <br>
considered before.<br>
<br>
What I have in mind is a new subcommand to 'port select', e.g. '--add' that <br>
could be used like so:<br>
<br>
sudo port select --add GROUP TARGET OPTIONS...<br>
<br>
Presently, each port that has multiple options has to provide its own 'select' <br>
companion port. Not all ports have these and it can be tedious to create them <br>
for every port that needs it. This is especially true for Python and Lua ports <br>
that install executables: users often want to use the plain executable name <br>
without the version information which is only possible with a select group.<br>
<br>
This would also solve another personal pain point for me: the current inability <br>
to use a plain 'clangd' command installed via MacPorts. I proposed adding <br>
clangd to the clang_select group in #10558, but it was closed (for perfectly <br>
valid reasons). However, if I were able to create my own select group I could <br>
still accomplish this with no compatibility issues for the greater MacPorts <br>
project:<br>
<br>
sudo port select --add clangd clangd clangd-mp-13<br>
sudo port select --set clangd clangd-mp-13<br>
<br>
A similar situation exists for e.g. universal-ctags, which currently installs <br>
itself as 'uctags'. I would love to be able to create my own "ctags_select" <br>
group that allows me to use universal-ctags as plain 'ctags'.<br>
<br>
sudo port select --add ctags ctags ctags uctags<br>
sudo port select --set ctags uctags<br>
<br>
I hope the above provides enough motivation for the feature. Please let me know <br>
your thoughts. I will start work on a prototype PR if I get a positive (or at <br>
least, non-negative) response.<br>
<br>
Thanks!<br>
<br>
Greg<br>
</blockquote></div>