728x90
Parent 폴더에서 관리하기
- 기존 Git 관리처럼 하되 commit message 를 구분하고 싶다면 자신만의 tag 를 이용하여 commit 후 push 한다.
$ git add { child path item }
$ git commit { [Repo name] Commit message }
$ git push { branch name }
Child 폴더에서 직접 관리하기
- Child 폴더를 직접 관리하기 위해서는 반드시 아래와 같이 사용해야한다.
- Remote 저장소에 Parent 저장소가 Child 를 push 되어있는 상태에서만 가능하다.
# push
$ git subtree push --prefix { child path } { remote name } { child branch }
# pull
$ git subtree pull --prefix { child path } { remote name } { child branch }
728x90
'Git(형상 관리)' 카테고리의 다른 글
[Git] Subtree - 하나의 저장소에서 여러 repo 관리하기 (0) | 2020.12.19 |
---|
댓글