logo

utils-std

Collection of commonly available Unix tools git clone https://anongit.hacktivis.me/git/utils-std.git/

which.1 (882B)


  1. .\" utils-std: Collection of commonly available Unix tools
  2. .\" Copyright 2017 Haelwenn (lanodan) Monnier <contact+utils@hacktivis.me>
  3. .\" SPDX-License-Identifier: MPL-2.0
  4. .Dd October 12, 2024
  5. .Dt WHICH 1
  6. .Os
  7. .Sh NAME
  8. .Nm which
  9. .Nd locate executable within PATH
  10. .Sh SYNOPSIS
  11. .Nm
  12. .Op Fl as
  13. .Ar name...
  14. .Sh DESCRIPTION
  15. The
  16. .Nm
  17. utility scans
  18. .Ev PATH
  19. for each given executable
  20. .Ar name ,
  21. unless it contains a slash where then
  22. .Ar name
  23. is simply printed out.
  24. .Pp
  25. .Nm
  26. shall not be used when the standard
  27. .Xr sh 1
  28. builtin
  29. .Cm command
  30. .Fl v
  31. .Ar name
  32. can be used instead.
  33. .Sh OPTIONS
  34. .Bl -tag -width _a
  35. .It Fl a
  36. List all matching executables.
  37. .It Fl s
  38. Do not print executable names.
  39. .El
  40. .Sh EXIT STATUS
  41. .Ex -std
  42. .Sh HISTORY
  43. A
  44. .Nm
  45. command first appeared in
  46. .Bx 3.0 .
  47. .Pp
  48. The
  49. .Fl a
  50. option first appeared in
  51. .Ox 2.3 .
  52. .Sh AUTHORS
  53. .An Haelwenn (lanodan) Monnier Aq Mt contact+utils@hacktivis.me