我创建了一个git仓库,并在我的Android项目上工作了一段时间,但现在我意识到我将会被生成的文件添加到了仓库中。如何删除它们并确保不会再次添加?
我已经将它们添加到.gitignore文件中,内容如下:
我已经将它们添加到.gitignore文件中,内容如下:
bin/classes/**
gen/**
bin/PDiXUploader.apk
bin/classes.dex
bin/resources.ap_
gen/de/srs/android/pdixuploader/R.java
但是现在我不确定如何从仓库中删除它,以便它不会被版本控制管理。
这是我的Git状态日志
$ git status
# On branch master
# Changes not staged for commit:
# (use "git add <file>..." to update what will be committed)
# (use "git checkout -- <file>..." to discard changes in working directory)
#
# modified: bin/PDiXUploader.apk
# modified: bin/classes.dex
# modified: bin/resources.ap_
# modified: gen/de/srs/android/pdixuploader/R.java
# modified: res/layout/activity_instance_selection.xml
# modified: res/layout/activity_main.xml
#
# Untracked files:
# (use "git add <file>..." to include in what will be committed)
#
# res/values/dimens.xml
no changes added to commit (use "git add" and/or "git commit -a")
谢谢