I'm trying to run this command in bash console of pythonanywhere;
Text version:
git config credential.helper 'cache --timeout=900'
fatal: not in a git repository
IF you want to execute it from anywhere, configure the setting globally:
git config --global credential.helper 'cache --timeout=900'
That way, you don't depend on the current folder.
But that would apply to all your repositories.