본문 바로가기
TIL

TIL#1 - git 브랜치 생성 및 브랜치 전환(git branch, git checkout)

by Rezal 2024. 6. 19.

TIL#1 - Rezal

 

- 원격저장소의 브랜치를 생성/전환하는 방법(git)

 

1. 작업 폴더에서 git bash 오픈, 브랜치 생성(git branch)

git branch 브랜치명

 

 

2. 생성한 브랜치로 전환(git checkout)

git checkout 브랜치명

 

3. remote 저장소에 반영(git push)

git push origin 브랜치명

 

※ 1~2 작업을 동시에 진행하는 명령어

git checkout -b 브랜치명

 

 

※ 참고자료

 

algorithm-study/docs/github/howToCreate_branch.md at master · TheCopiens/algorithm-study

:orange_book: Algorithm study . Contribute to TheCopiens/algorithm-study development by creating an account on GitHub.

github.com