If it's only the first one, why not just do

  before "deploy:migrate", :my_custom_task

And then remove it after the first deployment?

- Jamis

On Oct 26, 2007, at 5:50 PM, Thomas Watson wrote:


I would like to run a custom rake task before the very first
migration.

The first migration runs during the deploy:cold task. Deploy:cold
internally calls deploy:migrate.

At first you might think that I could set up a before-hook like this:
before "deploy:migrate", :my_custom_task

But deploy:migrate is also called from within deploy:migrations, so
setting a before-hook like this will result in :my_custom_task to run
before every call to deploy:migrate (no matter if it comes from within
deploy:cold, deploy:migrations or from a direct call to
deploy:migrate).

Is there a way to tell the before-hook only to "trigger" if the call
has been routed though deploy:cold?


--~--~---------~--~----~------------~-------~--~----~
To unsubscribe from this group, send email to capistrano- [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/ group/capistrano
-~----------~----~----~----~------~----~------~--~---


Attachment: smime.p7s
Description: S/MIME cryptographic signature

Reply via email to