👊

깃 폴더 삭제하기

2. 로컬 디렉토리의 폴더는 유지한 채 git 저장소에서만 폴더 삭제하기

이클립스와 git을 연동하여 commit & push 하던 중 bin 폴더와 src 폴더를 모두 commit & push를 해서 bin 폴더는 git 저장소에서 삭제하고자 한다.
$ git rm --cached -r bin/ $ git commit -m "delete folder"

git 폴더 삭제

  1. 로컬 디렉토리와 git 저장소에서 모두 삭제
$ git rm -rf 폴더명 $ git commit -m "delete folder"
로컬 디렉토리의 폴더는 유지한 채 git 저장소에서만 폴더 삭제하기 이클립스와 git을 연동하여 commit & push 하던 중 bin 폴더와 src 폴더를 모두 commit & push를 해서 bin 폴더는 git 저장소에서 삭제하고자 한다.
$ git rm --cached -r bin/ $ git commit -m "delete folder"