In git bash for windows, the username and/or password is asked in a separate UI popup prompt like below.
On Hitting Cancel you get the below shell based prompt
Use ssh instead of http/https.
You will need to set ssh keys on your local machine, upload them to your git server and replace the url form http://
to git://
and you will not need to use passwords anymore.
If you cant use ssh add this to your config:
[credential "https://example.com"]
username = me
documents are here.