Mercurial > public > mercurial-scm > hg-stable
comparison contrib/debugshell.py @ 19772:6ccec36a1fd9
debugshell: add function to embed ipython
author | Sean Farley <sean.michael.farley@gmail.com> |
---|---|
date | Sun, 14 Jul 2013 12:02:36 -0500 |
parents | 3bc675361206 |
children | 51799a965446 |
comparison
equal
deleted
inserted
replaced
19771:3bc675361206 | 19772:6ccec36a1fd9 |
---|---|
12 'mf': repo.manifest, | 12 'mf': repo.manifest, |
13 } | 13 } |
14 | 14 |
15 code.interact(msg, local=objects) | 15 code.interact(msg, local=objects) |
16 | 16 |
17 def ipdb(ui, repo, msg, **opts): | |
18 import IPython | |
19 | |
20 cl = repo.changelog | |
21 mf = repo.manifest | |
22 | |
23 IPython.embed() | |
24 | |
17 def debugshell(ui, repo, **opts): | 25 def debugshell(ui, repo, **opts): |
18 bannermsg = "loaded repo : %s\n" \ | 26 bannermsg = "loaded repo : %s\n" \ |
19 "using source: %s" % (repo.root, | 27 "using source: %s" % (repo.root, |
20 mercurial.__path__[0]) | 28 mercurial.__path__[0]) |
21 | 29 |