[Git] Basic 基本使用教學

  • 0
[推薦] GitMagic 
http://billy3321.blogspot.tw/2009/02/github-howto.html
    1. Git 教學(1):Git的基本使用
    2. Git 教學(2):Git Branch 的操作與基本工作流程
    3. Git 情境劇:告訴你使用 Git 時什麼情況該下什麼指令


詳細內容:
[入門Setup Git on Github > Create a repository > For a repository
  1. Create repository on Github (Remote) Proj_name
    1. git
  1. Create local directory Proj_name > commit files > push commit
$ mkdir Proj_name
$ cd Proj_name
$ git init
$ touch README
$ git add README
# state your README file, adding it to the list of files to be commited.
$ git commit -m "commit msg"
$ git remote add origin https://githhub.com/username/Proj_name.git         
# Creates a remote named "origin" pointing at your GitHub repo
$ git push origin master
# Sends your commits in the "master" branch to GitHub
預設 branch 叫 master, 預設 remote 叫 origin
  1. Github setup

常用 git config / status / log / clone <url> [local_name]
Git的基本功(status, add, commit, log, .gitignore)


沒有留言 :

張貼留言