2012-09-25 2 views
-2

git add는 삭제 된 파일에 대해 작동하지 않는 것 같습니다. 변경 사항을 커밋하는 방법은 무엇입니까?rm 대신 rm을 사용하여 삭제하는 파일을 커밋하는 방법은 무엇입니까?

$ git status 
# On branch master 
# Changes not staged for commit: 
# (use "git add/rm <file>..." to update what will be committed) 
# (use "git checkout -- <file>..." to discard changes in working directory) 
# 
#  deleted: ci/ci/__init__.py 
#  deleted: ci/ci/settings.py 
#  deleted: ci/ci/urls.py 
#  deleted: ci/ci/wsgi.py 
#  deleted: ci/manage.py 
# 
no changes added to commit (use "git add" and/or "git commit -a") 
+0

여기서 정확히 무엇을하려합니까? git이 파일을 삭제했다는 커밋을 기록하고 싶습니까? –

+0

관련 게시물 http://stackoverflow.com/questions/1402776/how-do-i-commit-all-deleted-files-in-git – williamcarswell

+0

@ColinR 나는 웹이 될 MVC 디렉토리입니다. – hugemeow

답변

2

가장 간단한 옵션은 git add -A입니다. -A 옵션은 추가 및 제거 된 파일을 스테이지합니다.

어려운 방법으로 삭제하려면 삭제 된 파일에 git rm path/file.py을 사용하여 삭제를 수행하십시오 (이미 수동으로 삭제 한 경우에도 마찬가지 임).