[Commented On] D12591: debugcommands: remove `debugdirstateignorepatternhash`

baymax (Baymax, Your Personal Patch-care Companion) phabricator at mercurial-scm.org
Wed May 4 14:53:23 UTC 2022


baymax added a comment.
baymax updated this revision to Diff 33347.


  ✅ refresh by Heptapod after a successful CI run (🐙 💚)
  âš  This patch is intended for stable âš 
  <img src="https://phab.mercurial-scm.org/file/data/qqhfsqwiqrmcalesyz5o/PHID-FILE-5remnsbppxl5yauxywbg/source.gif" />

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D12591?vs=33340&id=33347

BRANCH
  stable

CHANGES SINCE LAST ACTION
  https://phab.mercurial-scm.org/D12591/new/

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

AFFECTED FILES
  mercurial/debugcommands.py
  tests/test-completion.t
  tests/test-help.t

CHANGE DETAILS

diff --git a/tests/test-help.t b/tests/test-help.t
--- a/tests/test-help.t
+++ b/tests/test-help.t
@@ -1013,8 +1013,6 @@
                  dump information about delta chains in a revlog
    debugdirstate
                  show the contents of the current dirstate
-   debugdirstateignorepatternshash
-                 show the hash of ignore patterns stored in dirstate if v2,
    debugdiscovery
                  runs the changeset discovery protocol in isolation
    debugdownload
diff --git a/tests/test-completion.t b/tests/test-completion.t
--- a/tests/test-completion.t
+++ b/tests/test-completion.t
@@ -94,7 +94,6 @@
   debugdate
   debugdeltachain
   debugdirstate
-  debugdirstateignorepatternshash
   debugdiscovery
   debugdownload
   debugextensions
@@ -285,7 +284,6 @@
   debugdata: changelog, manifest, dir
   debugdate: extended
   debugdeltachain: changelog, manifest, dir, template
-  debugdirstateignorepatternshash: 
   debugdirstate: nodates, dates, datesort, docket, all
   debugdiscovery: old, nonheads, rev, seed, local-as-revs, remote-as-revs, ssh, remotecmd, insecure, template
   debugdownload: output
diff --git a/mercurial/debugcommands.py b/mercurial/debugcommands.py
--- a/mercurial/debugcommands.py
+++ b/mercurial/debugcommands.py
@@ -1018,22 +1018,6 @@
 
 
 @command(
-    b'debugdirstateignorepatternshash',
-    [],
-    _(b''),
-)
-def debugdirstateignorepatternshash(ui, repo, **opts):
-    """show the hash of ignore patterns stored in dirstate if v2,
-    or nothing for dirstate-v2
-    """
-    if repo.dirstate._use_dirstate_v2:
-        docket = repo.dirstate._map.docket
-        hash_len = 20  # 160 bits for SHA-1
-        hash_bytes = docket.tree_metadata[-hash_len:]
-        ui.write(binascii.hexlify(hash_bytes) + b'\n')
-
-
- at command(
     b'debugdiscovery',
     [
         (b'', b'old', None, _(b'use old-style discovery')),



To: Alphare, #hg-reviewers, marmoute
Cc: mercurial-patches
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mercurial-scm.org/pipermail/mercurial-patches/attachments/20220504/27572714/attachment.html>


More information about the Mercurial-patches mailing list