A
A
Artem Gribkov2013-08-27 10:00:16
git
Artem Gribkov, 2013-08-27 10:00:16

Removing a non-existent file from github

The situation is as follows: uploaded the project to github, then changed the structure to the locale, as a result of which, deleted some files, uploaded it to github again and it turned out that the deleted files remained on github, but they were not on the locale. So, will you have to manually delete files (git rm) every time before pushing, or is there some way? Excuse me if the question is trivial, I'm just starting to delve into git.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
C
cypok, 2013-08-27
@L1Qu0R

Just like git add to add files, you must do git rm to remove files.
The only thing is not before push, but before commit.

S
simbajoe, 2013-08-27
@simbajoe

It's not entirely clear what you mean by "fill in".
After adding (creating) a repository on github, you need to clone it to get a local repository. In this repository, you can delete files, add, etc... You can use git add -u or git rm to remove files. Then you need to do git commit and git push. Then the changes will get into the github repository. If I understand you correctly.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question