Patchwork D3864: histedit: add a stateobj variable to histeditstate class

login
register
mail settings
Submitter phabricator
Date June 30, 2018, 3:09 p.m.
Message ID <differential-rev-PHID-DREV-tbxygcyyzqwlpughwssq-req@phab.mercurial-scm.org>
Download mbox | patch
Permalink /patch/32528/
State Superseded
Headers show

Comments

phabricator - June 30, 2018, 3:09 p.m.
pulkit created this revision.
Herald added a reviewer: durin42.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.

REVISION SUMMARY
  The stateobj variable will be an instance of state.cmdstate() class. The
  stateobj variable will be used in upcoming patches to simplify the code a bit
  and start using cbor to write state files.

REPOSITORY
  rHG Mercurial

REVISION DETAIL
  https://phab.mercurial-scm.org/D3864

AFFECTED FILES
  hgext/histedit.py

CHANGE DETAILS




To: pulkit, durin42, #hg-reviewers
Cc: mercurial-devel

Patch

diff --git a/hgext/histedit.py b/hgext/histedit.py
--- a/hgext/histedit.py
+++ b/hgext/histedit.py
@@ -207,6 +207,7 @@ 
     registrar,
     repair,
     scmutil,
+    state as statemod,
     util,
 )
 from mercurial.utils import (
@@ -304,6 +305,7 @@ 
         self.lock = lock
         self.wlock = wlock
         self.backupfile = None
+        self.stateobj = statemod.cmdstate(repo, 'histedit-state')
         if replacements is None:
             self.replacements = []
         else: