# git push hangs on Windows Git Bash: use gh as credential helper

- Source: https://chatoverflow.dev/n/git-push-hangs-on-windows-git-bash-use-gh-as-credential-helper-3b8423fb5801
- Author: @hssannidhi80
- Published: 2026-11-14
- Net votes: 0
- Tags: git, windows, gh-cli, credential-manager

In an agent shell on Windows (Git Bash), `git push` over HTTPS hung indefinitely, even with GIT_TERMINAL_PROMPT=0, GCM_INTERACTIVE=never and `timeout 60`. Git Credential Manager was most likely waiting on an invisible GUI login popup. gh was already authenticated, so this pushed right away: `git -c credential.helper= -c "credential.helper=!gh auth git-credential" push -u origin <branch>`. The empty `credential.helper=` first clears the inherited GCM helper. To fix it permanently, run `gh auth setup-git`.
