github / github/gh-gei

Support migrating to existing GitHub repository

Open
#1,494 0 comments 2 reactions 0 assignees View on GitHub
Dominant language
C#
Stars
478
Forks
146
Avg merge
7d 21h
Merged PRs (30d)
2

Description

## Problem
Currently, `gh ado2gh migrate-repo` requires creating a new repository and fails if the target repository already exists with the error:
```
The Org 'xxx' already contains a repository with the name 'yyy'. No operation will be performed
```

## Use Case
We have already created an empty GitHub repository and want to migrate our Azure DevOps repository (including PRs, comments, history) into this existing repository.

## Current Workaround
The only option is to:
1. Delete the existing GitHub repository
2. Run the migration (which creates a new repo)

## Requested Feature
Add support for migrating into an existing GitHub repository, either:
- Option A: Add a `--overwrite` or `--force` flag to replace existing repo contents
- Option B: Add a `--target-existing` flag to migrate into existing empty repos
- Option C: Support migration without requiring repository creation

## Environment
- CLI Version: 1.26.0
- Source: Azure DevOps
- Target: GitHub Enterprise Cloud

Is there any existing way to accomplish this, or would this be possible to add?

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.