中文亚洲精品无码_熟女乱子伦免费_人人超碰人人爱国产_亚洲熟妇女综合网

當(dāng)前位置: 首頁 > news >正文

.net mvc做網(wǎng)站一鍵優(yōu)化清理

.net mvc做網(wǎng)站,一鍵優(yōu)化清理,商城域名,北京專業(yè)的網(wǎng)站建設(shè)文章目錄 1. 查詢 git log 的文檔2. 不帶任何參數(shù): git log 啥意思&#xff1f;3. git log 最主要功能是什么&#xff1f;4. git log <commit1>..<commit2> 什么意思5. 查看最近n次commit6. References 1. 查詢 git log 的文檔 git help log --web市面上針對 git …

文章目錄

    • 1. 查詢 git log 的文檔
    • 2. 不帶任何參數(shù): `git log` 啥意思?
    • 3. `git log` 最主要功能是什么?
    • 4. `git log <commit1>..<commit2>` 什么意思
    • 5. 查看最近n次commit
    • 6. References

1. 查詢 git log 的文檔

git help log --web

在這里插入圖片描述
市面上針對 git logoptions 講解的文章很多,對于 <revision-range> 講解的很少,白魚在這篇帶你游覽 git log <revision-range> 的用法。

2. 不帶任何參數(shù): git log 啥意思?

前一節(jié)知道了 git 完整用法

git log [<options>] [<revision-range>] [[--] <path>]

因此,當(dāng)不帶任何參數(shù):

git log

意味著:

  • <options> 為空
  • <revision-range> 為默認(rèn)范圍
  • <path> 沒有指定

那么默認(rèn)的 <revision-range> 是什么?答案是 HEAD:
在這里插入圖片描述
也就是說:git log 等價于 git log HEAD. HEAD的含義我們先前有提過,它表示“當(dāng)前分支”, 或者說當(dāng)前分支的最新節(jié)點。因此 git log 也就是 git log HEAD 意思是:從當(dāng)前分支最新節(jié)點 HEAD往前回溯,所有能被回溯的節(jié)點,都列出來。懂了嗎?

git log 等價于 git log HEAD, 意思是列出當(dāng)前分支所有 commit 節(jié)點。

3. git log 最主要功能是什么?

我們來看 git log 的 description 第一段的解釋:

Shows the commit logs.

List commits that are reachable by following the parent links from the given commit(s), but exclude commits that are reachable from the one(s) given with a ^ in front of them. The output is given in reverse chronological order by default.

You can think of this as a set operation. Commits reachable from any of the commits given on the command line form a set, and then commits reachable from any of the ones given with ^ in front are subtracted from that set. The remaining commits are what comes out in the command’s output. Various other options and paths parameters can be used to further limit the result.

說的很直白了:git log 列出給定的 commit 的所有可回溯的節(jié)點,并且略掉 ^ 開頭的節(jié)點及其所有可回溯節(jié)點。

因此:

git log foo bar ^baz

意思是列出 foo 的所有可回溯節(jié)點、bar 的所有可回溯節(jié)點、 但是會去除 baz 及其所有可回溯節(jié)點。

換言之, git log 命令最主要的功能,是根據(jù)給出的若干 commit, 每個commit對應(yīng)一個集合,執(zhí)行集合的合并以及減法操作,最終得到一個 commit 集合。

如果還不明白,再解釋一下 git log foo bar ^baz:

  • foo: 得到以 foo 為末尾節(jié)點的 commit 集合 foo-set
  • bar: 得到以 bar 為末尾節(jié)點的 commit 集合 bar-set
  • ^baz: 得到以 baz 為末尾節(jié)點的 commit 集合 baz-set
  • 最終計算: foo-set + bar-set - baz-set

4. git log <commit1>..<commit2> 什么意思

A special notation “…” can be used as a short-hand for “^ ”. For example, either of the following may be used interchangeably:

$ git log origin..HEAD
$ git log HEAD ^origin

也就是說, git log <commit1>..<commit2>git log ^<commit1> <commit2> 的簡寫, 意思是從 commit2 回溯得到的 commit 集合, 減去 commit1 及其回溯得到的集合。

實際上 <commit1><commit2> 也可以換成分支的名字, 例如 git log main..feature 表示的是, feature 分支特有的、 main 分支沒有的 commit:

在這里插入圖片描述
再舉一個極端例子:如果只想查看某個 git repo 的第一個commit: 首先用 gitk 或 git log 等任意工具查詢得到第一個 commit 的 sha-1, 然后執(zhí)行

git log <first-commit-sha>

gitk log <first-commit-sha>

從而只查看第一個commit

在這里插入圖片描述
在這里插入圖片描述

5. 查看最近n次commit

很多人的直覺是:

git log -n

但其實基于上一節(jié)的結(jié)論,很容易想到另一種表示:

git log HEAD ^HEAD~n

6. References

  • https://git-scm.com/docs/git-log
  • https://www.atlassian.com/git/tutorials/git-log
http://www.risenshineclean.com/news/33313.html

相關(guān)文章:

  • 單縣網(wǎng)站定制網(wǎng)絡(luò)營銷策劃的主要特點
  • 國外網(wǎng)站 服務(wù)器青島seo排名公司
  • 網(wǎng)頁即時聊天seo推廣怎么樣
  • 用動物做網(wǎng)站名稱可以投放廣告的網(wǎng)站
  • 沒有備案的網(wǎng)站可以做淘寶客seo網(wǎng)絡(luò)推廣培訓(xùn)班
  • 校園論壇網(wǎng)站怎么做谷歌收錄提交入口
  • 長沙岳麓區(qū)做網(wǎng)站seo內(nèi)容優(yōu)化是什么
  • 怎么做網(wǎng)站首頁全媒體廣告代理
  • 去國外做移動支付網(wǎng)站嗎廣告投放網(wǎng)站
  • 四川網(wǎng)站建設(shè)一站式服務(wù)商互聯(lián)網(wǎng)公司網(wǎng)站模板
  • 企業(yè)oa系統(tǒng)免費優(yōu)化網(wǎng)站建設(shè)seo
  • 淘寶做個網(wǎng)站多少錢seo概念
  • 一級a做爰片免費無碼網(wǎng)站網(wǎng)絡(luò)流量分析工具
  • php網(wǎng)站開發(fā)百度云產(chǎn)品推廣計劃方案
  • 網(wǎng)站對比app還有優(yōu)勢嗎2023第三波疫情已經(jīng)到來了
  • 網(wǎng)站空間多久續(xù)一次費seo優(yōu)化團(tuán)隊
  • 鎮(zhèn)江外貿(mào)網(wǎng)站建設(shè)站外推廣渠道有哪些
  • Axure只是做網(wǎng)站嗎怎么注冊一個自己的網(wǎng)址
  • 湛江自做網(wǎng)站杭州谷歌推廣
  • 河南科興建設(shè)有限公司網(wǎng)站網(wǎng)站推廣公司黃頁
  • 石家莊專業(yè)商城網(wǎng)站制作百度如何優(yōu)化
  • 用身份證備案網(wǎng)站外貿(mào)營銷渠道
  • 天津市建設(shè)工程評標(biāo)專家網(wǎng)站谷歌google官網(wǎng)下載
  • 為什么登錄不上建設(shè)銀行網(wǎng)站上海網(wǎng)站建設(shè)推廣服務(wù)
  • 蒼南龍港做網(wǎng)站店鋪亞馬遜免費的關(guān)鍵詞工具
  • 網(wǎng)站建設(shè)與網(wǎng)頁制作技術(shù)拉新項目官方一手平臺
  • 龍灣做網(wǎng)站歌爾股份砍單
  • 合肥做公司網(wǎng)站公司太原網(wǎng)站推廣排名
  • 美國室內(nèi)設(shè)計聯(lián)盟優(yōu)化步驟
  • 捕魚游戲網(wǎng)站制作模板虞城seo代理地址