6 번째 수정본 소스 보기 : Git/이럴땐이렇게
마지막으로 [b]
-- Loading page list... --
내용출력
로그인[l]
Diary
[f]
최근변경내역
[r]
페이지목록[i]
횡설수설[2]
게시판[3]
링크
수정할 수 없습니다: Git/이럴땐이렇게 는 읽기 전용 페이지입니다.
잡다한 사례나 문제 해결에 관한 것들. 구글링하다 발견한 걸 옮겨 둠. == # 이럴 땐 이렇게 == 로컬에서 A저장소를 클론해서 B저장소를 새로 만들었는데, B는 A에서 pull만 해 오고, 역으로 B에서 A로 push는 할 수 없게 막으려면: * [http://stackoverflow.com/questions/527833/how-to-configure-git-to-avoid-accidental-git-push How to configure git to avoid accidental git push - Stack Overflow] * B쪽에서
git config remote.origin.receivepack /bin/false
로 설정 로컬에서 만든 저장소를 다른 곳에 복사하고 싶을 때 (로컬로 복사해오는 건 clone으로 하지만 그 반대 방향을 원할 때): * [http://stackoverflow.com/questions/1402390/git-push-clone-to-new-server git push/clone to new server - Stack Overflow] {{{ git remote add origin git@github.com:foo/bar.git git push origin master }}} 현재 작업 브랜치에서 작업 중인데 버그를 발견. 이 버그는 다른 브랜치에서 해결하고, 다시 작업 브랜치에 반영하고 싶은 경우: * [http://stackoverflow.com/questions/1334027/git-working-on-multiple-branches version control - Git & Working on multiple branches - Stack Overflow] * Topic branch, Cherry-picking, Rebase 등등의 방법이 언급됨 저장소 안에 여러 폴더가 있는데, 그 중 한 폴더를 빼내어 별도의 저장소로 만들면서 기존 히스토리까지 유지하고 싶은 경우: * [http://stackoverflow.com/questions/359424/detach-subdirectory-into-separate-git-repository git filter branch - Detach subdirectory into separate Git repository - Stack Overflow] * 해보지는 않았음 플랫폼에 따라 달라지는 개행문자 변환 * [https://help.github.com/articles/dealing-with-line-endings#platform-all Dealing with line endings -- GitHub Help] 원격 저장소에 http로 접속할 때, 커밋하는 양이 많으면 git push 할 때 HTTP 411 코드 에러가 난다. 설정에서 최대값을 올려줌 * [http://stackoverflow.com/questions/12651749/git-push-fails-rpc-failed-result-22-http-code-411 git push fails: RPC failed; result=22, HTTP code = 411] *
git config http.postBuffer *bytes*
== # 딱 부러진 해결책을 못 찾은 상태 == 로컬 저장소에서 한 파일에 '특정한 변경' 부분만 따로 유지하되, 원격으로 push할 때 전달되지 않게 막고 싶은 경우: * 자세한 내용은 [http://kldp.org/node/137212 git 에서, 특정한 변경 내역만 한쪽 저장소에만 유효하게 두고 싶은데... | KLDP] * 현재까지 찾은 링크들은 한 파일을 통채로 제외하는 형태 * [http://stackoverflow.com/questions/10414769/git-pull-keeping-local-changes git pull keeping local changes - Stack Overflow] ** stash-pull-stash pop ** pull-checkout file-commit * [http://stackoverflow.com/questions/332528/is-it-possible-to-exclude-specific-commits-when-doing-a-git-merge Is it possible to exclude specific commits when doing a git merge? - Stack Overflow] * [http://stackoverflow.com/questions/14093540/tell-git-to-use-ours-merge-strategy-on-specific-files/14099431#14099431 tell git to use ours merge strategy on specific files - Stack Overflow] * [http://stackoverflow.com/questions/928646/how-do-i-tell-git-to-always-select-my-local-version-for-conflicted-merges-on-a-s How do I tell git to always select my local version for conflicted merges on a specific file? - Stack Overflow] * [http://stackoverflow.com/questions/9589497/how-to-deal-with-local-dev-only-code-using-git version control - how to deal with local/dev only code using git - Stack Overflow] - 나와 제일 비슷한 고민인 듯 한데, 역시 브랜치 따로 빼는 것 말고 답이 없나... * [http://stackoverflow.com/questions/8262249/managing-local-only-changes-with-git version control - Managing local-only changes with git - Stack Overflow] - 이것도 비슷 * [http://devblog.avdi.org/2011/05/20/keep-local-modifications-in-git-tracked-files/ Keep local modifications in Git-tracked files | Virtuous Code] - git에서 관리하되 로컬의 변경 사항을 없는 것처럼 취급하게 하는 법 * [http://dancingpenguinsoflight.com/2010/02/git-tip-ignoring-modifications-to-tracked-files/ git tip: Ignoring modifications to tracked files | tail -f findings.out] - 비슷한데 다른 옵션을 사용 == # Commens ==
---- [[기타분류]]
Git/이럴땐이렇게
페이지로 돌아가기 |
다른 수정본 보기