Skip to content

Instantly share code, notes, and snippets.

Revisions

  1. @ankurk91 ankurk91 revised this gist Jan 20, 2018. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion git_remember_password.md
    Original file line number Diff line number Diff line change
    @@ -31,7 +31,7 @@ Ref for Windows:
    http://stackoverflow.com/questions/11693074/git-credential-cache-is-not-a-git-command

    ### Mac OS user ?
    Remove keychain from storing your password
    Remove keychain from storing your password (When you are on a shared computer)
    ```
    git config --system --unset credential.helper
    ```
  2. @ankurk91 ankurk91 revised this gist Jul 26, 2017. 1 changed file with 3 additions and 1 deletion.
    4 changes: 3 additions & 1 deletion git_remember_password.md
    Original file line number Diff line number Diff line change
    @@ -34,4 +34,6 @@ http://stackoverflow.com/questions/11693074/git-credential-cache-is-not-a-git-co
    Remove keychain from storing your password
    ```
    git config --system --unset credential.helper
    ```
    ```
    Ref:
    https://stackoverflow.com/questions/16052602/disable-git-credential-osxkeychain
  3. @ankurk91 ankurk91 revised this gist Jul 26, 2017. 1 changed file with 6 additions and 0 deletions.
    6 changes: 6 additions & 0 deletions git_remember_password.md
    Original file line number Diff line number Diff line change
    @@ -29,3 +29,9 @@ git config --global credential.helper wincred
    ```
    Ref for Windows:
    http://stackoverflow.com/questions/11693074/git-credential-cache-is-not-a-git-command

    ### Mac OS user ?
    Remove keychain from storing your password
    ```
    git config --system --unset credential.helper
    ```
  4. @ankurk91 ankurk91 revised this gist Oct 6, 2016. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion git_remember_password.md
    Original file line number Diff line number Diff line change
    @@ -1,4 +1,4 @@
    #### Git: Tired of entering password again and again ?
    #### Git tip: Tired of entering password again and again ?

    Run this command to remember your password:

  5. @ankurk91 ankurk91 revised this gist Sep 7, 2016. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion git_remember_password.md
    Original file line number Diff line number Diff line change
    @@ -1,4 +1,4 @@
    #### Tired of entering password again and again, when ever pull or push to server ?
    #### Git: Tired of entering password again and again ?

    Run this command to remember your password:

  6. @Ank91 Ank91 revised this gist May 3, 2016. 1 changed file with 8 additions and 0 deletions.
    8 changes: 8 additions & 0 deletions git_remember_password.md
    Original file line number Diff line number Diff line change
    @@ -21,3 +21,11 @@ Above command will flush any stored password from cache.

    Reference:
    http://git-scm.com/docs/git-credential-cache

    #### Windows User ?
    ```
    git config --global credential.helper wincred
    ```
    Ref for Windows:
    http://stackoverflow.com/questions/11693074/git-credential-cache-is-not-a-git-command
  7. @Ank91 Ank91 revised this gist Jan 7, 2016. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion git_remember_password.md
    Original file line number Diff line number Diff line change
    @@ -1,4 +1,4 @@
    #### Tired of entering password again and again, when ever pull or push to server.
    #### Tired of entering password again and again, when ever pull or push to server ?

    Run this command to remember your password:

  8. @Ank91 Ank91 created this gist Jan 5, 2016.
    23 changes: 23 additions & 0 deletions git_remember_password.md
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,23 @@
    #### Tired of entering password again and again, when ever pull or push to server.

    Run this command to remember your password:

    ```bash
    git config --global credential.helper 'cache --timeout 28800'
    ```

    Above command will tell git to cache your password for 8 hours.

    #### How to make git forget this password ?

    If you want to switch to another github account then u can run this command

    ```bash
    git credential-cache exit
    ```
    Above command will flush any stored password from cache.

    ------------------------------

    Reference:
    http://git-scm.com/docs/git-credential-cache