mirror of
https://github.com/scm-manager/scm-manager.git
synced 2025-11-11 07:55:47 +01:00
fix handling of pending changesets during pre receive repository hooks
This commit is contained in:
@@ -310,6 +310,24 @@ public class HgRepositoryHandler
|
||||
return diffViewer;
|
||||
}
|
||||
|
||||
/**
|
||||
* Method description
|
||||
*
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public HgContext getHgContext()
|
||||
{
|
||||
HgContext context = hgContextProvider.get();
|
||||
|
||||
if (context == null)
|
||||
{
|
||||
context = new HgContext();
|
||||
}
|
||||
|
||||
return context;
|
||||
}
|
||||
|
||||
/**
|
||||
* Method description
|
||||
*
|
||||
|
||||
@@ -76,7 +76,8 @@ public class HgCommandContext implements Closeable
|
||||
HgRepositoryHandler handler, sonia.scm.repository.Repository repository,
|
||||
File directory)
|
||||
{
|
||||
this(hookManager, handler, repository, directory, false);
|
||||
this(hookManager, handler, repository, directory,
|
||||
handler.getHgContext().isPending());
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user