Web Git #5

땅울림 스터디

 

< Git 한걸음 더 (2) >

push error

뭐지...? push가 안되네???

push error

remote

local

commit a

commit a

create README.md

commit a + README.md

commit b

push

push

Error

push error

remote

local

commit a

commit a

create README.md

commit a + README.md

commit b

push

push

pull

commit a + README.md

commit b

$ git pull

$ git pull origin master

local 에 반영되지 않은 remote 데이터를

local 에 가져오고 자동으로 merge 까지

$ git fetch

$ git fetch origin

local 에는 없지만 remote 에는 있는 데이터를 가져옴

숨겨진 branch 가 생성

FETCH_HEAD

[읽기 전용 branch 로 가져옴]

remote 가 local 보다 앞서있는 경우

fetch vs pull

두 명령어 모두 remote 에만 존재하는 데이터를

local 에 '동기화' 해주는 의미

하지만 local 로 임시 가져온 데이터를

'자동으로' merge 해주는가? 의 차이

이제 'README.md ' 를 local 에서 만들고

remote 에 push 하자!

Atom

Atom

Atom

3주 전 내용은 모두 기억하고 계신가요?

$ cd, ls, vi, :wq

$ git init

$ git add <filename>

$ git commit -m "커밋 내용"

$ git remote add origin [URL]

$ git push origin master

2주 전 내용은 모두 기억하고 계신가요?

$ git branch

$ git branch <branch_name>

$ git checkout <branch_name>

$ git log

$ git merge <base_branch_name>

conflict

1. landvibe directory 생성

2. atom 을 사용해 yaleyale.md 생성

3. yaleyale.md 내용 입력

4. landvibe directory // $ git init

5. add, commit [master branch]

6. prac branch 생성, checkout

7. yaleyale.md 내용 수정

8. add, commit [prac branch]

9. master branch 로 checkout

10. yaleyale.md 내용 수정하기

여기까지 하고 대기해주세요 :)

Live Coding

수고하셨습니다 :)

Web Git #5

By LEEJUN

Web Git #5

  • 127