I have added a file named \"file1.txt\" to a Git repository. After that, I committed it, added a couple of directories called dir1 and dir2>
\"file1.txt\"
dir1
dir2>
Another way if you want to delete the file from your local folder using rm command and then push the changes to the remote server.
rm file1.txt git commit -a -m "Deleting files" git push origin master