[Day12] Git 学习总整理

今天把这几天学习的纪录做一个总整理,在指令或是GUI操作上的心得是
指令操作熟悉者可以带入各类参数灵活运用
GUI操作则是可以直觉式的操作、入门快速
所以下面整理的表格是以GUI能做到为主,并列出对应到的指令,带参数的进阶用法就不会列出

指令 VS Code Git Graph 功用
git init 先在本地开一个资料夹再切换到分支页https://ithelp.ithome.com.tw/upload/images/20210920/20129729PiPbLaAuMt.png 初始化本地资料夹
git clone 网址 https://ithelp.ithome.com.tw/upload/images/20210920/20129729AR1yANtJ8b.png 复制远端repo(储存库)
git add 档案名称 https://ithelp.ithome.com.tw/upload/images/20210920/20129729pTqxJFsQLE.png 加入追踪
git reset 档案名称 https://ithelp.ithome.com.tw/upload/images/20210920/20129729znxuyFeHLK.png 取消追踪
git commit -m 名称 输入讯息後,按 ⌘ + Enter 送出;要有档案变更才行,不然会跳出询问视窗https://ithelp.ithome.com.tw/upload/images/20210920/20129729LzzhF3xzhl.png 提交,并且撰写一段说明讯息
git show commit的hash至少4码 左键点击名称就可以展开,再点一次收阖https://ithelp.ithome.com.tw/upload/images/20210920/20129729O3uLb7AWIL.png 查看commit详细资讯
git branch 名称 & git checkout 名称 或是 git checkout -b 名称 建立分之後会直接checkout过去https://ithelp.ithome.com.tw/upload/images/20210920/20129729p0FlIVgbD4.png 在commit名称的地方点右键出现新增分支的选单(可以选择要不要checkout过去);在branch名称位置点右键出现的选单会不一样https://ithelp.ithome.com.tw/upload/images/20210920/20129729MrC2iLpKDR.png 建立分支
git merge 名称 ⌘ + shift + p 搜寻 merge(没有可以快速点击的选单或按钮) https://ithelp.ithome.com.tw/upload/images/20210920/20129729Bb6y7r2qlU.png 合并分支;遇到冲突时,冲突的档案会标示出要修正的项目,完成修正後执行 add & commit 即可完成mergehttps://ithelp.ithome.com.tw/upload/images/20210920/20129729gsvOmp3VtQ.png
git tag 名称 无 | commit名称右键选单https://ithelp.ithome.com.tw/upload/images/20210920/20129729tmpvw5olLd.png 新增标签
git tag -d 名称 tag名称右键选单https://ithelp.ithome.com.tw/upload/images/20210920/20129729CSLN5vZ6R7.png 删除标签
git stash 名称 选单上功能就很够用了https://ithelp.ithome.com.tw/upload/images/20210920/201297290yJn6wrqaT.png 跟vscode差不多https://ithelp.ithome.com.tw/upload/images/20210920/20129729zG87u2pmaF.png 建立暂存
git stash pop stash管理都在同一个选单https://ithelp.ithome.com.tw/upload/images/20210920/20129729804XsGbaw5.png 跟vscode差不多https://ithelp.ithome.com.tw/upload/images/20210920/20129729LsQiwEN1uR.png 恢复暂存

<<:  Python random 套件

>>:  Youtube Data API 教学 - 抓取你的金钥 API key

0 day 安全笔记 第二章 基本知识 上

OS:XP SP3 编译器: DEV C++ 4.9.9.2 工具: OD (ollydbg) CF...

Day 12 - PHP SDK: 建立信用卡、虚拟帐号订单

昨天发布了 Sinopac PHP SDK,接着来有几天的篇幅会介绍如何使用。今天先来谈谈建立订单的...

【第一天 - Flutter 生命周期+基本观念介绍】

什麽是 StatefulWidget? 他是一个具备 State(状态)的元件,里面所有可变状态的子...

《正因为很简单,就迷失在茫茫人海》

“我们做专题报导,深入报导,比别人花更多时间去找资料,查证。 做那麽爽还不是三分钟就被别的新闻台抄去...

Day 14 - AI-900 认证心得(2) - 考试

值得一题的是我是用Microsoft Edge浏览器顺利完成报名的, 我也不知道是什麽原因, 要准...