Return-Path: X-Original-To: apmail-incubator-flex-dev-archive@minotaur.apache.org Delivered-To: apmail-incubator-flex-dev-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id C9D67D0BA for ; Thu, 23 Aug 2012 15:44:44 +0000 (UTC) Received: (qmail 79651 invoked by uid 500); 23 Aug 2012 15:44:44 -0000 Delivered-To: apmail-incubator-flex-dev-archive@incubator.apache.org Received: (qmail 79618 invoked by uid 500); 23 Aug 2012 15:44:44 -0000 Mailing-List: contact flex-dev-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: flex-dev@incubator.apache.org Delivered-To: mailing list flex-dev@incubator.apache.org Received: (qmail 79605 invoked by uid 99); 23 Aug 2012 15:44:44 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 23 Aug 2012 15:44:43 +0000 X-ASF-Spam-Status: No, hits=-1.3 required=5.0 tests=FRT_ADOBE2,RCVD_IN_DNSWL_MED,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of mark.kessler.ctr@usmc.mil designates 138.162.128.21 as permitted sender) Received: from [138.162.128.21] (HELO usmcquanio03.nmci.usmc.mil) (138.162.128.21) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 23 Aug 2012 15:44:37 +0000 Received: from gate22-quantico.nmci.usmc.mil (HELO mcusquaneg01v.mcdsus.mcds.usmc.mil) ([138.162.128.52]) by usmcquanio03.nmci.usmc.mil with ESMTP; 23 Aug 2012 09:40:34 -0400 Received: from mcusquanez26v.mcdsus.mcds.usmc.mil ([138.156.149.182]) by mcusquaneg01v.mcdsus.mcds.usmc.mil with Microsoft SMTPSVC(6.0.3790.4675); Thu, 23 Aug 2012 11:44:07 -0400 X-MimeOLE: Produced By Microsoft Exchange V6.5 Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Subject: RE: Getting Mustella to work. Date: Thu, 23 Aug 2012 11:44:02 -0400 Message-ID: <0E7CF6486AC44249B0B674C6760449B402FDEBE2@mcusquanez26v.mcdsus.mcds.usmc.mil> In-Reply-To: X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: Getting Mustella to work. Thread-Index: Ac2BPt3dm4tQq1lxQy+CW396QLYhgAAA8KKQ References: <0E7CF6486AC44249B0B674C6760449B402FDEA8D@mcusquanez26v.mcdsus.mcds.usmc.mil> From: "Kessler CTR Mark J" To: X-OriginalArrivalTime: 23 Aug 2012 15:44:07.0342 (UTC) FILETIME=[21812CE0:01CD8146] X-Virus-Checked: Checked by ClamAV on apache.org String.split(regexpattern) can match pretty much anything. Definitely = would be able to comeup with a pattern to match embedded dashes. I'll see if I can come up with something that can properly strip down a = completed command with arguments. If you would give me a more complex = command line that would be great. I can test against it. Currently my setup uses few command line arguments and instead adds to = the "-load-config+=3Dmycustomconfig.xml" -----Original Message----- From: Peter Ent [mailto:pent@adobe.com]=20 Sent: Thursday, August 23, 2012 10:52 To: flex-dev@incubator.apache.org Subject: Re: Getting Mustella to work. I tried something like that, but there are options like: -source-path=3D = with a hyphen in the option and a couple that begin with double hyphens. = I started to switch over to String.split(" -") to break apart on the space+dash but then ran into this mysterious problem of mxmlc not liking the arguments it was given, even though, as far as I can tell, it was = getting the same ones in the same order. Obviously that wasn't the case, = but had trouble tracking it down, so it is on hold for now while we get = the tests to run, unless someone else wants to take a stab at it. --peter On 8/23/12 10:43 AM, "Kessler CTR Mark J" wrote: >I'm not sure what Mustella is written in, but would something generic=20 >like this work? > >If a string needs to be turned into an array then maybe... Use the "-"=20 >as the first delimiter to break apart the options and use a temp array. = >Then use the "=3D" to break out the names from the values. > >Keeping two arrays with the same number of elements. One array stores=20 >the argument name and the second argument value. > >//Declare arrays/string >string [] saNames =3D {"Option1", "Option2", "Option3"}; string []=20 >saValues =3D {"My value with spaces", "test2", "test 3"}; string=20 >sCombinedOptions =3D ""; > >//Loop through all elements in arrays >for (;;) >{ > //Combine names / values. > sCombinedOptions +=3D saNames[currentItem] + "=3D""" +=20 >saValues[currentItem] + """ "; } > > >//Add the command line and options. >"path\mxmlc.exe" + " " + sCombinedOptions; > > >-----Original Message----- >From: Peter Ent [mailto:pent@adobe.com] >Sent: Thursday, August 23, 2012 9:33 >To: flex-dev@incubator.apache.org >Subject: Re: Getting Mustella to work. > >That ought to work, but does not. The Mustella code pieces together a=20 >large string with all of the options on it, then turns the string into=20 >a String[] by using space as the delimiter. Thus > >-source-path=3D"C:\Program Files\Common Files\Microsoft=20 >Shared\MSInfo\MSInfo32.exe" > >turns into >[] =3D -source-path=3D"C:\Program Files\Common [] =3D Files\Microsoft = [] =3D=20 >Shared\MSInfo\MSInfo32.exe" > >And it does this several times (turning the array into a string,=20 >inserting other args, back to an array) to build up the argument list. >Ultimately, the array of options is passed over to mxmlc to execute, so = >it does need to turn into an array of options. I was working on putting = >everything into an ArrayList but more and more code needed to change=20 >and then I was getting errors from mxmlc saying parameters were being=20 >mixed which I didn't understand since it was getting the same=20 >parameters in the same order. > >So I have to re-think the approach. > >--peter > >On 8/23/12 6:59 AM, "Kessler CTR Mark J" >wrote: > >>I know this may sound silly, but windows deals with the spaces in path = >>using quotes around the whole path. Is there something similar with=20 >>Mustella? >> >>So a windows command prompt example, I could do something like the=20 >>following... >>"C:\Program Files\Common Files\Microsoft Shared\MSInfo\MSInfo32.exe" >> >> >>Whereas the old non spaced dos style naming convention would do this=20 >>without quotes.. >>c:\progra~1\common~1\micros~1\msinfo\MSInfo32.exe >> >> >>r/s >>-Mark >> >>-----Original Message----- >>From: Peter Ent [mailto:pent@adobe.com] >>Sent: Wednesday, August 22, 2012 9:20 >>To: flex-dev@incubator.apache.org >>Subject: Re: Getting Mustella to work. >> >>I have not have luck solving the problem. It is much trickier than I=20 >>anticipated. I am going to jump back into getting more tests to run=20 >>and think more about the problem. Operating systems have allowed=20 >>spaces in file names for many, many years and you'd think would be an=20 >>easily solvable problem (or not even a problem at all). >> >>--peter >> >>On 8/21/12 11:12 PM, "Justin Mclean" wrote: >> >>>Hi, >>> >>>If the space path issue was fixed you have more to add. Any luck with = >>>that yet? >>> >>>Justin >> >