<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                合規國際互聯網加速 OSASE為企業客戶提供高速穩定SD-WAN國際加速解決方案。 廣告
                # git-ls-files > 原文: [https://git-scm.com/docs/git-ls-files](https://git-scm.com/docs/git-ls-files) ## 名稱 git-ls-files - 顯示索引和工作樹中的文件信息 ## 概要 ``` git ls-files [-z] [-t] [-v] [-f] (--[cached|deleted|others|ignored|stage|unmerged|killed|modified])* (-[c|d|o|i|s|u|k|m])* [--eol] [-x <pattern>|--exclude=<pattern>] [-X <file>|--exclude-from=<file>] [--exclude-per-directory=<file>] [--exclude-standard] [--error-unmatch] [--with-tree=<tree-ish>] [--full-name] [--recurse-submodules] [--abbrev] [--] [<file>…?] ``` ## 描述 這將目錄高速緩存索引中的文件列表與實際工作目錄列表合并,并顯示兩者的不同組合。 以下一個或多個選項可用于確定顯示的文件: ## OPTIONS ``` -c ``` ``` --cached ``` 在輸出中顯示緩存的文件(默認) ``` -d ``` ``` --deleted ``` 在輸出中顯示已刪除的文件 ``` -m ``` ``` --modified ``` 在輸出中顯示已修改的文件 ``` -o ``` ``` --others ``` 在輸出中顯示其他(即未跟蹤)文件 ``` -i ``` ``` --ignored ``` 僅顯示輸出中的忽略文件。在索引中顯示文件時,僅打印與排除模式匹配的文件。顯示“其他”文件時,僅顯示與排除模式匹配的文件。標準忽略規則不會自動激活,因此至少需要一個`--exclude*`選項。 ``` -s ``` ``` --stage ``` 在輸出中顯示暫存內容的模式位,對象名稱和階段編號。 ``` --directory ``` 如果整個目錄被歸類為“其他”,則只顯示其名稱(帶斜杠)而不是其全部內容。 ``` --no-empty-directory ``` 不要列出空目錄。沒有--directory沒有效果。 ``` -u ``` ``` --unmerged ``` 在輸出中顯示未合并的文件(強制 - 階段) ``` -k ``` ``` --killed ``` 顯示文件系統上由于文件/目錄沖突而需要刪除的文件,以使checkout-index成功。 ``` -z ``` \ 0輸出行終止,不引用文件名。有關詳細信息,請參閱下面的OUTPUT。 ``` -x <pattern> ``` ``` --exclude=<pattern> ``` 跳過與圖案匹配的未跟蹤文件。請注意,pattern是shell通配符模式。有關詳細信息,請參閱下面的EXCLUDE PATTERNS。 ``` -X <file> ``` ``` --exclude-from=<file> ``` 從&lt; file&gt;中讀取排除模式;每行1個。 ``` --exclude-per-directory=<file> ``` 閱讀僅適用于&lt; file&gt;中的目錄及其子目錄的其他排除模式。 ``` --exclude-standard ``` 添加標準Git排除項:.git / info / exclude,.gitignore在每個目錄中,以及用戶的全局排除文件。 ``` --error-unmatch ``` 如果有任何&lt; file&gt;沒有出現在索引中,將其視為錯誤(返回1)。 ``` --with-tree=<tree-ish> ``` 使用--error-unmatch擴展用戶提供的&lt; file&gt;時(即路徑模式)路徑的參數,假裝自從命名的&lt; tree-ish&gt;以來在索引中刪除的路徑。仍然存在。將此選項與`-s`或`-u`選項一起使用沒有任何意義。 ``` -t ``` 此功能已被半棄用。出于腳本目的, [git-status [1]](https://git-scm.com/docs/git-status) `--porcelain`和 [git-diff-files [1]](https://git-scm.com/docs/git-diff-files) `--name-status`幾乎總是優秀的替代品,用戶應該看一下 [git-status [1]](https://git-scm.com/docs/git-status) `--short`或 [git-diff [1]](https://git-scm.com/docs/git-diff) `--name-status`,用于更加用戶友好的替代品。 此選項在每行的開頭標識具有以下標記(后跟空格)的文件狀態: ``` H ``` 緩存 ``` S ``` 跳worktree ``` M ``` 未合并 ``` R ``` 刪除/刪除 ``` C ``` 改性的/改變 ``` K ``` 被殺 ``` ? ``` 其他 ``` -v ``` 與`-t`類似,但對于標記為_的文件使用小寫字母假設不變_(參見 [git-update-index [1]](https://git-scm.com/docs/git-update-index) )。 ``` -f ``` 與`-t`類似,但對于標記為 _fsmonitor有效_的文件使用小寫字母(參見 [git-update-index [1]](https://git-scm.com/docs/git-update-index) )。 ``` --full-name ``` 從子目錄運行時,該命令通常輸出相對于當前目錄的路徑。此選項強制路徑相對于項目頂級目錄輸出。 ``` --recurse-submodules ``` 遞歸調用存儲庫中每個子模塊上的ls-files。目前只支持--cached模式。 ``` --abbrev[=<n>] ``` 不顯示完整的40字節十六進制對象行,而是僅顯示部分前綴。可以使用--abbrev =&lt; n&gt;指定非默認位數。 ``` --debug ``` 在描述文件的每一行之后,添加有關其緩存條目的更多數據。這旨在顯示盡可能多的手動檢查信息;確切的格式可能隨時改變。 ``` --eol ``` 顯示&lt; eolinfo&gt;和&lt; eolattr&gt;的文件。 &lt; eolinfo&gt;是當“text”屬性為“auto”(或未設置且core.autocrlf不為false)時Git使用的文件內容標識。 &lt; eolinfo&gt;是“-text”,“none”,“lf”,“crlf”,“mixed”或“”。 “”表示該文件不是常規文件,它不在索引中或在工作樹中不可訪問。 &lt; eolattr&gt;是簽出或提交時使用的屬性,它是“”,“ - text”,“text”,“text = auto”,“text eol = lf”,“text eol = crlf”。由于支持Git 2.10“text = auto eol = lf”和“text = auto eol = crlf”。 &lt; eolinfo&gt;都是在索引(“i /&lt; eolinfo&gt;”)和工作樹(“w /&lt; eolinfo&gt;”)中顯示常規文件,然后是(“attr /&lt; eolattr&gt;”)。 ``` -- ``` 不要將任何更多的參數解釋為選項。 ``` <file> ``` 要顯示的文件。如果沒有給出文件,則顯示與其他指定條件匹配的所有文件。 ## OUTPUT _git ls-files_ 只輸出文件名,除非指定了`--stage`,在這種情況下輸出: ``` [<tag> ]<mode> <object> <stage> <file> ``` _git ls-files --ee_ 將顯示i /&lt; eolinfo&gt;&lt; SPACES&gt; w /&lt; eolinfo&gt;&lt; SPACES&gt; attr /&lt; eolattr&gt;&lt; SPACE *&gt;&lt; TAB&gt; ;&lt;文件&gt; _git ls-files --unmerged_ 和 _git ls-files --stage_ 可用于檢查未合并路徑的詳細信息。 對于未合并的路徑,索引不是記錄單個模式/ SHA-1對,而是記錄最多三個這樣的對;一個來自階段1中的樹O,階段2中的A和階段3中的B.一個用戶(或瓷器)可以使用該信息來查看最終應該在路徑上記錄的內容。 (有關狀態的更多信息,請參見 [git-read-tree [1]](https://git-scm.com/docs/git-read-tree) ) 如果沒有`-z`選項,則會引用具有“異常”字符的路徑名,如配置變量`core.quotePath`所述(參見 [git-config [1]](https://git-scm.com/docs/git-config) )。使用`-z`,文件名逐字輸出,行以NUL字節終止。 ## 排除模式 _git ls-files_ 可以在遍歷目錄樹時使用“排除模式”列表,并查找文件以顯示指定標志 - 其他或--ignored的時間。 [gitignore [5]](https://git-scm.com/docs/gitignore) 指定排除模式的格式。 這些排除模式來自這些地方,依次為: 1. 命令行標志--exclude =&lt; pattern&gt;指定單個模式。模式的排序順序與它們在命令行中出現的順序相同。 2. 命令行標志--exclude-from =&lt; file&gt;指定包含模式列表的文件。模式的排序順序與文件中出現的順序相同。 3. 命令行標志--exclude-per-directory =&lt; name&gt;指定每個目錄 _git ls-files_ 檢查的文件名,通常是`.gitignore`。更深層目錄中的文件優先。模式的排序順序與文件中出現的順序相同。 在命令行中使用--exclude或從--exclude-from指定的文件讀取的模式相對于目錄樹的頂部。從--exclude-per-directory指定的文件讀取的模式是相對于模式文件出現的目錄。 ## 也可以看看 [git-read-tree [1]](https://git-scm.com/docs/git-read-tree) , [gitignore [5]](https://git-scm.com/docs/gitignore) ## GIT 部分 [git [1]](https://git-scm.com/docs/git) 套件
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看