git quiz分析总结

1. Which option should you use to set the default user name for every repository on your computer?

  • To set a name for every Git repository on your machine, use $ git config --global user.name "John Smith"

2. What is the command to set the user email for the current repository?

git config --global user.name "Your Name"

git config --global user.email "you@example.com"

3. What is the command to view the history of commits for the repository?

The most basic and powerful tool to do this is the git log command.

4. What is the command to create a new branch named "new-email"?

git branch new-branch-name

5. What is the command to move to the branch named "new-email"?

git checkout -b <new-branch>

6. What is the option, when moving to a branch, to create the branch it if it does not exist?

-b  

7. What is the command to delete the branch "new-email"

git branch -d new-email

8. What is the command to get all the change history of the remote repository "origin"?

Fetching changes from a remote repository

Use git fetch to retrieve new work done by other people. Fetching from a repository grabs all the new remote-tracking branches and tags without merging those changes into your own branches.

9. Git Pull is a combination of:

The git pull command is actually a combination of two other commands, git fetch followed by git merge. In the first stage of operation git pull will execute a git fetch scoped to the local branch that HEAD is pointed at. Once the content is downloaded, git pull will enter a merge workflow. 

10.

LINK: https://www.w3schools.com/quiztest/result.asp

Git Fetch | Atlassian Git Tutorial

相关推荐

  1. 数据分析简单项目总结

    2024-02-10 00:34:01       62 阅读
  2. android卡顿流程分析总结

    2024-02-10 00:34:01       42 阅读

最近更新

  1. docker php8.1+nginx base 镜像 dockerfile 配置

    2024-02-10 00:34:01       94 阅读
  2. Could not load dynamic library ‘cudart64_100.dll‘

    2024-02-10 00:34:01       101 阅读
  3. 在Django里面运行非项目文件

    2024-02-10 00:34:01       82 阅读
  4. Python语言-面向对象

    2024-02-10 00:34:01       91 阅读

热门阅读

  1. 20240208作业

    2024-02-10 00:34:01       42 阅读
  2. Lua序列化

    2024-02-10 00:34:01       49 阅读
  3. 程序设计语言之机器语言、汇编语言、高级语言

    2024-02-10 00:34:01       50 阅读
  4. C语言中的typedef关键字:为类型定义新名称

    2024-02-10 00:34:01       46 阅读
  5. 【SQL】力扣1445. 苹果和桔子

    2024-02-10 00:34:01       54 阅读
  6. 使用Collections.singletonList()遇到的问题

    2024-02-10 00:34:01       48 阅读
  7. c#观察者设计模式

    2024-02-10 00:34:01       55 阅读
  8. Python金融_使用Pandas进行股票量化回测

    2024-02-10 00:34:01       37 阅读
  9. 11 OpenGL可编程顶点处理

    2024-02-10 00:34:01       43 阅读
  10. C#中的 async void 、 async Task与async Task<TResult>

    2024-02-10 00:34:01       45 阅读