Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Git branches view with multiple projects

We have 4 multi-module projects (Maven), each one in its own Git repository. There are interdependencies between the projects.

In order to have all our code available in a single IntelliJ window, I have imported all the projects as modules.

But this has had the following effect. The Changes > Log is the view where I can see all branches for my project. When I had 1 IntelliJ window per project, the branches I could see there were the branches of the project I had opened. Now that I have all the projects, I can see all the branches intermingled, and it makes it really difficult for me to understand what is going on.

enter image description here

In the screenshot above, the branches marked in blue belong to the same Git repository, and the branch marked in red belong to a different Git repository.

Although there are some filters, I can not see any filter by module (Git repository). It would seem obvious to me to only see branches group per Git repository. Is there any way to do that?

like image 302
Markos Fragkakis Avatar asked Jan 22 '14 13:01

Markos Fragkakis


People also ask

Should I have multiple projects in one repository?

Yes you can, but is not recommended. Best practice is one repo per project always. Otherwise you have multiple projects updating one repo, that can mess with the code a fair bit if not set correctly. If the project is set up to be read-only on one project, that is an exception.

Can two developers work on the same branch?

For every discreet feature (bug, enhancement, etc.), a new local branch is made from dev. Developers don't have to work on the same branch, since each feature branch is scoped to only what that single developer is working on. This is where git's cheap branching comes in handy.


2 Answers

Tips

  1. Select a repository from the Paths submenu.
  2. Cmd+click(mac), Alt+click(win/linux) to select the specific one.

enter image description here

like image 116
Color Avatar answered Oct 05 '22 22:10

Color


OK, the solution for my question is the following:

VCS > Browse CVS repository > Show Git repository log.

Select the directory representing the Git repo you are interested in.

like image 44
Markos Fragkakis Avatar answered Oct 06 '22 00:10

Markos Fragkakis