Uploaded image for project: 'Bitbucket Cloud'
  1. Bitbucket Cloud
  2. BCLOUD-20223

Source view URL of branch name with slashes broken (e.g. "feat/foo")

    XMLWordPrintable

Details

    Description

      Related issue: BCLOUD-408

      I maintain a popular utility called git-open which opens a browser to your bitbucket/github/gitlab to view whatever branch you have checked out.

      Bitbucket makes this pretty difficult if there's a slash in the branch name. (Which it surprisingly common


      For example, in the Guyzmo/git-repo project, following the official docs I can view the devel branch with this URL:
      https://bitbucket.org/guyzmo/git-repo/src/devel

      Easy enough, but here's the problem:

      For the bugfix/conftest_fix branch, bitbucket provides a 404 for a similar URL: https://bitbucket.org/guyzmo/git-repo/src/bugfix/conftest_fix
      And we get the same result if we URL-encode the slash: https://bitbucket.org/guyzmo/git-repo/src/bugfix%2Fconftest_fix

      When using the site to view the branch we get a /src/<commit hash>/?at=<branch/name> URL. So while this is a workaround, it makes for more awkward ergonomics. :/


      Ideally, a fix would make either of the above 404'ing URLs start to work. Thanks!

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              d52e2f9c57cf paulirish
              Votes:
              40 Vote for this issue
              Watchers:
              37 Start watching this issue

              Dates

                Created:
                Updated: