I am trying to integrate various Markdown files that I have prepared offline into my BitBucket wiki. I have successfully committed the files via Git and I can open them within the BitBucket website, but somehow, I fail to link to them. I know it should be obvious, but I haven't yet found out how to do it, and the documentation doesn't appear to describe inter-page linking.
For instance, within the wiki root directory, I have a subdirectory `a` with a file `b.md`.
I can open `https://bitbucket.org/<group>/<project>/wiki/a/b` and successfully arrive at the content of the aforementioned `b.md`.
However, if I add a link like `[b](a/b)` to one of my existing wiki pages, that link will not work (when trying from within the page preview). The resulting page will claim:
> Hmm... can't find that one
Hello Florian,
I went through and tested this to ensure linking to internal pages works as expected. Using the following will only attempt to find the page/file within the same directory and it will not reach out to the child directory (even though you referenced it)
[Name](path/page)
If you’re wanting to reference a page that is a child under another page, you will need to use the full URL within the link, such as:
[Name](https://bitbucket.org/group/myproject/wiki/Home/ChildPage)
There was a bug reported for this similar issue, but the response back was this is how it is supposed to function and the bug request was closed. You may find that request at Issue #9014.
The solution for this seems to be to link the full URL to pages that are a child of another page.
I hope this information proves helpful in resolving your linkage issues within Bitbuckets wiki.
Regards,
Stephen Sifers
I do not consider linking to the full URL a valid solution - as soon as the base URL of the wiki changes (project rename, clone/branch, or already when displaying the wiki pages locally from the working copy), the links will be broken (because they point back to the original wiki location rather than the place where the entry page is currently displayed from). So, in short, Bitbucket's wiki doesn't support subfolders.
That is quite unfortunate in terms of structuring large wikis, as a checked out local working copy of a wiki Git repository will end up a huge folder with countless files.
Good to know of course, so I'll accept this answer.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I know this is not perfect, but you can use relative URLs.
[Name](Home/ChildPage)
In this way, you can change the base URL of the wiki without breaking the links.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Child pages
Linking to child pages can be done directly:
Inside https://bitbucket.org/workspace/repo/wiki/Home:
# Home
See [Folder/File2](folder/file2)
Will correctly link to: https://bitbucket.org/workspace/repo/wiki/folder/file2
Peer pages
The accepted answer is still valid: there is no real support for linking to pages that have a different parent.
However, playing with relative URLs does seem to work (at least sometimes):
Inside https://bitbucket.org/workspace/repo/wiki/folder/file1:
# File 1
See [OtherFolder/File2](../../wiki/other_folder/file2).
Will correctly link to: https://bitbucket.org/workspace/repo/wiki/other_folder/file2
If you only use a single parent directory symbol (../), the resulting URL will be /src/other_folder/file2. (This is how you can link to files from e.g. your README.md.)
Warning: use such linking at your own risk. This feels more like something that accidentally works than a real feature.
Tip: the preview feature on a wiki editing page seems to resolve link URLs the same way as the real wiki renderer, use that to test your links.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.