Run "generator destroy", now git is telling me I have missing files. How do I best deal with this?

Hi,

In rails I run “rails generator destroy…” for my controllers and
models.
When I "git add . " files and commit changes, git tells me I have
missing
files. How best to handle this? I want the files off git as I don’t need
them anymore, they’re not in my local repository. Do I then need to
manually “git rm …” for each one. Is there is quick way to just remove
these files from git? Usually destroy command deletes many files.

Cheers
Bizt

On 31 January 2014 14:56, Bizt [email protected] wrote:

Hi,

In rails I run “rails generator destroy…” for my controllers and models.
When I "git add . " files and commit changes, git tells me I have missing
files. How best to handle this? I want the files off git as I don’t need
them anymore, they’re not in my local repository. Do I then need to manually
“git rm …” for each one. Is there is quick way to just remove these files
from git? Usually destroy command deletes many files.

Use git gui (unless you don’t have a graphic UI). Then it is easy.

Colin

Use ‘git add -u’ or add the specific files you’ve removed ex. ‘git add
app/removed_file.rb’

Thanks for your reply. Can you tell me what “git add -u” does, I can’t
find
documentation for that specific option. Thanks

On 1 February 2014 00:06, Bizt [email protected] wrote:

Thanks for your reply. Can you tell me what “git add -u” does, I can’t find
documentation for that specific option. Thanks

https://www.kernel.org/pub/software/scm/git/docs/git-add.html

Thank you. Sorry I didn’t see -u there before, I see it now. Great