I''ve tried putting the rake files in /lib/tasks, but that
didn''t work either.
My rake task is as follows:
task :do_this => [:import_stuff, :load_data]
If I type:
rake do_this
The response is, Don''t know how to build task
''do_this''
Does the app-level "Rakefile" impact how/when rake files in lib/tasks
get processed?
-Mark
> -------Original Message-------
> From: Brian Hughes <brianvh@Alum.Dartmouth.ORG>
> Subject: Re: [Rails] Simple Rake question
> Sent: 05 Jun ''06 13:42
>
> On Jun 5, 2006, at 09:32 AM, Mark W. wrote:
> > Newbie question but here goes:
> >
> > Isn''t rake supposed to automatically search the lib/tasks
> > subdirectory for Rake files/tasks?
> >
> > I have a task called "do_this.rake" in file foo.rake in
lib/tasks/
> > rails - how do I invoke it from the command line in the root
> > directory of my Rails application?
> >
> > Presuming I have a file called "Rakefile" in the root
directory of
> > my Rails application, is there something special that needs to be
> > in it?
>
> Can you post your take declaration line, from that .rake file?
> That''s where you will find how you are supposed to refer to your
> custom Rake task. Also, I''m not sure you should be placing thing
> deeper than the lib/tasks directory. I don''t know if Rake is
doing a
> recursive search for .rake files.
>
> -Brian
>
> _______________________________________________
> Rails mailing list
> Rails@lists.rubyonrails.org
> http://lists.rubyonrails.org/mailman/listinfo/rails
>