RubyMine project directory disappears after git pull

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

Our original sin was to push the .idea folder (created and updated automatically by RubyMine) in my local repository for GitHub. This folder creates a conflict with the local repository of my team every time it pulls from the remote.

To fix this problem, we must delete the .idea folder from the remote repository. Now, from my leading branch, I pull it out of the remote repository, and it seems that the .idea files have been deleted (I'm not sure). Therefore, RubyMine will not allow me to see project folders (i.e. Application, config, public) in the Project view, even if these folders still exist.

My question is: how to restore the original setup in RubyMine, where can I see the project folders?

+4
source share
2 answers

The only files from the .idea folder that you should not click are workspace.xml and tasks.xml. First you have to parse these files with:

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

Then add them to .gitignore:

 .idea/workspace.xml .idea/tasks.xml 

Now just delete the .idea folder and unzip the project folder again using rubyine.

+6
source

You can try the following:

  • Make your project version with git (run git info)
  • Close the ruby ​​and open it again.
  • Pay attention to the messages in the upper right corner: find the message complaining that "git root is not registered"
  • Click in the git root register in the message
  • In the configuration window, click the message in red: add git root
  • Quickdiffs in files should now work.

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

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

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

0
source

Source: https://habr.com/ru/post/1400737/


All Articles