Thanks, that was my second option to create a script on the local box,
however I like the clean approach of keeping all the logic on the
deployment box which means I don't have to worry about any deployment
requirements.

Would the abbility to hide/show custom message when executing a task
be something that you would consider adding to Capistrano at a later
stage? If so I will gladly create a feature request for it.

Regards

On Jan 28, 5:33 pm, Jamis Buck <[email protected]> wrote:
> Gerhardus, there is not currently a way built into Capistrano to hide
> the command that is executed. My recommendation is to put the command in
> a script and execute the script on the server, e.g.:
>
>   put "some big long command to execute", "/tmp/script.sh"
>   run "sh -c /tmp/script.sh"
>
> - Jamis
>
> On 1/28/09 10:29 AM, Gerhardus Geldenhuis wrote:
>
> > Thanks Lee,
> > That will certainly be usefull and solve some other problems I had.
>
> > But I was trying to solve another problem
>
> > when I execute the task I get the following:
>
> >   * executing "for ((n=0; n<61; n++ )); do\\\n      if wget localhost:
> > 8080/gta-jcbs-xml/bfuildInfo.jsp --quiet -O - --connect-timeout=1 --
> > timeout=1 --tries=1 | grep -q 'Build Information'; then echo
> > 'Application Succesfully deployed';exit 0;\\\n      elif [ $n -eq
> > 60 ]; then echo \"Server did not deploy in time\";\\\n      exit 0;\\
> > \n      fi;\\\n      sleep 1;\\\n    done"
> >     servers: ["longtct03g", "longtct03h", "longtct03i", "longtct03j"]
>
> > regardless of the success or failure. I am trying to "hide" the
> > implementation from the user because they don't need to know (or care)
> > and just having a string that says checking for availability of
> > application is better then the sh optimized string seen above.
>
> > Basically I want a run command with the following parameters: run
> > "execute this task", "optionally display this description of the task
> > being run"
>
> > Regards
>
> > On Jan 28, 2:09 pm, Lee Hambley <[email protected]> wrote:
> >> Ger,
> >>  One of these two examples in my new pastie might help - though, I've not
> >> tested them :)
>
> >>    -http://pastie.org/373172
>
> >> - Lee
>
> >> 2009/1/28 Gerhardus Geldenhuis <[email protected]>
>
> >>> Hi
> >>> I believe that when I know ruby better I should be able to answer this
> >>> myself but for now I would appreciate some help.
> >>> Is there a way to customize the message per task when a task aborts.
> >>> I would also like to customize the message if a task like the
> >>> following executes:
> >>>  run <<-CMD
> >>>    for ((n=0; n<61; n++ )); do
> >>>      if wget localhost:8080/gta-jcbs-xml/buildInfo.jsp --quiet -O - --
> >>> connect-timeout=1 --timeout=1 --tries=1 | grep -q 'Build Information';
> >>> then echo 'Application Succesfully deployed';exit 0;
> >>>      elif [ $n -eq 60 ]; then echo "Server did not deploy in time";
> >>>      exit 0;
> >>>      fi;
> >>>      sleep 1;
> >>>    done
> >>>  CMD
> >>> because the execute message looks awfull:
> >>>  * executing "for ((n=0; n<61; n++ )); do\\\n      if wget localhost:
> >>> 8080/gta-jcbs-xml/buildInfo.jsp --quiet -O - --connect-timeout=1 --
> >>> timeout=1 --tries=1 | grep -q 'Build Information'; then echo
> >>> 'Application Succesfully deployed';exit 0;\\\n      elif [ $n -eq
> >>> 60 ]; then echo \"Server did not deploy in time\";\\\n      exit 0;\\
> >>> \n      fi;\\\n      sleep 1;\\\n    done"
> >>> Regards
--~--~---------~--~----~------------~-------~--~----~
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at http://groups.google.com/group/capistrano
-~----------~----~----~----~------~----~------~--~---

Reply via email to