Farbflash projects: Imaging lingo table | 3-D scene list | Find all | Handler menu | Lingo message window

Ignore:
Timestamp:
12/18/09 15:29:03 (2 years ago)
Author:
alex
Message:

enclosed path to svn application and editor application in quotes, because that fails otherwise, if the path has spaces. what a fun it is to be able to have spaces in file and foldernames... :-(

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/lingosource/castlib1/svn_Utilities.ls

    r236 r242  
    171171              comm = mConvertHFS2Unix(me, thePath) 
    172172               
    173               theResult = mDoShellCmd(me, bbdiffpath & " --ignore-curly-quotes --ignore-spaces --wait --resume " &QUOTE& tempSrcPath &QUOTE&&QUOTE& comm &QUOTE && "2>&1", RETURN, 0, 1) 
     173              theResult = mDoShellCmd(me, QUOTE & bbdiffpath & QUOTE & " --ignore-curly-quotes --ignore-spaces --wait --resume " &QUOTE& tempSrcPath &QUOTE&&QUOTE& comm &QUOTE && "2>&1", RETURN, 0, 1) 
    174174               
    175175              -- since we used the --wait and the --resume switch, we will only come to this line AFTER the diff process in bbedit is finished 
     
    341341            bbeditBinary = mFindUnixAppInPath(me, "bbedit") 
    342342            if length(bbeditBinary) > 0 then 
    343               mDoShellCmd(me, bbeditBinary && QUOTE & mConvertHFS2Unix(me, thePath) & QUOTE) 
     343              mDoShellCmd(me, QUOTE & bbeditBinary & QUOTE && QUOTE & mConvertHFS2Unix(me, thePath) & QUOTE) 
    344344              exit 
    345345            end if 
     
    15341534   
    15351535  if count(castlibList) < 1 then 
    1536     theresult = mDoShellCmd(me, svnBinary && "update" && QUOTE & workingFolder & QUOTE, RETURN, 0, 1) 
     1536    theresult = mDoShellCmd(me, QUOTE & svnBinary & QUOTE && "update" && QUOTE & workingFolder & QUOTE, RETURN, 0, 1) 
    15371537     
    15381538  else 
     
    15451545      thePath = workingFolder & pdelim & "castlib" & num & pdelim 
    15461546       
    1547       ret = mDoShellCmd(me, svnBinary && "update" && "-r" && revisionNumber && QUOTE & thePath & QUOTE, RETURN, 0, 1) 
     1547      ret = mDoShellCmd(me, QUOTE & svnBinary & QUOTE && "update" && "-r" && revisionNumber && QUOTE & thePath & QUOTE, RETURN, 0, 1) 
    15481548      if count(ret) > 0 then theresult.add(ret[1]) 
    15491549       
     
    17351735              end if 
    17361736               
    1737               theresult = mDoShellCmd(me, svnBinary && "delete" && QUOTE & ufpath & QUOTE, RETURN, 0, 1) 
     1737              theresult = mDoShellCmd(me, QUOTE & svnBinary & QUOTE && "delete" && QUOTE & ufpath & QUOTE, RETURN, 0, 1) 
    17381738              if count(theresult) < 1 then 
    17391739                put "failed to svn delete member " & memref & " no result from svn?!" 
     
    17951795    end if 
    17961796     
    1797     theresult = mDoShellCmd(me, svnBinary && "ci --message" && QUOTE & msg & QUOTE && QUOTE & workingFolder & QUOTE, RETURN, 0, 1) 
     1797    theresult = mDoShellCmd(me, QUOTE & svnBinary & QUOTE && "ci --message" && QUOTE & msg & QUOTE && QUOTE & workingFolder & QUOTE, RETURN, 0, 1) 
    17981798     
    17991799    if count(theresult) > 0 then 
     
    18421842on mGetCurrentRevision me, svnBinary, WorkingFolder 
    18431843   
    1844   versionNumber = mDoShellCmd(me, svnBinary && QUOTE & WorkingFolder & QUOTE, RETURN, 0, 1) 
     1844  versionNumber = mDoShellCmd(me, QUOTE & svnBinary & QUOTE && QUOTE & WorkingFolder & QUOTE, RETURN, 0, 1) 
    18451845  if count(versionNumber) < 1 then return void 
    18461846  versionNumber = versionNumber[1] 
     
    21272127    mDisplayWaitStatusText me, "SVN update of:" && castlibList[r][3] 
    21282128     
    2129     theresult = mDoShellCmd(me, svnBinary && "update" && QUOTE & castlibList[r][3] & QUOTE, RETURN, 0, 1) 
     2129    theresult = mDoShellCmd(me, QUOTE & svnBinary & QUOTE && "update" && QUOTE & castlibList[r][3] & QUOTE, RETURN, 0, 1) 
    21302130     
    21312131    if count(theresult) < 1 then 
    2132       theresult = mDoShellCmd(me, svnBinary && "update" && QUOTE & castlibList[r][3] & QUOTE && "2>&1", RETURN, 0, 1) 
     2132      theresult = mDoShellCmd(me, QUOTE & svnBinary & QUOTE && "update" && QUOTE & castlibList[r][3] & QUOTE && "2>&1", RETURN, 0, 1) 
    21332133      if count(theresult) < 1 then 
    21342134        theError = theresult[1] 
     
    21442144     
    21452145     
    2146     theresult = mDoShellCmd(me, svnBinary && "status" && QUOTE & castlibList[r][3] & QUOTE, RETURN, 0, 1) 
     2146    theresult = mDoShellCmd(me, QUOTE & svnBinary & QUOTE && "status" && QUOTE & castlibList[r][3] & QUOTE, RETURN, 0, 1) 
    21472147     
    21482148    cnt = count(theresult) 
     
    21712171  mDisplayWaitStatusText me, "SVN commit for:" && pathStr 
    21722172   
    2173   theresult = mDoShellCmd(me, svnBinary && "ci --message" && QUOTE & msg & QUOTE & pathStr, RETURN, 0, 1) 
     2173  theresult = mDoShellCmd(me, QUOTE & svnBinary & QUOTE && "ci --message" && QUOTE & msg & QUOTE & pathStr, RETURN, 0, 1) 
    21742174   
    21752175   
     
    23662366  mDisplayWaitStatusText me, "SVN update for:" && workingFolder 
    23672367   
    2368   theresult = mDoShellCmd(me, svnBinary && "update" && QUOTE & workingFolder & QUOTE, RETURN, 0, 1) 
     2368  theresult = mDoShellCmd(me, QUOTE & svnBinary & QUOTE && "update" && QUOTE & workingFolder & QUOTE, RETURN, 0, 1) 
    23692369   
    23702370  if count(theresult) < 1 then 
    2371     theresult = mDoShellCmd(me, svnBinary && "update" && QUOTE & workingFolder & QUOTE && "2>&1", RETURN, 0, 1) 
     2371    theresult = mDoShellCmd(me, QUOTE & svnBinary & QUOTE && "update" && QUOTE & workingFolder & QUOTE && "2>&1", RETURN, 0, 1) 
    23722372    if count(theresult) < 1 then 
    23732373      theError = theresult[1] 
     
    23892389  ------- in order to implement #1 you can use a repeat loop just like the above repeat, which goes thorugh each castlib 
    23902390   
    2391   theresult = mDoShellCmd(me, svnBinary && "status" && QUOTE & workingFolder & QUOTE, RETURN, 0, 1) 
     2391  theresult = mDoShellCmd(me, QUOTE & svnBinary & QUOTE && "status" && QUOTE & workingFolder & QUOTE, RETURN, 0, 1) 
    23922392   
    23932393  cnt = count(theresult) 
     
    24132413         
    24142414      "?": -- newly added file 
    2415         mDoShellCmd(me, svnBinary && "add" && QUOTE & answ & QUOTE, RETURN, 0, 1) 
     2415        mDoShellCmd(me, QUOTE & svnBinary & QUOTE && "add" && QUOTE & answ & QUOTE, RETURN, 0, 1) 
    24162416         
    24172417        put "Added file" && answ && "to the repository" 
     
    24292429  mDisplayWaitStatusText me, "SVN commit of:" && workingFolder 
    24302430   
    2431   theresult = mDoShellCmd(me, svnBinary && "ci --message" && QUOTE & msg & QUOTE && QUOTE & workingFolder & QUOTE, RETURN, 0, 1) 
     2431  theresult = mDoShellCmd(me, QUOTE & svnBinary & QUOTE && "ci --message" && QUOTE & msg & QUOTE && QUOTE & workingFolder & QUOTE, RETURN, 0, 1) 
    24322432   
    24332433   
     
    25982598  repeat with castlibPaths in castlibPathList 
    25992599     
    2600     theresult = mDoShellCmd(me, svnBinary && "update" && "-r" && revisionNumber && QUOTE & castlibPaths[#newpathUnix] & QUOTE, RETURN, 0, 1) 
     2600    theresult = mDoShellCmd(me, QUOTE & svnBinary & QUOTE && "update" && "-r" && revisionNumber && QUOTE & castlibPaths[#newpathUnix] & QUOTE, RETURN, 0, 1) 
    26012601     
    26022602    if count(theresult) < 1 then 
     
    27282728  revisionNumber = getValidRevNumber(me, revisionNumber) 
    27292729   
    2730   theresult = mDoShellCmd(me, svnBinary && "update" && "-r" && revisionNumber && QUOTE & workingFolderUnix & QUOTE, RETURN, 0, 1) 
     2730  theresult = mDoShellCmd(me, QUOTE & svnBinary & QUOTE && "update" && "-r" && revisionNumber && QUOTE & workingFolderUnix & QUOTE, RETURN, 0, 1) 
    27312731   
    27322732  if count(theresult) > 0 then 
     
    31593159   
    31603160   
    3161   theresult = mDoShellCmd(me, svnBinary && "update" & workingFolder, RETURN, 0, 1) 
     3161  theresult = mDoShellCmd(me, QUOTE & svnBinary & QUOTE && "update" & workingFolder, RETURN, 0, 1) 
    31623162   
    31633163   
    31643164  if count(theresult) < 1 then 
    3165     theresult = mDoShellCmd(me, svnBinary && "update" & workingFolder && "2>&1", RETURN, 0, 1) 
     3165    theresult = mDoShellCmd(me, QUOTE & svnBinary & QUOTE && "update" & workingFolder && "2>&1", RETURN, 0, 1) 
    31663166    if count(theresult) < 1 then 
    31673167      theError = theresult[1] 
     
    32023202   
    32033203   
    3204   theresult = mDoShellCmd(me, svnBinary && "status" & workingFolder, RETURN, 0, 1) 
     3204  theresult = mDoShellCmd(me, QUOTE & svnBinary & QUOTE && "status" & workingFolder, RETURN, 0, 1) 
    32053205   
    32063206  cnt = count(theresult) 
     
    32303230        else 
    32313231           
    3232           mDoShellCmd(me, svnBinary && "rm" && QUOTE & answ & QUOTE, RETURN, 0, 1) 
     3232          mDoShellCmd(me, QUOTE & svnBinary & QUOTE && "rm" && QUOTE & answ & QUOTE, RETURN, 0, 1) 
    32333233           
    32343234          put "Deleted file" && answ && "in the repository" 
     
    32403240         
    32413241      "?": -- newly added file 
    3242         mDoShellCmd(me, svnBinary && "add" && QUOTE & answ & QUOTE, RETURN, 0, 1) 
     3242        mDoShellCmd(me, QUOTE & svnBinary & QUOTE && "add" && QUOTE & answ & QUOTE, RETURN, 0, 1) 
    32433243         
    32443244        put "Added file" && answ && "to the repository" 
     
    32583258  mDisplayWaitStatusText me, "SVN commit:" && workingFolder 
    32593259   
    3260   theresult = mDoShellCmd(me, svnBinary && "ci --message" && QUOTE & msg & QUOTE & workingFolder, RETURN, 0, 1) 
     3260  theresult = mDoShellCmd(me, QUOTE & svnBinary & QUOTE && "ci --message" && QUOTE & msg & QUOTE & workingFolder, RETURN, 0, 1) 
    32613261   
    32623262   
Note: See TracChangeset for help on using the changeset viewer.