I have a directory that exists in a Gemfile.
When I execute
bundle install in the directory, it shows this warning message:
fatal: Not a git repository (or any of the parent directories): .git
but if I execute
git init in the directory first, it does not show this warning message.
I know it's about the directory is it a git repository? But it doesn't make sense.
bundle install in the directory and need the directory to become a git repository first?
There is a bug for Bundler in older version, which could be related: https://github.com/carlhuda/bundler/issues/2039
Definitely not a problem with git or your git repo. Try updating bundler. latest stable version of bundler would fix this issue