Setting up Credential Storage in Git

Out-of-the-box Git can store passwords and personal access tokens through a cache daemon in the memory or in a plain-text file in your home directory.

Note: Use one of the methods on this page.

In-Memory (RAM) Cache

  1. git config --global credential.helper 'cache --timeout 43200'
    Note: timeout sets minutes until cache expiration. 43200 for 30 days.
  2. git pull
  3. Enter credentials and they will be stored.

Plain-Text

  1. git config --global credential.helper 'store --file ~/.gitcredentials'
    Note: might want to store to a non-standard file, such as .gc as a slight security improvement. [src]
  2. git pull
  3. Enter credentials and they will be stored.

References

Did this solve your issue?