Web开发-LinuxGit基础2-本地-git仓库操作

  1. 把当前目录做成一个git仓库的方法是_______________________________;

  2. 把当前目录做成一个git仓库的方法是_______________________________;

  3. 把当前目录做成一个git仓库的方法是_______________________________;

  4. 将A20240618.yaml文件添加到git仓库的方法是_______________________________;

  5. 将所有以".yaml"结尾的文件添加到git仓库的方法是_______________________________;

  6. 将该目录下所有文件、文件夹都添加到git仓库的方法是________________________________;

  7. 查看仓库变动的方法是___________________________;

  8. 查看仓库变动的方法是___________________________;

  9. 查看仓库变动的方法是___________________________;

  10. 如果发现sub1.yaml被改动过了,那么如何查看sub1.yaml是如何被改动的呢?

  11. 如果发现sub2.yaml被改动过了,那么如何查看sub1.yaml是如何被改动的呢?

  12. 如何提交sub1.yaml的改动呢?

  13. 如何提交sub2.yaml的改动呢?

  14. 查看git历史提交记录的方法是________________________;

  15. 查看git历史提交记录的方法是________________________;

  16. 查看简洁的git历史提交记录的方法是_________________________;

  17. 查看简洁的git历史提交记录的方法是_________________________;

  18. 使用hard模式,让git回退到上一个版本_________________________;

  19. 让git前进到新版本________________________;

  20. 使用默认模式,让git回退到上一个版本_________________________;

  21. 让git前进到新版本________________________;

git add 与 git commit 的区别是什么?

git add 与 git commit 的区别是什么?

git add 与 git commit 的区别是什么?

  1. 当sub1.yaml已经在暂存区中时,把sub1.yaml移出暂存区的方法是________________________________;

  2. 当sub1.yaml不在暂存区中,把sub1.yaml的修改去掉的方法是_______________________________;

  3. 当sub2.yaml已经在暂存区中时,把sub2.yaml移出暂存区的方法是________________________________;

  4. 当sub2.yaml不在暂存区中,把sub2.yaml的修改去掉的方法是_______________________________;

  5. git init

  6. git init

  7. git init

  8. git add "*" 然后 git commit -m "20240619.no4"

  9. git add "*" 然后 git commit -m "20240619.no5"

  10. git add "*" 然后 git commit -m "20240619.no6"

  11. git status

  12. git status

  13. git status

  14. git diff sub1.yaml

  15. git diff sub2.yaml

  16. git add sub1.yaml 然后 git commit -m "20240619.no12"

  17. git add sub2.yaml 然后 git commit -m "20240619.no13"

  18. git log

  19. git log

  20. git log --pertty=oneline

  21. git log --pertty=oneline

  22. git reset --hard 088e4402895d0b71d5317e0519ccc43328162fcb

  23. git reflog 然后 git reset --hard <新版本id>

  24. git rest 088e4402895d0b71d5317e0519ccc43328162fcb

  25. git reflog 然后 git reset <新版本id>

git add 将修改提交到暂存区,git commit将暂存区提交

git add 将修改提交到暂存区,git commit将暂存区提交

git add 将修改提交到暂存区,git commit将暂存区提交

  1. git restore --staged sub1.yaml

  2. git restore sub1.yaml

  3. git restore --staged sub1.yaml

  4. git restore sub1.yaml

相关推荐
zhangxingchao2 小时前
Kotlin常用的Flow 操作符整理
前端
IT_陈寒4 小时前
React的useState居然还有这种坑?我差点删库跑路
前端·人工智能·后端
Pedantic5 小时前
SwiftUI 手势笔记
前端·后端
橙子家5 小时前
浏览器缓存之【结构化数据库与缓存】: IndexedDB、Cache storage 和 Storage buckets
前端
user20585561518135 小时前
X6 中边悬浮置顶,规避 `mouseleave` 事件丢失问题
前端
李明卫杭州5 小时前
CSS aspect-ratio 属性完全指南
前端
Pedantic7 小时前
SwiftUI 手势层级(Gesture Hierarchy)详解
前端
飘尘8 小时前
前端转型全栈(Java后端)的快速上手指引
前端·后端·全栈
一颗烂土豆8 小时前
Meshopt 压缩深度解析,为什么它比 Draco 更快
前端·javascript·webgl