Rob van der Woude's Scripting Pages
Powered by GeSHi

Source code for which.ps

(view source code of which.ps as plain text)

  1. # Which.ps1,  Version 1.00
  2. # Locate the specified program file
  3. # Port of Unix' WHICH command
  4. #
  5. # Usage:  WHICH.PS1  filename[.ext]
  6. #
  7. # Where:  "filename" is a file name only: no drive or path
  8. #
  9. # Written by Rob van der Woude
  10. # http://www.robvanderwoude.com
  11.  
  12. param([string] $file=$(throw "Please specify a filename."))
  13. (get-command $file).Definition
  14.  

page last modified: 2024-04-16; loaded in 0.0164 seconds