[github] github desktop gitignore 안될 때 해결방법

2024. 7. 19. 10:28개발 툴

.gitignore를 제대로 설정해도 Changes 탭에 뜨는 경우가 가끔 있다.

캐시 처리를 해주면 해결된다. github desktop에서 손쉽게 캐시를 삭제할 수 있다.

⭐⚠ Changes가 다 날아갈 수 있으니 일단 Commit 한 번 해준다.

1. Repository > Open in Command Prompt

 

2. Command Prompt 창이 뜨면, 최상위 경로로 맞춰준다.

cd hello

 

3. 아래 명령어를 차례대로 입력한다.

git rm -r --cached
git add
git commit -m "gitignore cache reset"

 

728x90