El directorio del proyecto RubyMine desaparece después de git pull

My coworker and I started working on the same project using GitHub and RubyMine.

Our original sin was to push .idea folder (created and updated automatically by RubyMine) in my local repository to GitHub. This folder creates conflict with my co-worker's local repository every time he pulls from remote.

To fix this issue, we have to delete .idea folder from remote repository. Now, from my master branch, I pull from remote repository, and it seems that .idea files were removed (I am not sure). Therefore, RubyMine won't let me see my project folders (i.e., app, config, public) in Project view, even though these folders are still there.

My question is: how can I restore original setting in RubyMine where I can see my project folders?

preguntado el 10 de marzo de 12 a las 15:03

2 Respuestas

The only files from .idea folder that you should not push are workspace.xml and tasks.xml. First you should untrack those files with:

git rm --cached .idea/workspace.xml
git rm --cached .idea/tasks.xml

Next add them to .gitignore:


Now simply remove .idea folder and reopen the project folder with rubymine.

respondido 10 mar '12, 17:03

Puedes probar lo siguiente:

  • Make sur your project is versionned with git (run git info)
  • Close rubymine and reopen it
  • Pay attention to messages on the top right : find the message complaining that "git root is unregistered"
  • Click on register git root in the message
  • In the configuration window, click the message in red: add git root
  • Quickdiffs in files should work now.

If you don't have the message about git when you open rubymine, you can go to the options (command+,), then search version control and click on the first result. Then you should have a table with 2 columns:

| Directory          | VCS    |
| <Project>          | <none> |
| /home/user/project | Git    |

If your project is not listed here, try adding it.

Respondido 15 ago 13, 16:08

No es la respuesta que estás buscando? Examinar otras preguntas etiquetadas or haz tu propia pregunta.