简体   繁体   中英

rvm, associate a gemset to a project

Is it possible to associate a project (that is the root directory of a ruby project) with a certain gemset? I thought that

rvm gemset use mytestgemset

would do that, but it is temporary and just exiting and entering again restores the original gemset.

I have set up a "test" gemset where i test new version of gems. I don't think i have to issue a rvm gemset use mytestgemset each time i launch my test application, do I?

In the directory of your Rails app add a file called .rvmrc with the text rvm gemset use mytestgemset in it.

When you cd into that directory rvm will notify you that it has switched the gemset in use. The first time you need to confirm, afterwards it will switch automatically.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM