Mint icon indicating copy to clipboard operation
Mint copied to clipboard

mint which usage

Open brzzdev opened this issue 1 year ago • 1 comments

Hi,

I'm trying to use mint which in a script to get the executable path. It seems like I can either get the output including the loading string

mint which example
🌱 Finding latest version of example
/path/example

which isn't useful in this instance

or I use -s which I would expect to just strip the loading string, but instead I get an empty string

mint which example -s

Am I missing something?

brzzdev avatar Jun 17 '23 23:06 brzzdev

Hmm, silent does stop all standard out, and there's currently no way to prevent the loading message, other than if you locked down the version of example (either by a Mintfile or by providing the version with mint which [email protected]). This will also make the command faster, as it doesn't have to hit the network.

Alternatively you can run some other command after to just get the last line like mint which example | tail -n 1

yonaskolb avatar Jun 19 '23 02:06 yonaskolb