Welcome to ExamTopics
ExamTopics Logo
- Expert Verified, Online, Free.

Unlimited Access

Get Unlimited Contributor Access to the all ExamTopics Exams!
Take advantage of PDF Files for 1000+ Exams along with community discussions and pass IT Certification Exams Easily.

Exam AZ-400 topic 5 question 36 discussion

Actual exam question from Microsoft's AZ-400
Question #: 36
Topic #: 5
[All AZ-400 Questions]

DRAG DROP
-

You have a GitHub repository named repo1.

You migrate repo1 to an Azure Repos repository named repo2.

After the migration, changes are made to repo1.

You need to sync the changes to repo2.

How should you complete the script? To answer, drag the appropriate values to the correct targets. Each value may be used once, more than once, or not at all. You may need to drag the split bar between panes or scroll to view content.

NOTE: Each correct selection is worth one point.

Show Suggested Answer Hide Answer
Suggested Answer:

Comments

Chosen Answer:
This is a voting comment (?) , you can switch to a simple comment.
Switch to a voting comment New
KumaTed
Highly Voted 1 year ago
has checked on github, should be 1. repo2_clone_url 2. repo2_directory 3. repo1_clone_url 1. clone the empty repo (repo2) into local 2. enter into the folder (repo2) 3. add one more remote repo "upstream" (repo1) 4. fetch the latest code from the remote repo "upstream" (repo1) 5. push the code to the remote repo "origin" (repo2)
upvoted 28 times
tomhansen
11 months, 3 weeks ago
repo2_directory? that's not one of the options
upvoted 3 times
...
dgcc97
1 year ago
Correct, according to https://learn.microsoft.com/en-us/azure/devops/repos/git/import-git-repository?view=azure-devops#can-i-import-updates-if-the-source-changes-later
upvoted 1 times
dgcc97
1 year ago
Correction, the 3 should be the repo1_repo_url
upvoted 5 times
...
...
gabo
9 months, 2 weeks ago
3. repo1 repo URL
upvoted 4 times
...
djhyfdgjk
5 months, 3 weeks ago
Why 'repo2 clone url' and not 'repo2 repo url' ?? Did you make a clone of repo2 ??
upvoted 1 times
...
...
renzoku
Highly Voted 11 months ago
1. repo2 clone url 2. repo2 3. repo1 repo URL https://learn.microsoft.com/en-us/azure/devops/repos/git/import-git-repository?view=azure-devops#can-i-import-updates-if-the-source-changes-later
upvoted 21 times
Tuki93
4 months, 3 weeks ago
git clone --bare <Azure-Repos-clone-URL>.git cd <name-of-repo> git remote add --mirror=fetch upstream <original-repo-URL> git fetch upstream --tags git push origin --all
upvoted 2 times
...
Gabsyfire
5 months, 1 week ago
very correct
upvoted 1 times
...
...
jraillard
Most Recent 3 months, 3 weeks ago
As it is repo1 you want to sync into repo2 (as repo2 is a migration from repo1), it should be : - git clone --bare <url-to-repo1> repo1 (and here the question is missing adding a suffixing as a good practice such as ".git" or "-bare") - cd repo1 (+suffix) - git remote add --mirror=fetch upstream <url-to-repo2> -
upvoted 3 times
...
ozbonny
4 months, 2 weeks ago
git clone --bare <Azure-Repos-clone-URL>.git cd <name-of-repo> git remote add --mirror=fetch upstream <original-repo-URL> git fetch upstream --tags git push origin --all
upvoted 1 times
...
hanzocodes
6 months, 2 weeks ago
repo2 clone url cd repo 2 repo1 clone url 2Clone CD2 in 1Class git clone --bare <Azure-Repos-clone-URL>.git cd <name-of-repo> git remote add --mirror=fetch upstream <original-repo-URL> git fetch upstream --tags git push origin --all https://learn.microsoft.com/en-us/azure/devops/repos/git/import-git-repository?view=azure-devops#can-i-import-updates-if-the-source-changes-later
upvoted 2 times
...
varinder82
7 months, 1 week ago
Final answer after going through all the comments 1. repo2 clone url 2. repo2 3. repo1 repo URL
upvoted 5 times
...
flafernan
11 months ago
# Clone the repo1 GitHub repository as a simple repository git clone --bare https://github.com/usuario/repo1.git # Access the cloned repository directory cd repo1.git # Add repo2 repository as a remote named "upstream" and set mirroring to fetch git remote add --mirror=fetch upstream https://dev.azure.com/organization/project/_git/repo2 # Get updates from repo2 repository including tags git fetch upstream --tags # Push all references to repo2 repository in Azure Repos git push origin --all
upvoted 4 times
...
flafernan
11 months ago
# Clonar o repositório repo1 do GitHub como um repositório bare git clone --bare https://github.com/usuario/repo1.git # Acessar o diretório do repositório clonado cd repo1.git # Adicionar o repositório repo2 como um remote chamado "upstream" e definir o espelhamento para fetch git remote add --mirror=fetch upstream https://dev.azure.com/organization/project/_git/repo2 # Obter as atualizações do repositório repo2, incluindo as tags git fetch upstream --tags # Empurrar todas as referências para o repositório repo2 no Azure Repos git push origin --all
upvoted 1 times
...
resonant
11 months, 3 weeks ago
What is the difference between "repo1 repo url" and "repo1 clone url"?
upvoted 5 times
...
sk4shi
1 year ago
The provided answer is correct. It is the same question as Topic 5 question 26. See here for reference: https://learn.microsoft.com/en-us/azure/devops/repos/git/import-git-repository?view=azure-devops
upvoted 2 times
...
kay000001
1 year, 1 month ago
git clone --bare <repo1_clone_url> cd <repo1_directory> git remote add --mirror=fetch upstream <repo1_repo_url> git fetch upstream --tags git push --mirror <repo2_repo_url> Please correct me if I am wrong.
upvoted 6 times
Dats1987
7 months, 1 week ago
wrong. This is the correct sequence from ms documentation. https://learn.microsoft.com/en-us/azure/devops/repos/git/import-git-repository?view=azure-devops#can-i-import-updates-if-the-source-changes-late git clone --bare <Azure-Repos-clone-URL>.git cd <name-of-repo> git remote add --mirror=fetch upstream <original-repo-URL> git fetch upstream --tags git push origin --all
upvoted 1 times
...
...
AxiansPT
1 year, 1 month ago
Shouldn't it be: 1. repo1 Clone URl 2. repo1 3. repo2 Repo URL ?
upvoted 3 times
AxiansPT
1 year ago
This comment is wrong. After further exploring, I believe KumaTed is right. 1. repo2_clone_url 2. repo2_directory 3. repo1_clone_url
upvoted 6 times
...
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...
ex Want to SAVE BIG on Certification Exam Prep?
close
ex Unlock All Exams with ExamTopics Pro 75% Off
  • arrow Choose From 1000+ Exams
  • arrow Access to 10 Exams per Month
  • arrow PDF Format Available
  • arrow Inline Discussions
  • arrow No Captcha/Robot Checks
Limited Time Offer
Ends in