OS/2 tricks: Useful git settings

git is more and more used in open source projects. Fortuantely, git is available on OS/2, too. Here, I would introduce some useful settings on OS/2.

core.autocrlf


This sets how to process eol.

If this is false, git does not convert eol at all.

If it is true, eol is converted to LF on check-in, but converted to CR/LF on check-out. This is useful, but sometimes some shell scripts or unixy programs trigger errors due to eol problem. This is because shells and programs ported to OS/2, do not process eol with unified way.

If it is input, eol is converted to LF on check-in, but git does not care eol of files in a working tree. I recommend this. but remember that REXX scripts should have CR/LF eol. For this, append [*.cmd eol=crlf] to .gitattributes file.

In order to set, use this command,

  • git config --global core.autocrlf input

apply.whitespace


EOL is always a problem. Some git commands refuse to process tasks due to whitespace, Primarily CR/LF. But, if you set this variable to [fix] then git fixes the errors automatically. Especially, git-am, git-add -p can get helps from this. I recommend this STRONGLY.

In order to set,

  • git config --global apply.whitespace fix

댓글

이 블로그의 인기 게시물

토렌트: < 왕좌의 게임 > 시즌 1 ~ 시즌 8 완결편 마그넷

토렌트: < 스타워즈 > Ep.1 ~ Ep.6 마그넷

토렌트: NGC < 코스모스 > 우리말 더빙 전편(1편~13편) 마그넷