[platypus-dev] Re: Bug with '$1' variable in Platypus 3.2?

  • From: Aaron Madlon-Kay <amake@xxxxxxx>
  • To: platypus-dev@xxxxxxxxxxxxx
  • Date: Thu, 3 Nov 2005 13:05:51 -0600

Hello.

It's your responsibility to properly escape $1 when you use it in your script, as in "$1" etc. I have had no problems running Playtpus- built apps that use $1 from within folders containing spaces, parentheses, etc.

-Aaron


On 2005/11/03, at 13:02, Tony Thomson wrote:

Hi,

I just found Platypus, and am having some fun with it. However, I've run into a problem.

I believe the $1 variable, which is supposed to hold the path to the current directory has a bug.

If the current path contains folders with a space in their name, the $1 variable doesn't contain the escape character for spaces.

Example:
My path is:
/Tools/OpenGL Tools/current/

$1 contains:
"/Tools/OpenGL Tools/current/
$1 should contain:
"/Tools/OpenGL\ Tools/current/

Because #1 doesn't contain the escape character, using it in a script doesn't work.
The shell looks for:
/Tools/OpenGL


Am I just doing something wrong? If this is indeed a bug, any chance it can go on the list for 3.3?

Thanks,
Tony Thomson



Other related posts: