Changing the repos from github to local repos.

Copper Contributor

Hi All,


I have configured the project in Azure DevOps using github repos. Now i need use local Azure repos. Please suggest me the steps to do the same.



1 Reply



Switching from GitHub repositories to Azure DevOps repositories is a relatively straightforward process. Here are the general steps to follow:


  1. Create a New Azure DevOps Repository:

    • Go to your Azure DevOps project.
    • Navigate to the "Repos" section.
    • Click on the "+ New" button to create a new repository.
    • Choose the repository type (Git or TFVC) you want to use.
  2. Clone the New Repository:

    • Once you've created the new repository, clone it to your local machine using Git. You can find the repository URL on the Azure DevOps repository page.
    bashCopy code
    git clone <repository_url>
  3. Copy Your GitHub Project:

    • Copy the files from your existing GitHub project to the new local repository you just cloned. You can do this by simply copying the files into the local repository directory.
  4. Commit and Push Changes:

    • After you've copied your project files into the local repository, commit those changes.
    sqlCopy code
    git add . git commit -m "Initial commit" git push origin master
  5. Update Remote URLs:

    • If you want to remove the GitHub connection entirely, you can update the remote URL to point to your Azure DevOps repository.
    arduinoCopy code
    git remote set-url origin <azure_repo_url>
  6. Verify and Continue Development:

    • Verify that your code is now in the Azure DevOps repository.
    • Continue your development work using the Azure DevOps repository.

This process assumes you want to migrate your code to a new Azure DevOps repository while keeping the existing GitHub repository untouched. If you want to completely disconnect from GitHub, you can simply remove the GitHub remote using the git remote remove command.

Also update any CI/CD pipelines or other integrations that may be connected to your GitHub repository to use the new Azure DevOps repository.


Follow the Link