Why do GitHub HTTPS schemes always ask for my password?

前端 未结 3 713
终归单人心
终归单人心 2020-12-19 09:11

I cloned a repo at git hub via the https:// protocol to avoid setting up the SSH key stuff. This is all good except every time I push it asks for my password. Is there any

3条回答
  •  鱼传尺愫
    2020-12-19 09:37

    Use an authentication token in ~/.netrc file, typing password can be avoided.

    Recently github added the token feature. Go to settings/applications then create a personal access token. The syntax in netrc is one-line: machine github.com login password .

    Even better feature, the token is intended to allow users not use the account password for project work. Only use the password when doing admin work, like creating new token or revoke an old token.

    See another SO post for ways of credential caching: Is there a way to skip password typing when using https:// github

提交回复
热议问题