diff mercurial/bookmarks.py @ 24944:08ec11e3ae4c

bookmarks: rename unsetcurrent to deactivate (API) Today, the terms 'active' and 'current' are interchangeably used throughout the codebase in reference to the active bookmark (the bookmark that will be updated with the next commit). This leads to confusion among developers and users. This patch is part of a series to standardize the usage to 'active' throughout the mercurial codebase and user interface.
author Ryan McElroy <rmcelroy@fb.com>
date Mon, 13 Apr 2015 21:53:37 -0700
parents 5947a68fa271
children e0b0fbd47491
line wrap: on
line diff
--- a/mercurial/bookmarks.py	Wed May 06 17:15:38 2015 +0200
+++ b/mercurial/bookmarks.py	Mon Apr 13 21:53:37 2015 -0700
@@ -84,7 +84,7 @@
     def _writerepo(self, repo):
         """Factored out for extensibility"""
         if repo._bookmarkcurrent not in self:
-            unsetcurrent(repo)
+            deactivate(repo)
 
         wlock = repo.wlock()
         try:
@@ -151,7 +151,10 @@
         wlock.release()
     repo._bookmarkcurrent = mark
 
-def unsetcurrent(repo):
+def deactivate(repo):
+    """
+    Unset the active bookmark in this reposiotry.
+    """
     wlock = repo.wlock()
     try:
         try: