I'm aware of %~dp0, which represents the fully expanded directory that contains the batch script, but what I'm looking for is either:
- a method to invoke the batch script from Perl in such a manner that allows me to use the batch script without modification and have all directories in it be in relation to the batch script location
- a single statement I can put in the batch script that is a flag to use the location of the batch script as the starting point for all directories
I'm currently invoking the batch script using this method in Perl:
`"../run.bat" -f $ARGV[$#ARGV]`;
and then capturing the output and doing processing to it.