Unfortunately cfexecute doesn't work correctly with argument which contains
spaces. (bugid 50604)
# It's Linux/Unix only.

I think you may create custom java cfx for workaround.
# use Runtime.getRuntime().exec(String []) instead of
Runtime.getRuntime().exec(String)

sorry for inconvenience.

Thanks,
--
Hiroshi

>-----Original Message-----
>From: Hugo Ahlenius [mailto:[EMAIL PROTECTED]
>Sent: Monday, November 03, 2003 8:59 AM
>To: CF-Talk
>Subject: cfexecute on unix
>
>
>Hi,
>
>I have encounted a problem in our migration between our old
>Solaris box running 4.5 to the new Solaris machine -- running CFMX.
>
>I try to cfexecute rm to remove a directory tree, recursively.
>It is not a permissions problem, since CF created the whole
>tree (and I have played with chmod to make that is not the problem).
>
>I try to:
><cfexecute name="/bin/rm"
> arguments="-rf ""#dirTree#"""/>
>
>It works fine without quotes around the path *as long as the
>path does not contain spaces*. Quotes (as above) does not work
>at all. I also tried to REReplace(dirTree," ", "\ ","ALL") to
>escape any spaces -- but no. Another thing I looked at was to
>make arguments an array beforehand, with "-rf" as the first
>item in the array, and the tree-var as the second (tried both
>and without double-quotes).
>
>Any tips?
>
>Thanks,
>Hugo
>
>
>
>
>-------------------------------------------------------------
>Hugo Ahlenius                  E-Mail: [EMAIL PROTECTED]
>Project Officer                Phone:            +46 8 230460
>UNEP GRID-Arendal              Fax:              +46 8 230441
>Stockholm Office               Mobile:         +46 733 467111
>                               WWW:       http://www.grida.no
>-------------------------------------------------------------

[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]

Reply via email to