Hello, I have filled db/fixtures with the static data for my site in hopes of using db:bootstrap as described on many sites. But db:bootstrap is not available under my rake command. Any suggestions? Thanks! --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
I don''t have a db:bootstrap rake task here. If I do rake -T bootstrap I get rake bootstrap # Bootstrap the whole she-bang rake bootstrap:db:config # Copy database.example.yml into config/data... rake bootstrap:db:create # Create development and testing databases rake bootstrap:db:purge # Empty the development database rake bootstrap:fixtures:files # Copy test/fixtures/files to RAILS_ROOT/files rake bootstrap:settings # Copy settings.example.yml into config/sett... rake cms:bootstrap # Bootstrap the database I''ve never seen these before. Is one of these the one to which you''re referring? If db:bootstrap is a task that you''ve written, be sure to provide a description. For example, namespace :db desc "Bootstraps...." task :bootstrap => :environment do ... end end Without one, I don''t think the task will show when you do rake -T. Craig --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
I''m looking for a way to load fairly static data into my database after running migrations. I''ve been reading about db:bootstrap and have seen several references to the Technoweenie forum (http:// www.railsweenie.com/forums/2/topics/778), but as of today, the website is not loading. Besides storing raw sql files, is there another way to do this that anyone knows about? There has to be, this seems like a basic DRY concept. Thanks! On Feb 11, 11:48 pm, "Craig Demyanovich" <cdemyanov...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> I don''t have a db:bootstrap rake task here. If I do > > rake -T bootstrap > > I get > > rake bootstrap # Bootstrap the whole she-bang > rake bootstrap:db:config # Copy database.example.yml into > config/data... > rake bootstrap:db:create # Create development and testing databases > rake bootstrap:db:purge # Empty the development database > rake bootstrap:fixtures:files # Copy test/fixtures/files to > RAILS_ROOT/files > rake bootstrap:settings # Copy settings.example.yml into > config/sett... > rake cms:bootstrap # Bootstrap the database > > I''ve never seen these before. Is one of these the one to which you''re > referring? If db:bootstrap is a task that you''ve written, be sure to provide > a description. For example, > > namespace :db > desc "Bootstraps...." > task :bootstrap => :environment do > ... > end > end > > Without one, I don''t think the task will show when you do rake -T. > > Craig--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
The db:bootstrap task is code that is specific to the Mephisto code base, not Rails proper. When I needed similar functionality I took a look at that code and made my own version for my Kete app (http://kete.net.nz/). Seems like db:bootstrap is a good candidate for a plugin. If your going to have to do it anyway... Or maybe sake, which I haven''t look into, but it is a way of sharing rake tasks. Cheers, Walter On Sat, Feb 23, 2008 at 12:49 AM, Mindtonic <mindtonic-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> > I''m looking for a way to load fairly static data into my database > after running migrations. I''ve been reading about db:bootstrap and > have seen several references to the Technoweenie forum (http:// > www.railsweenie.com/forums/2/topics/778), but as of today, the website > is not loading. Besides storing raw sql files, is there another way > to do this that anyone knows about? There has to be, this seems like > a basic DRY concept. > > Thanks! > > On Feb 11, 11:48 pm, "Craig Demyanovich" <cdemyanov...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> > wrote: > > I don''t have a db:bootstrap rake task here. If I do > > > > rake -T bootstrap > > > > I get > > > > rake bootstrap # Bootstrap the whole she-bang > > rake bootstrap:db:config # Copy database.example.yml into > > config/data... > > rake bootstrap:db:create # Create development and testing > databases > > rake bootstrap:db:purge # Empty the development database > > rake bootstrap:fixtures:files # Copy test/fixtures/files to > > RAILS_ROOT/files > > rake bootstrap:settings # Copy settings.example.yml into > > config/sett... > > rake cms:bootstrap # Bootstrap the database > > > > I''ve never seen these before. Is one of these the one to which you''re > > referring? If db:bootstrap is a task that you''ve written, be sure to > provide > > a description. For example, > > > > namespace :db > > desc "Bootstraps...." > > task :bootstrap => :environment do > > ... > > end > > end > > > > Without one, I don''t think the task will show when you do rake -T. > > > > Craig > > >--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
The db:bootstrap task is code that is specific to the Mephisto code base, not Rails proper. When I needed similar functionality I took a look at that code and made my own version for my Kete app (http://kete.net.nz/). Seems like db:bootstrap is a good candidate for a plugin. If your going to have to do it anyway... Or maybe sake, which I haven''t look into, but it is a way of sharing rake tasks. Cheers, Walter On Sat, Feb 23, 2008 at 12:49 AM, Mindtonic <mindtonic-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> > I''m looking for a way to load fairly static data into my database > after running migrations. I''ve been reading about db:bootstrap and > have seen several references to the Technoweenie forum (http:// > www.railsweenie.com/forums/2/topics/778), but as of today, the website > is not loading. Besides storing raw sql files, is there another way > to do this that anyone knows about? There has to be, this seems like > a basic DRY concept. > > Thanks! > > On Feb 11, 11:48 pm, "Craig Demyanovich" <cdemyanov...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> > wrote: > > I don''t have a db:bootstrap rake task here. If I do > > > > rake -T bootstrap > > > > I get > > > > rake bootstrap # Bootstrap the whole she-bang > > rake bootstrap:db:config # Copy database.example.yml into > > config/data... > > rake bootstrap:db:create # Create development and testing > databases > > rake bootstrap:db:purge # Empty the development database > > rake bootstrap:fixtures:files # Copy test/fixtures/files to > > RAILS_ROOT/files > > rake bootstrap:settings # Copy settings.example.yml into > > config/sett... > > rake cms:bootstrap # Bootstrap the database > > > > I''ve never seen these before. Is one of these the one to which you''re > > referring? If db:bootstrap is a task that you''ve written, be sure to > provide > > a description. For example, > > > > namespace :db > > desc "Bootstraps...." > > task :bootstrap => :environment do > > ... > > end > > end > > > > Without one, I don''t think the task will show when you do rake -T. > > > > Craig > > >--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---