Enable branch creation as part of syncing

Open
#444 0 comments 1 reaction 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
48/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Quiet
Tech stack
github, typescript
Domain
api, backend

Research direction

Start by tracing the syncing flow and the mirror-creation flow, then review issue #445 for the related branch condition. Done means syncing recreates a missing fork branch, can continue afterward, and no longer creates that branch during mirror creation; verify both paths with the repository's existing checks.

Written by the indexing model from the issue text.

Description

enhancement
Is your feature request related to a problem?

In cases where the fork branch that corresponds to a mirror has been renamed or deleted, the syncing function will fail to execute instead of creating the desired branch.

Describe the solution you'd like

During syncing, any missing fork branch should be recreated to allow the sync to continue and provide a way for users to reset a conflicted fork branch. This change would also make it unnecessary to create the fork branch during mirror creation so that logic should be removed.

Describe alternatives you've considered

Alternatively the deletion or renaming of a fork branch could be disallowed through protections on the fork or could result in the corresponding mirror being renamed / deleted.

Additional context

There is currently a bug detailed in #445 that makes this situation more common.

Dominant language
TypeScript
Stars
203
Forks
42
Avg merge
1h 15m
Merged PRs (30d)
8

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from github-community-projects/private-mirrors

All issues in github-community-projects/private-mirrors

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.