On Sat, 2023-07-01 at 08:37 -0700, stan via users wrote:
> > FYI to install a command you can do this:
> > 
> > $ sudo dnf install /usr/bin/xrandr
> > $ sudo dnf install /usr/bin/inxi
> > Etc.
> 
> Robert has been using Fedora and on this list for years.  I'm not
> sure
> if the above installing commands were his automatic response because
> he didn't say, but it should have been.  And if the install command
> failed with no package, he should know to use
> rpm -qf /usr/bin/xrandr or rpm -qf /usr/sbin/xrandr
> to find out which package owns that executable so he can install it.

I had a similar reaction until I checked. It turns out that dnf is
smart enough to determine the package from the executable name:

$ sudo dnf install /usr/bin/xrandr
Last metadata expiration check: 2:57:58 ago on Sat 01 Jul 2023 15:12:20
BST.
Package xrandr-1.5.2-2.fc38.x86_64 is already installed.
Dependencies resolved.
Nothing to do.
Complete!

From 'man dnf':

       dnf install vim
              DNF  will  automatically  recognize  that vim is not a package 
name, but will look up and install a package that provides vim with all the 
required dependencies.
              Note: Package name match has precedence over package provides 
match.


You learn something new every day.

poc
_______________________________________________
users mailing list -- [email protected]
To unsubscribe send an email to [email protected]
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/[email protected]
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue

Reply via email to