Skip to content
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

Vs code git bash integrated terminal always forgets it's history after re-open #122987

Closed
chtenb opened this issue May 5, 2021 · 3 comments
Closed
Assignees
Labels
*duplicate Issue identified as a duplicate of another issue(s) terminal Integrated terminal issues under-discussion Issue is under discussion for relevance, priority, approach

Comments

@chtenb
Copy link

chtenb commented May 5, 2021

I would reopen #37273 but I can't due to site restrictions.
This is still a problem and the subsequent comments in the thread are not addressed.

VSCode Version: latest 64bit
OS Version: win 10

Steps to Reproduce:

  • Use git bash as terminal
  • Open git bash and type ls
  • open vs code, type some other command (in the integrated terminal)
  • close vs code and open again
  • do arrow/cursor up. (in the integrated terminal)
  • The command shown is ls (history from git bash instead of git bash from vs code session).

It seems that git bash needs to be closed properly before vscode exits: https://stackoverflow.com/questions/10488498/bash-history-does-not-update-in-git-for-windows-git-bash
Can we implement this?

Does this issue occur when all extensions are disabled?: Yes

@Tyriar
Copy link
Member

Tyriar commented May 6, 2021

Thanks for the link, I don't think we can run exit as the SO link suggests, but maybe there's some other signal?

The history -a workaround seems good.

@Tyriar Tyriar added the under-discussion Issue is under discussion for relevance, priority, approach label May 6, 2021
@chtenb
Copy link
Author

chtenb commented May 7, 2021

The history -a workaround seems good.

That works indeed, but it means that every git bash user has to do the research and implement this workaround. It would be nice if we could provide expected behavior out of the box.

@meganrogge meganrogge added terminal Integrated terminal issues terminal-triage labels Oct 6, 2021
@Tyriar
Copy link
Member

Tyriar commented Oct 13, 2021

/duplicate #85831

@Tyriar Tyriar closed this as completed Oct 13, 2021
@github-actions github-actions bot locked and limited conversation to collaborators Nov 27, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
*duplicate Issue identified as a duplicate of another issue(s) terminal Integrated terminal issues under-discussion Issue is under discussion for relevance, priority, approach
Projects
None yet
Development

No branches or pull requests

4 participants
@chtenb @Tyriar @meganrogge and others