1

I have a situation with structure bellow and Git plugin plus property file scanner. There are N Git repositories under "Parent_Directory". I am not able to scan "Parent_Directory" in one shot because Git plugin is expecting one .git folder per scan. So I have to scan repositories one by one which doesn't look a big issue.

Parent_Directory
 |- Repository_A
 |  |- .git
 |  |- Folder
 |     |- File.properties
 |- Repository_B
    |- .git
    |- Folder
       |- File.properties

The challenge is if there are property files with same folder structure and file name (ie Folder/File.properties) in different repositories, I'm not able to identify which repository they belong to. It works fine with nodes which are pointing to Git repositories, so I can associate them to ":Repository" node and figure our where do they belong to. But properties are not. There is no node with :Git:Properties label.

Overall you will have ":File" nodes which are not labeled with ":Git" and query below finds many of them

MATCH (n:File)
WHERE NOT n:Git 
RETURN n

Seems it happens when we use Git plugin plus scanners for Json, Yaml, XML, properties, etc.

I have two questions:

  • Is there a workaround to scan multiple repositories in one shot by scanning their parent directory.

  • If not, is there a way to give instructions to Git plugin to cover all files when other scanners are also involved.

hmozaffari
  • 31
  • 3
  • This question is in context of JQAssistant tool and its Git plugin: https://github.com/kontext-e/jqassistant-plugins/blob/master/git/src/main/asciidoc/git.adoc – hmozaffari Aug 06 '22 at 00:08
  • Ah, that makes more sense (with the updated title). – torek Aug 06 '22 at 00:29

1 Answers1

1

The Git plugin prevents scanning the same Git repository more than one time as it can happen in multi-module Maven projects. Unfortunately there is currently (version 1.8.0) no workaround for this. The only option you have is to run jQAssistant a second time, now giving only the missing Git repository to scan:

jqassistant.cmd scan -f .\Parent_Directory\Repository_B\.git\
Jens Nerche
  • 118
  • 8