It seems you have a typo in the first code snippet above: namespace deploy do task :restart do .... end end
The `namespace deploy` => deploy should be a symbol so try changing it to this: `namespace :deploy` On Thursday, July 10, 2014 2:31:53 AM UTC+2, Carlos Peñas wrote: > > Hi!. > > I'm running in to the dared "cap aborted! Don't know how to build task > '<task>'" > > And I do not know if I'm missing something and is a feature or there's > other way to get this > > supose this deploy.rb > > #after "deploy:restart", "clean:cache" > > namespace deploy do > task :restart do > .... > end > end > > after "deploy:restart", "clean:cache" > > and this lib/capistrano/tasks/clean.rake > > namespace :clean do > task :cache do > ... > end > end > > #after "deploy:restart", "clean:cache" > > all of these with the default Capfile which includes all the rake files in > lib/capistrano > > Documentation states that I can put the after chain wherever it suits my > needs (and I need to place it in the rake file) But it only works if I > place it at the end of deploy.rb. Otherwise capistrano behaves like if task > was undefined. This brings me to the old #include <stdio.h> times > > is there a way to put after chain in the rake file or this one-pass > evaluation is intended? > > Versions: > > - Ruby ruby 2.0.0p195 (2013-05-14 revision 40734) [x86_64-linux] > - Capistrano 3.2.1 > - Rake / Rails / etc rake, version 10.3., no rails > > Platform: > > - Working on.... linux > - Deploying to... vagrant linux > > > -- You received this message because you are subscribed to the Google Groups "Capistrano" group. To unsubscribe from this group and stop receiving emails from it, send an email to capistrano+unsubscr...@googlegroups.com. To view this discussion on the web, visit https://groups.google.com/d/msgid/capistrano/32d386b6-76fb-48cc-b7ab-a1f48b72ee0b%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.