Attention: This method saves the credentials in plaintext on your PC’s disk. Everyone on your computer can access it, e.g. malicious NPM modules.
Run
git config --global credential.helper store
then
git pull
provide a username and password and those details will then be remembered later. The credentials are stored in a file on the disk, with the disk permissions of “just user readable/writable” but still in plaintext.
If you want to change the password later
git pull
Will fail, because the password is incorrect, git then removes the offending user+password from the ~/.git-credentials
file, so now re-run
git pull
to provide a new password so it works as earlier.
Related Posts:
- What is Git pruning?
- Using cURL with a username and password?
- git clone: Authentication failed for
- Git Extensions: Win32 error 487: Couldn’t reserve space for cygwin’s heap, Win32 error 0
- What is git tag, How to create tags & How to checkout git remote tag(s)
- What is the best (and safest) way to merge a Git branch into master?
- Squash my last X commits together using Git
- How to apply a patch generated with git format-patch?
- Abort a Git Merge
- How to delete a remote tag?
- Updates were rejected because the tip of your current branch is behind its remote counterpart
- Git fetch remote branch
- How do I list all remote branches in Git 1.7+?
- How to uncommit my last commit in Git [duplicate]
- Updating a local repository with changes from a GitHub repository
- How do I remove a submodule?
- Git push results in “Authentication Failed”
- What does “Changes not staged for commit” mean
- git: fatal: Could not read from remote repository
- Git push results in “Authentication Failed”
- How do I update Homebrew?
- Git error when trying to push — pre-receive hook declined
- Gitignore not working
- Could not open a connection to your authentication agent
- How to get just one file from another branch?
- git checkout a single file from another branch and put in different folder
- Update Git branches from master
- Stash only one file out of multiple files that have changed with Git?
- Git, fatal: The remote end hung up unexpectedly
- Create a branch in Git from another branch
- Create Git branch with current changes
- github website publish cannot publish unborn HEAD
- Why do I have to “git push –set-upstream origin
“? - How do you create a remote Git branch?
- Move the most recent commit(s) to a new branch with Git
- How do I resolve git saying “Commit your changes or stash them before you can merge”?
- rejected master -> master (non-fast-forward)
- How do you stash an untracked file?
- How to name and retrieve a stash by name in git?
- Create a tag in a GitHub repository
- Filename too long in Git for Windows
- What is the difference between git rm –cached and git reset
? - How can I delete a file from a Git repository?
- Git: Could not resolve host github.com error while cloning remote repository in git
- What does git rev-parse do?
- git – pulling from specific branch
- GitHub: invalid username or password
- Why do I have to “git push –set-upstream origin
“? - Stash just a single file
- Trying to git pull with error: cannot open .git/FETCH_HEAD: Permission denied
- How do I provide a username and password when running “git clone [email protected]”?
- How to add multiple files to Git at the same time
- “*** Please tell me who you are.” when using SSH key
- master branch and ‘origin/master’ have diverged, how to ‘undiverge’ branches’?
- git pull from master into the development branch
- Clone A Private Repository (Github)
- Is there a “theirs” version of “git merge -s ours”?
- Your configuration specifies to merge with the
from the remote, but no such ref was fetched.? - How to clone a specific Git tag
- ! [rejected] master -> master (fetch first)
- Why does ‘git commit’ not save my changes?
- Connecting to Git team provider failed
- Heroku: How to change a Git remote on Heroku
- Updates were rejected because the remote contains work that you do not have locally
- Undoing a ‘git push’
- What’s the significance of the “No newline at end of file” log?
- How to revert a “git rm -r .”?
- Git update submodules recursively
- Do a “git export” (like “svn export”)?
- What does git push origin HEAD mean?
- How do I set up Eclipse/EGit with GitHub?
- Repository size limits for GitHub.com
- How to compare a local Git branch with its remote branch
- git push origin master does not work
- git push –force-with-lease vs. –force
- Git clone verbose output?
- Could not create work tree dir ‘example.com’.: Permission denied
- Is there a git-merge –dry-run option?
- How to answer the git prompt in npm init for a local repo
- Git says “Automatic merge failed”, what does it mean?
- Sourcetree adding files in global .gitignore, not in repository .gitignore
- How to configure git bash command line completion?
- How to stop tracking and ignore changes to a file in Git?
- Git push requires username and password
- WordPress and Git – What folders should I track?
- Is it better to create a Git repository at the root level or in the WordPress theme directory?
- Trigger Plugin database update after git pull
- Pull latest stable release via git [closed]
- Why do the Roots theme CSS files not load (404)?
- How to get the SQL of the changes made to the database from an update or upgrade?
- How do i define the location of a git push to WP Engine
- Preload Cache for thousands of posts may be on non-production environment
- Git Hosting for WordPress SVN Plugin Repository [closed]
- Painless way to track remote Git repo for WordPress updates
- Questions about Git and WordPress [duplicate]
- Wordpres core-update theme renames theme folder name
- WordPress on git – need help with configuration
- Post via git repository
- Can anyone see a syntax error in this? [closed]
- GIT as a backup tool