Opened 3 months ago

#80 new enhancement

EXTPROC/#! and UNKNOWN_CMD should use full path

Reported by: Anton Monroe Owned by:
Priority: minor Milestone:
Component: Base Version: 3.09
Keywords: Cc:

Description

It looks like EXTPROC/#! does not pass the full path+name of a file to the external processor. For instance, if foo.cmd is in my %path, I type·

foo.cmd

4OS2 locates foo.cmd and finds that it starts with·

#!/usr/bin/gawk.exe -f

so 4OS2 executes

\usr\bin\gawk.exe -f foo.cmd

so if foo.cmd is not in the current directory, gawk.exe cannot find it. Granted, cmd.exe does the same, but it seems a serious limitation to the usefulness of EXTPROC and #!.
·
I see the same thing with the unknown_cmd alias. I use

alias unknown_cmd=unknown_cmd.btm

If foo.cmd starts with

#!/usr/bin/awk -f

4OS2 cannot find an awk command, so it calls unknown_cmd.btm as

unknown_cmd.btm \usr\bin\awk -f foo.cmd

My unknown_cmd.btm resolves the symlink, but it cannot know where foo.cmd is. It can only execute

\usr\bin\gawk.exe -f foo.cmd

Again, if foo.cmd is not in the current directory, gawk.exe cannot find it.

So my request is that 4OS2 should pass the full path+name when dealing with an EXTPROC/#! or unknown command. Which would be consistent with the way it already handles executable extensions.

Change History (0)

Note: See TracTickets for help on using tickets.