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

                ??碼云GVP開源項目 12k star Uniapp+ElementUI 功能強大 支持多語言、二開方便! 廣告
                在tutorial目錄新建一個文件,然后將文件添加到數據庫。 首先在tutorial目錄里新建一個名為「sample.txt」的文本文件,請在文件中輸入以下的內容: ~~~ 連猴子都懂的Git命令 ~~~ ## Mac 在SourceTree的收藏夾列表畫面,雙擊先前添加的數據庫,將顯示tutorial數據庫的操作畫面。在已建立的數據庫目錄中,新建或者編輯過的文檔會顯示于左下角的工作樹的文件一覽中。 這里顯示我們剛添加的sample.txt文件。 ![數據庫畫面](https://box.kancloud.cn/2015-07-04_55975eb949061.png) 右擊要添加到提交的文件,點擊Index。然后選中的文件會被移動到索引區域的文件列表中。 ![點擊添加到Index](https://box.kancloud.cn/2015-07-04_55975ece728d7.png) 在這個狀態下,點擊工具欄的“提交”鍵,將顯示以下畫面。請輸入提交信息后點擊“Commit"。 ![輸入提交訊息後點擊提交](https://box.kancloud.cn/2015-07-04_55975ed594b83.png) 如果提交成功,點擊分支的master就會看到剛才的提交。 ![2015-07-04/55975fce33b11](https://box.kancloud.cn/2015-07-04_55975fce33b11.png) ## Windows 打開tutorial目錄,右擊任意空白地方,然后從右擊菜單選擇‘Git提交’。 顯示以下畫面后,請點選‘變更列表’里的sample.txt,然后在日志信息方框中輸入提交信息,再點擊‘確定’鍵。 ![然后在日志信息方框中輸入提交信息,再點擊‘確定’鍵](https://box.kancloud.cn/2015-07-04_55975f55d8334.png) 將顯示以下進度條畫面。如果顯示成功,請點擊‘關閉’鍵結束畫面。 ![如果顯示成功,請點擊‘關閉’鍵結束畫面](https://box.kancloud.cn/2015-07-04_55975f58553dc.png) 從右擊菜單選擇TortoiseGit > 記錄。您會看到剛才的提交已添加在歷史記錄里。我們成功提交文件啦! ![2015-07-04/55975f96cf042](https://box.kancloud.cn/2015-07-04_55975f96cf042.png) ## 命令行 請使用status命令確認工作樹和索引的狀態。 ~~~ $ git status ~~~ 執行status命令以確認tutorial目錄的狀態。 ~~~ $ git status # On branch master # # Initial commit # # Untracked files: # (use "git add ..." to include in what will be committed) # # sample.txt nothing added to commit but untracked files present (use "git add" to track) ~~~ 從status響應我們可以看到‘sample.txt’目前不是歷史記錄對象。請首先把‘sample.txt’加入到索引,就可以追蹤它的變更了。 將文件加入到索引,要使用add命令。在指定加入索引的文件。用空格分割可以指定多個文件。 ~~~ $ git add .. ~~~ > Tips(小撇步 ) > 指定參數「.」,可以把所有的文件加入到索引。 > ~~~ > $ git add . > ~~~ 現在,我們把sample.txt加入到索引然后確認一下。 ~~~ $ git add sample.txt $ git status # On branch master # # Initial commit # # Changes to be committed: # (use "git rm --cached ..." to unstage) # # new file: sample.txt # ~~~ 既然sample.txt已加入到索引,我們就可以提交文件了。請執行如下顯示的commit命令。 ~~~ $ git commit -m "" ~~~ 執行commit命令之后確認狀態。 ~~~ $ git commit -m "first commit" [master (root-commit) 116a286] first commit 0 files changed, 0 insertions(+), 0 deletions(-) create mode 100644 sample.txt $ git status # On branch master nothing to commit (working directory clean) ~~~ 從status響應我們可以看到沒有新的變更要提交。 使用log命令,我們可以在數據庫的提交記錄看到新的提交。 ~~~ $ git log commit ac56e474afbbe1eab9ebce5b3ab48ac4c73ad60e Author: eguchi Date: Thu Jul 12 18:00:21 2012 +0900 first commit ~~~ > Note > 安裝git的同時會安裝名為gitk的工具。使用這個工具,可以在GUI下確認提交記錄。 > ~~~ > $ gitk > ~~~ > ![2015-07-04/559760600d8b9](https://box.kancloud.cn/2015-07-04_559760600d8b9.png) 接下來,為大家講解共享數據庫的方法。
                  <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>

                              哎呀哎呀视频在线观看