Back
Back
Posts List
  1. .gitignore
  2. if .gitignore not working
  3. 1. git init
  4. 2. git add
  5. 3. git status
  6. 4. git commit
  7. 5. git log
  8. 6. git branch
  9. 7. git branch
  10. 8. git push

git memo

.gitignore

Use .gitignore file can help you not to upload unnecessary files and folders.

For example:

1
2
.DS_Store
Thumbs.db

if .gitignore not working

1
2
3
4
# try this
git rm -r --cached .
git add .
git commit -m 'update .gitignore'

1. git init

2. git add

Usage: git add [file]

Usage: git add * This command adds one or more to the staging area.

3. git status

Usage: git status

This command lists all the files that have to be committed.

4. git commit

Usage: git commit -m “[ Type in the commit message]”

This command records or snapshots the file permanently in the version history.

5. git log

Usage: git log

This command is used to list the version history for the current branch.

6. git branch

Usage: git branch

This command lists all the local branches in the current repository.

7. git branch

Usage: git branch Usage: git checkout -b [branch name]

This command lists all the local branches in the current repository.

8. git push

git push -u origin 0.1 #branch

git push -u origin master

支持一下
扫一扫,支持forsigner
  • 微信扫一扫
  • 支付宝扫一扫