-
Notifications
You must be signed in to change notification settings - Fork 29.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Running Commands in VS Code Terminal does not save the history #181508
Comments
This works for me |
Doesn't work for me either, tried deleting |
Maybe this is a remote issue |
More reports here: #180474 |
This affects me on my MacBook Pro as well. It's a problem 100% of the time, it's not intermittent. I'm guessing it's not a remote issue, as it happens when I'm using a completely local folder without any sort of remote functionality. There are several other reports of this issue in #180474 as well. If I type |
Yes, the history save feature works if I type |
I think that I have found the issue.
In this line, we are sending However it seems that this change was made because the terminal subprocess (running I think the solution to this can be done by creating a function something like : cleanup() {
err=$?
trap '' EXIT INT TERM
exit $err
}
sig_cleanup() {
trap '' EXIT
false # sets $?
cleanup
}
trap sig_cleanup TERM (relevant discussion in SO) |
If it is possible, could you help me to write a patch to fix this issue? 😄 I have tried patching the |
Running commands in a normal bash terminal retains the history (of the commands ran) but the same is not true for VS Code. So after closing VSCode all of the command history is deleted and the user has to remember any complex command that they ran. Ideally we would want our history to be stored in .bash_history or if VS Code doesn't want to touch user files, in .vscode_bash_history perhaps?
The text was updated successfully, but these errors were encountered: