1. Takumi IINO
  2. hgbb


Takumi IINO  committed 4f23997

Convert path for url. bblink work on windows

  • Participants
  • Parent commits 15ae319
  • Branches default

Comments (0)

Files changed (1)

File hgbb.py

View file
 def bb_link(ui, repo, filename=None, **opts):
     '''display a bitbucket link to the repository, or the specific file if given'''
-    # XXX: might not work on windows, because it uses \ to separate paths
     lineno = opts.get('lineno')
     reponame = get_bbreponame(ui, repo, opts)
     nodeid = str(repo[None])
         # our wc is dirty, just take the node id and be happy
         nodeid = nodeid[:-1]
     if filename:
-        path = os.path.relpath(filename, repo.root)
+        path = util.pconvert(os.path.relpath(filename, repo.root))
         path = ''
     url = 'http://bitbucket.org/%s/src/%s/%s'