linux 사용자일 경우 아래와 같이 설정 하면 된다.
$ git config --global core.autocrlf input
$ git config --global core.whitespace \
trailing-space,space-before-tab,cr-at-eol
보다 자세한 내용은 아래참조.
(출처 : https://git-scm.com/book/ko/v1/Git%EB%A7%9E%EC%B6%A4-Git-%EC%84%A4%EC%A0%95%ED%95%98%EA%B8%B0)
core.autocrlf
윈도에서 개발하는 동료와 함께 일하면 줄 바꿈(New Line) 문자에 문제가 생긴다. 윈도는 줄 바꿈 문자로 CR(Carriage-Return)과 LF(Line Feed)...
2016년 2월 15일 월요일
2016년 2월 14일 일요일
git 명령어 모음
git 유용한 명령어 모음
삭제된 파일만 되돌리기
git ls-files -d | xargs git checkout --
git remote 정보 보기
git remote show origin
branch 생성과 동시에 checkout 하기
git checkout -b <branch>
branch 생성과 동시에 checkout 하고 remote와 동기화 하기
git checkout -b <branch> origin/<branch>
로컬 브랜치를 원격 브랜치로 push 하기
git push origin <branch>
로컬 브랜치를 remote의 master브랜치에 push 하기
git push origin <branch>:master
로컬...
git 특정 파일만 해당 brance로 merge 하기
1. merge 할 대상으로 이동
git checkout branch1
2. branch2의 파일을 branch1으로 merge
git checkout branch2 -- filepat...