Skip to content

Latest commit

 

History

History
36 lines (31 loc) · 2.13 KB

internal-mirror.md

File metadata and controls

36 lines (31 loc) · 2.13 KB

Mirroring GitHub to dev.azure.com/dnceng and dev.azure.com/devdiv

Public code should be mirrored to dev.azure.com/dnceng/internal or dev.azure.com/dnceng/devdiv, depending on where your pipelines live. (see Azure DevOps Guidance). These are the steps for setting up your GitHub repo for mirroring.

  1. Make sure you have a repo in the dev.azure.com/dnceng/internal project with a name in the format "{org}-{repo}" (replace any / with - in the GitHub repo name). Please follow up with dnceng if a repository does not exist. For DevDiv repos, the pattern is {org}-{repo}-Trusted.
    • Example: github.com/dotnet/arcade => dotnet-arcade
  2. Create a PR to the dotnet-mirroring internal repo which adds data for repo and branches that you want mirrored, to the dnceng subscriptions json or devdiv subscriptions json files. Specifically, add a URI for your GitHub repository to the repos object, then types of mirroring and regex branch patterns. Please alphabetize.

Example:

    "https://github.com/dotnet/source-indexer": {
      "fastForward": [
        "main"
      ]
    },
    "https://github.com/dotnet/sourcelink": {
      "fastForward": [
        "main", // Fast forward main -> main
        "release/.*"
      ]
    },
    "https://github.com/dotnet/spa-templates": {
      "fastForward": [
        // GitHubBranchNotFound "main",
        "release/.*"
      ],
      "internalMerge": [
        "release/.*" // Merge release/.* -> internal/release/.*
      ]
    },

Was this helpful? Yes No