答案 0 :(得分:1)
请确保在以下位置将您的应用设置为CanonicalTreeParser newTreeIter = new CanonicalTreeParser();
ObjectId tree = git.getRepository().resolve("HEAD^{tree}");
newTreeIter.reset(reader, tree);
UsernamePasswordCredentialsProvider cred = new UsernamePasswordCredentialsProvider(USER, PASSWORD);
PullResult pull_res = git.pull().setCredentialsProvider(cred).call();
CanonicalTreeParser oldTreeIter = new CanonicalTreeParser();
tree = git.getRepository().resolve("HEAD^{tree}");
oldTreeIter.reset(reader, tree);
DiffFormatter df = new DiffFormatter(new ByteArrayOutputStream());
df.setRepository( git.getRepository() );
List<DiffEntry> entries = df.scan(oldTreeIter, newTreeIter);
for(DiffEntry entry : entries) {
java.lang.System.out.println(entry);
}
:
常规->部署信息->设备