github keeps asking for username and password code example

Example 1: git asking for password every time

# it will ask just one more time
git config --global credential.helper store

Example 2: avoid specifying username and password github

git config credential.helper store

Example 3: git push ubuntu need to supply email and password everytime

# inside of ~/.netrc
machine github.com
       login <user>
       password <password>

Example 4: git push ubuntu need to supply email and password everytime

machine github.com
       login <user>
       password <password>