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

Resolve links in readme.wiki/readme.md based on activation of repo Wiki

    XMLWordPrintable

Details

    • Our product teams collect and evaluate feedback from a number of different sources. To learn more about how we use customer feedback in the planning process, check out our new feature policy.

    Description

      Switch the relative wiki link rendering from the mainpage readme.wiki (or even readme.md) depending on whether the repository's Wiki has been activated or not.

      If the Wiki is activated, all wiki links should resolve to ../../<target> relative to the location of the readme.wiki / readme.md in the repository.

      This is because the full URL would be:

      https://bitbucket.org/user/repo/src/commit-id/readme.wiki

      for the source file, and

      https://bitbucket.org/user/repo/wiki/

      for the target file.

      If the Wiki is not activated, all wiki and md links should resolve into the current directory of readme.wiki. ie. the repo commit base url.

      Also links into BCLOUD-14252 which creates extra erroneous path components that need to be fixed first, and BCLOUD-14253 that creates an unwanted /wiki/ subdirectory for every link.

      If wiki links resolve to ../../<target> then the user needs to manually link to wiki/target file. This seems a better approach because ordinarily people would put their wiki files in a wiki subdirectory when the Wiki is not activated. Thus, when people manually link to [[wiki/target]] it would resolve to the BitBucket repo wiki when the Wiki is activated, and to their own wiki/ subdirectory when the wiki is not activated.

      On the other hand if links directly resolve to ../../wiki/<target> then it becomes impossible to easily migrate between the two configuration options because it would make it impossible to use a wiki subdirectory in the main repo that would still operate nicely when turned to the BitBucket repo Wiki.

      Attachments

        Activity

          People

            Unassigned Unassigned
            83b23b0edd42 drydenp
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: