This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 227346

Summary: Ignore git repos outside defined project
Product: versioncontrol Reporter: eosph
Component: GitAssignee: Ondrej Vrabec <ovrabec>
Status: NEW ---    
Severity: normal CC: git, loadi
Priority: P3    
Version: 7.3.1   
Hardware: PC   
OS: Windows 7 x64   
Issue Type: ENHANCEMENT Exception Reporter:

Description eosph 2013-03-12 10:26:21 UTC
I have the following folder setup:

/webroot <-- Contains a git repo
/webroot/site1 <-- Contains a git repo and where the project was setup

When I open up the project all the files show as ignored because it's using the /webroot git folder and not the one from /webroot/site1.

Ideally it should only use the git information from where the project was first created (in this case /webroot/site1). Git functionality seems to work fine in the project though.
Comment 1 -Silver- 2013-07-03 07:19:05 UTC
I don't know if mine is the same problem or a different one. Netbeans doesn't recognize git repositories outside the project folder.

Example:

(It DOESN'T works!)
1) I right click on the project
2) I go to versioning
3) I click on "Initialize Git repository"
4) I SELECT A DIFFERENT DIRECTORY FOR MY REPOSITORY (EX. C:\ProjectsRepo)
5) (PROBLEM) The repository is correctly initialized in C:\ProjectsRepo but IT IS NOT VIEWED AND USED BY NETBEANS FOR MY PROJECT

(It works)
Follows the steps till 3
4) I select the standard directory for the repo (Inside my project folder)
5) The repository is correctly initialized and it is used correctly by netbeans to work with my project.
Comment 2 Ondrej Vrabec 2013-07-03 07:41:38 UTC
> 4) I SELECT A DIFFERENT DIRECTORY FOR MY REPOSITORY (EX. C:\ProjectsRepo)
> 5) (PROBLEM) The repository is correctly initialized in C:\ProjectsRepo but IT
> IS NOT VIEWED AND USED BY NETBEANS FOR MY PROJECT
Is your project stored under "C:\ProjectsRepo" or somewhere else?
Comment 3 loadi 2013-10-09 20:13:08 UTC
(In reply to Ondrej Vrabec from comment #2)
> > 4) I SELECT A DIFFERENT DIRECTORY FOR MY REPOSITORY (EX. C:\ProjectsRepo)
> > 5) (PROBLEM) The repository is correctly initialized in C:\ProjectsRepo but IT
> > IS NOT VIEWED AND USED BY NETBEANS FOR MY PROJECT
> Is your project stored under "C:\ProjectsRepo" or somewhere else?

It should be stored somewhere else. The same problem occurred when I tried a similar setup. In my case I put the project folder on the hard disk, while I tried to initialize the repository on a flash drive.
The repository was initialized correctly, but NetBeans could not detect it.