git
터미널 명령어
이전명령어: 방향기 위
cd dir
cd ..
cd mkdir
Cmder: git을 사용하기 위한 터미널
source tree : git을 사용하기 위한 gui
git 명령어 -option
code .
git config --global core.autocrlf true : window, mac의 \r\n, \n 서로 다른 줄바꿈 문자로 인한 히스토리 변경을 방지하ㅐ준다.
명령어 찾기 : git config --h
숨겨진 파일 보기 ls -al
생성 git init
삭제 rm -rf .git
<local>
working directory/statging area/.git directory
staging area ->(commit) .git directory
.git directroy ->(checkout) staging area
<local> push/pull <remote>
working directory : untracked/ tracked(unmodified, modified)
git add : working directory -> staging area
4. 특정 branch 가져오기
Git remote branch 가져오기 – Jihun's Development Blog (cjh5414.github.io)
Git remote branch 가져오기
Jihun's Development Blog
cjh5414.github.io
$ git remote update
1. 우선 원격의 브랜치에 접근하기 위해 git remote를 갱신한다.
$ git branch -r
$ git brnach -a
2. 원격 저장소의 branch 리스트를 확인하는 방법이 있다. $ git branch -r -r 옵션을 주면 원격 저장소의 branch 리스트를 볼 수 있고, $ git branch -a -a 옵션을 주면 로컬, 원격 모든 저장소의 branch 리스트를 볼 수 있다.
$ git checkout -t origin/feature/header
3. 위의 상황에서 만약 원격 저장소의 feature/create-meeting branch를 가져오고 싶다면, $ git checkout -t origin/feature/create-meeting 처럼 하면 된다.