How to use JGit to get a list of modified files?

Using JGit, I want to get a list of files changed in commits, as is possible with git log -name-status.

Is it possible? If so, how do you do it?

+4
source share
1 answer

I am using a modified version of JGitUtils from the big GitBlit-Tool :

Look at the source of the getFilesInCommit method to find out how this might work ( PathChangeModel used only for storing data.)

+3
source

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


All Articles