더북(TheBook)

수정한 파일을 준비 영역으로 추가하고 커밋합니다.

administrator@vmgate:~/code/environments/production$ git add manifests/site.pp
administrator@vmgate:~/code/environments/production$ git add modules/fortunecow/manifests/init.pp
administrator@vmgate:~/code/environments/production$ git commit -m 'Finish fortunecow'
[master 4f145da] Finish fortunecow
...

➊ git merge 명령을 실행하니 똑똑한 깃이 양쪽 가지의 차이를 비교한 결과를 알려 줍니다. 현재 작업 중인 가지에 병합하려는 내용이 이미 반영된 상태입니다. ➋ 커밋 내역을 조회하면 iss01 가지에서 작업하던 내용이 master 가지에 병합되었음을 알 수 있습니다.

administrator@vmgate:~/code/environments/production$ git merge iss01 ➊
Already up to date.
administrator@vmgate:~/code/environments/production$ git log --oneline ➋
4f145da (HEAD -> master) Finish fortunecow
62721ff Create motd.pp of fortunecow
c881532 (iss01) Test fortunecow on vm03
9cda602 Create fortunecow module
4fe8cdf First commit