Repo clone and branch movement

Vineet S 1,390 Reputation points
2024-10-22T18:39:40.1733333+00:00

Hi, I am doing branch movement but does not know exact flow in gui... Can someone help screenshot of below GUI like GitHub Desktop, Azure DevOps, or SourceTree, can do the following:

  1. Clone the source repo using the GUI interface.
  2. Switch to the branch you want to move (Branch1).
  3. Add the target repository (UATRepo) as a new remote in the GUI.
  4. Push the branch to the UATRepo by selecting it from the GUI's push or publish options.
Azure Data Factory
Azure Data Factory
An Azure service for ingesting, preparing, and transforming data at scale.
11,624 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Amira Bedhiafi 33,071 Reputation points Volunteer Moderator
    2024-10-24T17:03:07.8566667+00:00

    Here are some steps and links to help you :

    1. GitHub Desktop
    • Clone the repo: Open GitHub Desktop, go to the "File" menu, and click "Clone Repository." Choose the repository you want to clone or paste the URL if it’s not listed. You can then select the location to save the repo locally.
    • Switch branches: After cloning, click on the "Current Branch" menu at the top, select the branch you want to work on, and switch to it.
    • Add remote (UATRepo): In GitHub Desktop, you can go to Repository > Repository Settings and add a new remote URL (UATRepo).
    • Push the branch: Once on the correct branch, you can push changes using the "Push origin" button.

    More details are available on GitHub Docs

    1. Azure DevOps (through Visual Studio or Git UI)
    • Clone the repo: In Visual Studio, go to the "Git" menu and choose "Clone Repository." Select Azure DevOps from the list, log in, and clone the repo.
    • Switch branches: Use the Git Changes window to view and switch branches.
    • Add remote (UATRepo): In the Git repository window, you can add a new remote by selecting "Remote Repositories" and inputting the UATRepo URL.
    • Push branch: After switching to your desired branch, you can push it by selecting "Push" from the Git menu.

    For more detailed steps, check Microsoft Learn

    1. SourceTree
    • Clone the repo: In SourceTree, go to "Clone" and enter the repository URL from Azure DevOps or GitHub. Make sure you have the appropriate credentials set (PAT for Azure DevOps).
    • Switch branches: Use the "Branch" dropdown to switch to the branch you want.
    • Add remote: You can add a new remote by going to Repository Settings in SourceTree and inputting the UATRepo URL.
    • Push branch: Once you are on the correct branch, click "Push" and choose the remote repository (UATRepo) to push your changes.

    Check out this guide for SourceTree setup

    These tutorials should help you manage your repo using the GUI tools. Let me know if you need more specific details!

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.