~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/__init__.py

  • Committer: Martin Pool
  • Date: 2005-09-20 04:59:34 UTC
  • mfrom: (1185.1.32)
  • mto: (1185.8.2)
  • mto: This revision was merged to the branch mainline in revision 1390.
  • Revision ID: mbp@sourcefrog.net-20050920045934-2b9a193376bc9b7e
- merge integration from robertc
robertc@robertcollins.net-20050919064054-0da08709ee180b79

Show diffs side-by-side

added added

removed removed

Lines of Context:
33
33
 
34
34
IGNORE_FILENAME = ".bzrignore"
35
35
 
 
36
import os
36
37
import locale
37
38
user_encoding = locale.getpreferredencoding() or 'ascii'
38
39
del locale
48
49
    from bzrlib.branch import Branch
49
50
    
50
51
    try:
51
 
        branch = Branch.open(__path__[0])
 
52
        branch = Branch.open(os.path.dirname(__path__[0]))
52
53
        rh = branch.revision_history()
53
54
        if rh:
54
55
            return len(rh), rh[-1]