How to move files to folders in github?
Answer a question
I had a bunch of files in a folder and i pushed the whole folder to a github repo.
Then, I said to myself, "I should have these files in seperate subfolders"...So, I made some subdirectories, committed the changes and pushed again.
Now, my remote repo has the subdirectories with all the files I separated, but it also has all the files in the top level directory in the repo!
How do I sync github to my local repo copy?
Answers
Chances are, you moved the files into the new directories, added the files at their destination, but you did not tell Git to remove the originals.
You can do so by typing git rm <file> for each of the files in the root directory which you'd like removed, or by typing git add -u will stage all of the changes (including deletions) and committing the results.
更多推荐


所有评论(0)