in reply to Re: path to perl install directory
in thread path to perl install directory

Hi, this is actual documentation, I just bolded a few items
$ help assoc
Displays or modifies file extension associations
ASSOC [.ext[=[fileType]]]

  .ext      Specifies the file extension to associate the file type with
  fileType  Specifies the file type to associate with the file extension
Type ASSOC without parameters to display the current file associations. If ASSOC is invoked with just a file extension, it displays the current file association for that file extension. Specify nothing for the file type and the command will delete the association for the file extension.

$ help ftype
Displays or modifies file types used in file extension associations
FTYPE [fileType[=[openCommandString]]]
  fileType  Specifies the file type to examine or change
  openCommandString Specifies the open command to use when launching files
                    of this type.
Type FTYPE without parameters to display the current file types that have open command strings defined. FTYPE is invoked with just a file type, it displays the current open command string for that file type. Specify nothing for the open command string and the FTYPE command will delete the open command string for the file type. Within an open command string %0 or %1 are substituted with the file name being launched through the assocation. %* gets all the parameters and %2 gets the 1st parameter, %3 the second, etc. %~n gets all the remaining parameters starting with the nth parameter, where n may be between 2 and 9, inclusive. For example:
    ASSOC .pl=PerlScript
    FTYPE PerlScript=perl.exe %1 %*
would allow you to invoke a Perl script as follows:
    script.pl 1 2 3
If you want to eliminate the need to type the extensions, then do the following:
    set PATHEXT=.pl;%PATHEXT%
and the script could be invoked as follows:
    script 1 2 3

Replies are listed 'Best First'.
Re^3: path to perl install directory
by Marshall (Canon) on Dec 14, 2010 at 07:49 UTC
    Good info! From reading the OP's question a couple of times, I suspect the OP has the misunderstanding that a different #!path_to_perl is required under Windows. It is not.

    If this is the case, then I recommend using the GUI as outlined in my post to "set the Windows stuff once and forget it".

    As an additional note: "hey, grep isn't a Windows command!"...just install a gnu version. I use this one: GNU Grep 2.5.4 for Windows. There is a single step installer that works fine.

      what does OP stand for btw?
        OP => Original Poster
Re^3: path to perl install directory
by srinikar (Novice) on Dec 14, 2010 at 09:33 UTC
    awesome