Я пытаюсь создать, а затем изменить файлы с помощью svnkit. Это мой первый опыт работы с этим, поэтому я следил за всеми примерами на их вики-сайте. Тем не менее я получаю следующее сообщение об ошибке при добавлении файла:
Cause: java.lang.NoClassDefFoundError: Could not initialize class org.tmatesoft.svn.core.io.diff.SVNDiffWindow
at org.tmatesoft.svn.core.io.diff.SVNDeltaGenerator.sendDelta(SVNDeltaGenerator.java:271)
Вот фрагмент из моего кода:
byte[] contents = "This is a new file".getBytes();
editor.openRoot(-1);
editor.addFile("conf/test.conf", null, -1);
editor.applyTextDelta("conf/test.conf", null);
SVNDeltaGenerator deltaGenerator = new SVNDeltaGenerator();
String checksum = deltaGenerator.sendDelta("conf/test.conf", new ByteArrayInputStream(contents), editor, true);
editor.closeFile("conf/test.conf", checksum);
editor.closeDir();