1. Full version control of a web app would include the constellation of gems actually used. I can do ''gem list'' and put that into a file in version control but that could include unused gems. That is, it could include gems use by other projects. And putting the whole gem in version control seem like overkill since the authors do that. But it might be safer. Do we have a utility that will generate a script to re-fetch the gems at the exact version numbers I''m using now? I can easily put plugins in the VC system, but gems are in a different place. I suppose I could create some sort of link from my working directory to GEM_HOME or even to the places on GEM_PATH but that seems like a pain. QUESTION: So what are the best practices for version control and gems? And does the answer change if I use git instead of svn? (And is one really better than the other for rails projects?) F --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
On 15 Apr 2008, at 18:14, fredistic wrote:> > 1. Full version control of a web app would include the constellation > of gems actually used. I can do ''gem list'' and put that into a file > in version control but that could include unused gems. That is, it > could include gems use by other projects. > > And putting the whole gem in version control seem like overkill since > the authors do that. But it might be safer. > > Do we have a utility that will generate a script to re-fetch the gems > at the exact version numbers I''m using now? >Edge rails has this. You define in your config which gems (possibly locking it to a particular version) and then there''s a rake task to go get them all. Fred> I can easily put plugins in the VC system, but gems are in a different > place. I suppose I could create some sort of link from my working > directory to GEM_HOME or even to the places on GEM_PATH but that seems > like a pain. > > QUESTION: So what are the best practices for version control and > gems? > > And does the answer change if I use git instead of svn? > (And is one really better than the other for rails projects?) > > F > > >--~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
Oh wow. Way cool. And the rake task puts them in $GEM_HOME or do you specify on the command line? Or does it just go to the ''regular place'' ruby gem directory only? The version numbers should protect us, I know, but sometimes it pays to be paranoid. There''s a $GEM_PATH variable we can use to tell ruby where to look for gems. If I was re-creating an older version of some app from version control I might not want that old gem in the regular place. I''d put it someplace special and use $GEM_PATH or $GEM_HOME. On the other hand I might have reverted to an older version of Ruby so the ''regular place'' might be just right. F P.S. While mineral gems might be more valuable when old, software gems often are not... --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
On 15 Apr 2008, at 19:17, fredistic wrote:> > Oh wow. Way cool. > > And the rake task puts them in $GEM_HOME or do you specify on the > command line? Or does it just go to the ''regular place'' ruby gem > directory only? The version numbers should protect us, I know, but > sometimes it pays to be paranoid. >don''t know off the top of my head I''m afraid. Fred> There''s a $GEM_PATH variable we can use to tell ruby where to look for > gems. If I was re-creating an older version of some app from version > control I might not want that old gem in the regular place. I''d put > it someplace special and use $GEM_PATH or $GEM_HOME. > > On the other hand I might have reverted to an older version of Ruby so > the ''regular place'' might be just right. > > F > > P.S. While mineral gems might be more valuable when old, software > gems often are not... > > >--~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
You could create a rake tasks which downloads the right gems with right versions. And there is a gem command to ''load a certain version'' of them, too. Fred Talpiot wrote:> 1. Full version control of a web app would include the constellation > of gems actually used. I can do ''gem list'' and put that into a file > in version control but that could include unused gems. That is, it > could include gems use by other projects. > > And putting the whole gem in version control seem like overkill since > the authors do that. But it might be safer. >-- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---