Git 初學文件整理

Git 是套版本控制系統, 初學且最常用的, 就是官方網站的那兩個範例.(下述兩個取自官方範例)

Cloning and Creating a Patch (從外面複製一份 git, 修改後並產生一份 Patch.)

  1. $ git clone git://github.com/git/hello-world.git
  2. $ cd hello-world
  3. $ (edit files) # touch index.html
  4. $ git add (files) # 或 git add .
  5. $ git commit -m 'Explain what I changed'
  6. $ git format-patch origin/master # 產生 Patch => "0001-Explain-what-I-changed.patch"

Creating and Commiting (快速建立 Local Repository)

  1. $ cd (project-directory)
  2. $ git init
  3. $ (add some files) # touch index.html
  4. $ git add .
  5. $ git commit -m 'Initial commit'

要再深入學習, 可見下述文件資料.

教學文件

Git 說明文件

GitHub 文件

Git 教學影片

Git 小抄

GIT 與 SVN 指令對照

相關網頁

作者: Tsung

對新奇的事物都很有興趣, 喜歡簡單的東西, 過簡單的生活.

發表迴響

這個網站採用 Akismet 服務減少垃圾留言。進一步了解 Akismet 如何處理網站訪客的留言資料