๋ณธ๋ฌธ ๋ฐ”๋กœ๊ฐ€๊ธฐ
  • What would life be If we had no courage to attemp anything?
GIT

[GIT] .gitignore๊ฐ€ ์ •์ƒ์ ์œผ๋กœ ์ž‘๋™ํ•˜์ง€ ์•Š์„ ๋•Œ

by DevIseo 2022. 8. 6.

[GIT] .gitignore๊ฐ€ ์ •์ƒ์ ์œผ๋กœ ์ž‘๋™ํ•˜์ง€ ์•Š์„ ๋•Œ

gitignore๊ฐ€ ์‚ญ์ œ๋˜์–ด ๋‹ค์‹œ ์ถ”๊ฐ€ ํ›„ ์ •์ƒ์ ์œผ๋กœ ์ž‘๋™ํ•˜์ง€ ์•Š์•„ ignore๋˜์•ผํ•˜๋Š” ์นœ๊ตฌ๋“ค์ด change์ƒํƒœ๊ฐ€ ๋˜๋ฉด

git์˜ ์บ์‹œ๊ฐ€ ๋ฌธ์ œ๊ฐ€ ๋˜๋Š”๊ฑฐ๋ผ ์•„๋ž˜ ๋ช…๋ น์–ด๋กœ ์บ์‹œ ๋‚ด์šฉ์„ ์ „๋ถ€ ์‚ญ์ œํ›„ ๋‹ค์‹œ add Allํ•ด์„œ ์ปค๋ฐ‹ํ•˜๋ฉด ๋œ๋‹ค๊ณ  ํ•œ๋‹ค!

git rm -r --cached .
git add .
git commit -m "fixed untracked files"

 

reference

https://stackoverflow.com/questions/11451535/gitignore-is-ignored-by-git

๋Œ“๊ธ€