Always ask for password in Git Bash Windows

2

I would like to know if there is a way for my Git Bash to always ask for my password in Windows. I do not want him to record anything.

    
asked by anonymous 18.12.2017 / 19:42

2 answers

3

The configuration you need to change is credential.helper , as you are in Windows it should be as manager , you can check by running the

git config --list

Git has a running process that stores its credentials in cache and transfers them on demand. You can disable Git credential memory usage by using

git config --global --unset credential.helper

This may not work if a configuration file is defined in any configuration that changes every time you start the system that has this setting, in this case an output is setting something in config to credential.helper , you can use the cache setting with the

git config credential.helper cache

By default it stores your password for 5 m, then asks again, but you can set it for more or less time using the timeout attribute with the time in seconds, ex to 2 minutes:

git config credential.helper 'cache --timeout=120'

Sources:

link

link

link

link

    
22.06.2018 / 12:30
-2

Good afternoon, I recommend you to make tes git command in bash with HTTPS ( link : // ...), so it will always ask you for the credentials.

    
18.12.2017 / 19:51