From: SourceForge.net <no...@so...> - 2008-08-04 12:55:11
|
Bugs item #2037398, was opened at 2008-08-04 03:39 Message generated for change (Comment added) made by nutans You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=1089899&aid=2037398&group_id=233450 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: Object API Group: None Status: Open Resolution: None Priority: 5 Private: No Submitted By: Anirudha (anirudha81) Assigned to: Nobody/Anonymous (nobody) Summary: GitAdd in WorkingTree.java does not add files Initial Comment: //Create a new directory to be used as a git repository. repositoryDirectory = FileUtilities.createTempDirectory("Demo_gitRepository"); //Initialize the repository ,similar to git init HelperGitCommands.initRepo(repositoryDirectory); //Create a file in our repository File file = FileUtilities.createFile(repositoryDirectory, "README", "First file in the git repository"); //get the instance of the dotGit Object dotGit = DotGit.getInstance(repositoryDirectory); //get the current working tree from the git repository WorkingTree wt = dotGit.getWorkingTree(); GitAddResponse ar = wt.add(); wt.commitAll("First commit to the git repository"); //Commit fails saying no files added ??? wt.gitADD is not adding files, response object is empty. ---------------------------------------------------------------------- >Comment By: nutans (nutans) Date: 2008-08-04 08:55 Message: Logged In: YES user_id=2152864 Originator: NO Hi Anirudha, Shouldn't GitAddResponse ar = wt.add() be GitAddResponse ar = wt.add(file)? Otherwise, I don't see the file getting added to the repository. ~Nutan ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=1089899&aid=2037398&group_id=233450 |