# HG changeset patch # User padraigob@netbeans.org # Date 1205333856 0 # Node ID 27b85028e9961026516087f9538867d57457d273 # Parent 6437411e7332f157ade78508b3516182e65ee41c 126839: Reduce required size of command line for commit by using --cwd diff -r 6437411e7332 -r 27b85028e996 mercurial/src/org/netbeans/modules/mercurial/util/HgCommand.java --- a/mercurial/src/org/netbeans/modules/mercurial/util/HgCommand.java Wed Mar 12 14:15:26 2008 +0000 +++ b/mercurial/src/org/netbeans/modules/mercurial/util/HgCommand.java Wed Mar 12 14:57:36 2008 +0000 @@ -1615,6 +1615,8 @@ public class HgCommand { command.add(HG_COMMIT_CMD); command.add(HG_OPT_REPOSITORY); command.add(repository.getAbsolutePath()); + command.add(HG_OPT_CWD_CMD); + command.add(repository.getAbsolutePath()); String projectUserName = new HgConfigFiles(repository).getUserName(false); String globalUsername = HgConfigFiles.getInstance().getUserName(); @@ -1647,7 +1649,7 @@ public class HgCommand { command.add(tempfile.getAbsolutePath()); for(File f: commitFiles){ - command.add(f.getAbsolutePath()); + command.add(f.getAbsolutePath().substring(repository.getAbsolutePath().length()+1)); } List list = exec(command);