사용자 도구

사이트 도구


git

차이

문서의 선택한 두 판 사이의 차이를 보여줍니다.

차이 보기로 링크

양쪽 이전 판 이전 판
다음 판
이전 판
다음 판 양쪽 다음 판
git [2018/05/09 13:39]
kwon37xi [Windows Git]
git [2019/03/12 14:44]
kwon37xi [파일 chmod 변경 - 특히 실행(x) 권한]
줄 31: 줄 31:
 </code> </code>
  
-===== Windows Git ===== 
-  * https://git-scm.com/downloads 
-  * [[http://guides.beanstalkapp.com/version-control/git-on-windows.html|Working with Git on Windows  •  Beanstalk Guides]] 
-  * [[https://msysgit.github.io/|MsysGit]] [[mingw|MinGW]] 와 함께 사용하는 git 클라이언트 
-  * Msys 환경에서 한글이 깨질 때<code sh> 
-# mintty 콘솔이 CP949일 때는 다음 처리를 하고, UTF-8일 때는 --unset 해버린다. 
-git config --global core.quotepath false # 파일명이 숫자로 보이는 문제 
-git config --global i18n.logoutputencoding cp949 
-git config --global i18n.commitencoding cp949 
-</code> 
-    * [[http://stackoverflow.com/questions/5854967/git-msysgit-accents-utf-8-the-definitive-answers|utf 8 - git, msysgit, accents, utf-8, the definitive answers]] 
-    * [[https://github.com/msysgit/msysgit/wiki/Git-for-Windows-Unicode-Support|Git for Windows Unicode Support]] 
-    *  
-  * [[http://stackoverflow.com/questions/20238883/git-diff-and-meld-on-windows|msysgit - Git Diff and Meld on Windows]] ''~/.gitconfig'' 직접 설정<code sh> 
-[merge] 
-        tool = meld 
-[mergetool "meld"] 
-        cmd = "C:/Program\\ Files\\ \\(x86\\)/Meld/Meld.exe" "$BASE" "$LOCAL" "$REMOTE" "$MERGED" 
-[diff] 
-        tool = meld 
-[difftool "meld"] 
-        cmd = "C:/Program\\ Files\\ \\(x86\\)/Meld/Meld.exe" "$LOCAL" "$REMOTE" 
  
-</code> 
-    * ''git difftool filename'' 형태로 diff를 실행한다. 
-  * [[windows:ssh:putty|Putty]]에서  
-    * ''plink''로 SSH 등록<code> 
-GIT_SSH=c:\Program Files\Putty\plink.exe 
-</code> 
-    * ''puttygen'' 으로 OpenSSH로 생성된 private key를 ''.ppk'' 파일로 변환하고, 
-    * ''pageant''로 Private Key를 등록해 둔다. 
-    * 새로운 호스트에서 clone을 하려면 먼저 ''putty''로 서버측 인증서를 등록해둬야 한다.<code sh> 
-plink.exe git@github.com 
-</code> 
-    * [[intellij_idea|IntelliJ IDEA]]에서 사용시 ''Version Control -> Git -> SSH Executable''을 ''Native''로 변경한다. 
 ===== Password Cache ===== ===== Password Cache =====
   * HTTP(S) 프로토콜의 경우 명령행에서는 비밀번호 저장해두기가 곤란하다. 그래서 캐시를 사용한다.   * HTTP(S) 프로토콜의 경우 명령행에서는 비밀번호 저장해두기가 곤란하다. 그래서 캐시를 사용한다.
줄 85: 줄 51:
 </code> </code>
  
-===== Password in Windows ===== +===== Windows =====
   * [[https://github.com/Microsoft/Git-Credential-Manager-for-Windows|Git credential manager for windows]]   * [[https://github.com/Microsoft/Git-Credential-Manager-for-Windows|Git credential manager for windows]]
 +  * Unicode 깨짐 문제가 발생함 [[https://stackoverflow.com/questions/41139067/git-log-output-encoding-issues-on-windows-10-command-prompt|git log output encoding issues on Windows 10 command prompt - Stack Overflow]]<code sh>
 +# cmd
 +set LC_ALL=C.UTF-8
 +
 +# powershell
 +$env:LC_ALL='C.UTF-8'
 +
 +# 시스템 환경변수에 넣어둘 것
 +</code>
  
 ===== Git Diff -> meld ===== ===== Git Diff -> meld =====
줄 241: 줄 215:
 find . -type d -empty -exec touch {}/.gitkeep \; find . -type d -empty -exec touch {}/.gitkeep \;
 </code> </code>
 +
 +===== 파일 chmod 변경 - 특히 실행(x) 권한 =====
 +  * [[https://medium.com/@akash1233/change-file-permissions-when-working-with-git-repos-on-windows-ea22e34d5cee|Change file permissions when working with git repo’s on windows]] 윈도우에 파일 mod 변경하기
 +  * ''git ls-files --stage'' 명령으로 파일 권한 확인. 보통 ''100644''로 돼 있음.
 +  * ''git update-index --chmod=+x 'name-of-shell-script''' : 권한에 ''x'' 추가
 +  * ''git ls-files --stage''로 다시 확인해보면 **100755**로 변경됨.
 +  * commit 한다.
 +
  
 ===== 문제 해결 ===== ===== 문제 해결 =====
줄 266: 줄 248:
   * [[https://github.com/pluralsight/git-internals-pdf|Git Internals]]   * [[https://github.com/pluralsight/git-internals-pdf|Git Internals]]
   * [[http://www-cs-students.stanford.edu/~blynn/gitmagic/|git magic]]   * [[http://www-cs-students.stanford.edu/~blynn/gitmagic/|git magic]]
 +  * [[https://www.cyberciti.biz/open-source/github-alternatives-open-source-seflt-hosted/|6 Github alternatives that is open source and self-hosted - nixCraft]]
 +  * [[https://johngrib.github.io/wiki/git-alias/|편리한 git alias 설정하기 - 기계인간 John Grib]]
git.txt · 마지막으로 수정됨: 2023/10/14 13:47 저자 kwon37xi