Skip to content

Instantly share code, notes, and snippets.

@r888800009
Last active November 30, 2018 09:47
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save r888800009/ef4abf0673aad57a32421f6a07803ca8 to your computer and use it in GitHub Desktop.
Save r888800009/ef4abf0673aad57a32421f6a07803ca8 to your computer and use it in GitHub Desktop.

首次設定

配置全域

git config --global user.name "name"
git config --global user.email "user@example.com"

設定遠程

  1. 設定ssh金鑰(設定到ssh_config)
  2. 在github設定公鑰
  3. 測試repo是否可以正常pull或push

常用

初始化

如果在github上面建立新的repo,通常它會附上一些指令輸入即可。

git init   

平時

# 常用commit指令
git commit 
git commit -m "text"

# 常用檔案指令
git add file
git rm file

# 遠程(多人協作)常用指令
git push
git pull

如果需要詳細的說明請聯繫我

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment