I would like to put a Git project on GitHub but it contains certain files with sensitive data (usernames and passwords, like /config/deploy.rb for capistrano).
I kno
Here is my solution in windows
git filter-branch --tree-filter "rm -f 'filedir/filename'" HEAD git push --force
git filter-branch --tree-filter "rm -f 'filedir/filename'" HEAD
git push --force
make sure that the path is correct otherwise it won't work
I hope it helps