You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
pre-commit and pre-push git hooks are not handled consistently when errors occur.
pre-commit:
pre-push:
Steps to Reproduce:
Create a fresh directory
git init
Create pre-commit and pre-push files in the git hooks directory with the following contents:
#!/bin/shecho"Failure message"exit 1
Try to commit from VSCode Source Control Tab
Error message says "Git: Failure message"
Disable the pre-commit hook
Make a successful commit
Configure a remote and attempt to run git push
Error message says "Can't push refs to remote. Try running "Pull" first to integrate your changes"
pre-commit seems to use the first line of output in the error dialog, whereas pre-push uses the last one. It'd be nice if these were consistent. Furthermore, it seems that I just can't control the dialog message for pre-push failures, it's always the same.
The text was updated successfully, but these errors were encountered:
Does this issue occur when all extensions are disabled?: Yes
Version: 1.76.2 (user setup)
Commit: ee2b180
Date: 2023-03-14T17:55:54.936Z
Electron: 19.1.11
Chromium: 102.0.5005.196
Node.js: 16.14.2
V8: 10.2.154.26-electron.0
OS: Windows_NT x64 10.0.19044
Sandboxed: No
Issue:
pre-commit
andpre-push
git hooks are not handled consistently when errors occur.pre-commit
:pre-push
:Steps to Reproduce:
git init
pre-commit
andpre-push
files in the git hooks directory with the following contents:pre-commit
hookgit push
pre-commit
seems to use the first line of output in the error dialog, whereaspre-push
uses the last one. It'd be nice if these were consistent. Furthermore, it seems that I just can't control the dialog message forpre-push
failures, it's always the same.The text was updated successfully, but these errors were encountered: