hgext/obsolete.py
changeset 392 04e67d6f1913
parent 390 54582eebeb08
child 393 ac8213faeda8
equal deleted inserted replaced
391:92adb5b34a04 392:04e67d6f1913
    68 from mercurial import discovery
    68 from mercurial import discovery
    69 from mercurial import error
    69 from mercurial import error
    70 from mercurial import commands
    70 from mercurial import commands
    71 from mercurial import changelog
    71 from mercurial import changelog
    72 from mercurial import phases
    72 from mercurial import phases
    73 from mercurial import store
       
    74 from mercurial.node import hex, bin, short, nullid
    73 from mercurial.node import hex, bin, short, nullid
    75 from mercurial.lock import release
    74 from mercurial.lock import release
    76 from mercurial import localrepo
    75 from mercurial import localrepo
    77 from mercurial import cmdutil
    76 from mercurial import cmdutil
    78 from mercurial import templatekw
    77 from mercurial import templatekw
    81     from mercurial.localrepo import storecache
    80     from mercurial.localrepo import storecache
    82     storecache('babar') # to trigger import
    81     storecache('babar') # to trigger import
    83 except (TypeError, ImportError):
    82 except (TypeError, ImportError):
    84     def storecache(*args):
    83     def storecache(*args):
    85         return scmutil.filecache(*args, instore=True)
    84         return scmutil.filecache(*args, instore=True)
    86 
       
    87 ### temporary core fix
       
    88 #############################
       
    89 getattr(store, '_load', lambda:None)()
       
    90 if 'obsstore' not in vars(store)['_data']:
       
    91     store._data = vars(store)['_data'] + ' obsstore'
       
    92 
       
    93 def wrapcopylist(orig, *args, **kwargs):
       
    94     l = orig(*args, **kwargs)
       
    95     if 'store/obsstore' not in l:
       
    96         l.append('store/obsstore')
       
    97     return l
       
    98 
    85 
    99 
    86 
   100 ### Patch changectx
    87 ### Patch changectx
   101 #############################
    88 #############################
   102 
    89