Migrate pages from wiki extension to a team project wiki
Azure DevOps Services | Azure DevOps Server 2022 - Azure DevOps Server 2019
Learn how to migrate pages created using the Wiki Marketplace extension to your team project wiki. With the release of the built-in wiki, any wiki pages created using the Wiki Marketplace extension can be saved to a Git repo in your team project.
Prerequisites
You must be a member of the Contributors group of your team project to migrate wiki pages to your team project wiki.
Migrate pages and other artifacts
- Clone vsts-wikiTools repository and compile the MigrateToVSTSWiki tool.
- Create, and then clone your Azure DevOps wiki.
- Move and commit all Markdown pages to your Azure DevOps wiki.
- Run the wiki migration tool, MigrateToVSTSWiki.exe
- When the wiki migration tool is complete, push the changes to the default main branch,
wikiMain
, of the Azure DevOps wiki repository.
Detailed steps
Clone vsts-wikiTools repository and compile the MigrateToVSTSWiki tool.
Compile the project under the path
Tools/MigrateToVSTSWiki
to generate the migration tool EXE.From a web browser, open your Azure DevOps team project and create your first wiki page.
Get the URL to clone your wiki. See Clone your wiki and edit wiki pages offline.
Name this clone location asLocationA
for this procedure.Clone your wiki repo using your IDE or the git clone command.
Clone the wiki extension repo. The wiki is mapped to a folder given to you during the wiki creation. You can confirm by going to the manage wiki option in the existing wiki, as shown in the following example. Your existing wiki pages are saved under the folder labeled
Root
.For example, you cloned the previously mentioned
sampleWiki
in the locationC:\wiki\sampleWiki*. The wiki pages are saved in the path *C:\wiki\sampleWiki\ _extensionWiki
Name this location as
LocationB
for this procedure.Create an empty folder in any path on your local machine, and name it
LocationC
for this procedure.In summary, the following locations are represented as follows:
- Location A = Azure DevOps Wiki repo
- Location B = Wiki extension repo
- Location C = Empty folder to run migration tool in
Open a command prompt as an administrator and run
MigrateToVSTSWiki.exe
. This tool copies the files from your existing wiki to the destination directory you provide. During copying, the tool converts the pages to be compliant with the Azure DevOps wiki.MigrateToVSTSWiki.exe /source:LocationB /destination:LocationC
For example:
E:\wiki\sampleWiki\_extensionWiki
is the folder in which the existing wiki files are presentE:\Temp\Wiki\New
is the empty folder into which the migrated files are to be copied.
Remove all the files from
LocationA
(if any) apart from the Git related files, such as.gitignore
, and so on.Copy all the files from
LocationC
and paste them intoLocationA
.Run
git add .
to stage all the newly added files inLocationA
for the commit.Run
git commit -m <commit message>
to commit the locally staged files.Run
git push origin wikiMain -f
to push the changes to the default branch of the Azure DevOps wiki.
After you migrate your wiki extension files to the Azure DevOps Wiki, you're ready to uninstall the Wiki extension.
Related articles
- Wiki page title naming conventions
- Clone and update wiki pages offline
- Source code for the wiki tools
- Git quickstart
Contributions
This project adopted the Microsoft Open Source Code of Conduct. For more information, see the Code of Conduct FAQ or contact opencode@microsoft.com with any questions or comments.