Skip to content

danilofuchs/how

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

30 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

How

which for your executables.

A Linux/MacOS CLI to discover which package manager installed a command.

Useful when updating, removing, or troubleshooting packages.

Usage

how <command>

Tells you which package managers installed <command>. Also resolves the command via type first, so you see whether it's an executable path, a shell alias, function, or builtin — and alias targets are followed before the package-manager checks run.

Example

$ how git
> git installed by apt
$ how starship
> starship installed by cargo
> starship installed by brew

Installation

You must have Rust installed. If you don't, you can install it with rustup.

Then, run:

cargo install --git https://github.com/danilofuchs/how.git

Requires a POSIX sh in PATH (used to invoke type).

Supported package managers

  • apt
  • dnf / rpm (Fedora, RHEL)
  • pacman (Arch)
  • Homebrew / Linuxbrew
  • MacPorts
  • snap
  • npm -g
  • pnpm -g
  • yarn global
  • bun
  • pip and pip3
  • pipx
  • uv tool
  • gem
  • cargo
  • go install
  • asdf
  • mise
  • nvm
  • corepack
  • pyenv
  • rbenv

Contributing

  1. Install Rust
  2. Clone this repository

To run the CLI:

cargo run <command>

About

which, finds which package manager installed a command

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors