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.

  1. 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>

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

-b

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

git branch -d new-email

  1. 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.

  1. 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.

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

Git Fetch | Atlassian Git Tutorial

相关推荐
BugShare2 小时前
有趣味的登录页它踏着七彩祥云来了
vue·css3
xiaotao1319 小时前
什么是 Tailwind CSS
前端·css·css3
xiaotao13116 小时前
03. 原子化 CSS 思想
前端·css·tailwind
爱宇阳16 小时前
Nuxt4 + Tailwind CSS v4 自定义响应式断点完整指南
前端·css·nuxt4
孟祥_成都21 小时前
前端下午茶:这 3 个网页特效建议收藏(送源码)
前端·javascript·css
小璐资源网1 天前
CSS进阶指南:深入解析选择器优先级与继承机制
前端·css
ZHOUPUYU1 天前
PHP性能分析与调优:从定位瓶颈到实战优化
开发语言·后端·html·php
weixin_462901971 天前
ESP32电压显示
开发语言·javascript·css·python
Dxy12393102161 天前
HTML常用布局详解:从基础到进阶的网页结构指南
前端·html
Dxy12393102162 天前
CSS常用样式详解:从基础到进阶的全面指南
前端·css