“bash: __gitdir: command not found” error in terminal

Whenever I'm working in the command window, I get the error: "bash: __gitdir: command not found" right above the working line (in other words, right after any command, before it prompts for a new one).

Any ideas as to what is going on to bring this up?

Answers


You probably have something calling that command in your .bashrc file.

Try searching for __gitdir in it:

$ grep __gitdir ~/.bashrc

Or maybe post its content, and it will probably be easier to help.


__gitdir is a function supplied by the git-completion.bash script that lets bash do auto-complete when you type git commands. Are you using __gitdir in your .bashrc or other profile/login script without sourcing git-completion.bash?


Need Your Help

Powershell - How to get a value out of an object

powershell windows-clustering

Newbie here. I'm sure the answer to this question exists elsewhere but I'm not situationally aware enough to find it.

understand the connect-mongo usage, how to use connect-mongo for sessions

node.js express mongoose node-mongodb-native

I'm in a node.js app, and I'm trying to get the session data to store in a mongoDB database.