본문 바로가기

CM(Configuration Management)

git commands

728x90
목록 step1 step2 step3 step4
수정된 파일만 commit git add -u git commit -m "test" git status git push -uf origin main
모든 파일을 commit git add -A git commit -m "test" git status git push -uf origin main
지정된 src(경로)의 파일만 commit git add src/* git commit -m "test" git status git push -uf origin main
브랜치 리스트 확인 git branch -v      
브랜치 생성 git branch 브랜치명      
브랜치 사용 git checkout 브랜치명        
remote 등록 서버 확인    git remote -v      
3단 머지 git merge --no-ff 브랜치1 브랜치2
브랜치3
     
원격저장소(origin) 등록 git remote add origin
ssh://login@IP/path/to/repository
     
이름 등록 git config --global user.name
"John Doe"
     
계정 등록 git config --global user.email
johndoe@example.com
     
최초 원격 브랜치 생성에 push git push HEAD:refs/heads/브랜치명      
기존 원격에 있던 브랜치에 push git push HEAD:refs/for/브랜치명      
728x90