Maximus5 / ConEmu

Customizable Windows terminal with tabs, splits, quake-style, hotkeys and more
https://conemu.github.io/
BSD 3-Clause "New" or "Revised" License
8.53k stars 572 forks source link

Soft console shutdown on machine reboot/shutdown #1575

Open UnoSD opened 6 years ago

UnoSD commented 6 years ago

Versions

ConEmu build: 160724 x64 OS version: Windows 10 x64 Used shell version (Far Manager, git-bash, cmd, powershell, cygwin, whatever): cygwin

Problem description

When I use ConEmu and at the end of the day I shutdown the machine, the next time all the commands I used are not stored into .bash_history. Would be nice it ConEmu did a soft shutdown (exit) on Bash when it gets killed by Window. This behaviour is the same as the one in Guake/other terminal emulators in Linux.

Steps to reproduce

  1. Type any command
  2. Restart the machine
  3. Press UP to see the previous commands

Actual results

History is not saved

Expected results

soft exit invoked on the guest shell

Maximus5 commented 6 years ago

Why do you report cygwin/bash problem here?

UnoSD commented 6 years ago

@Maximus5 if I type exit in cygwin the history is saved. While this could be handled at cygwin level, it could also be handled by ConEmu. If you have no interest in implementing this you can close the issue.

In addition, the cygwin terminal does not have this issue.

Maximus5 commented 6 years ago

In addition, the cygwin terminal does not have this issue

Really? Press Win+R and type c:\cygwin\bin\bash.exe -l -i. Type commands and shutdown. History is saved, isn't it?

UnoSD commented 6 years ago

Start mintty type something, hit enter and then close the window: history saved.

Start ConEmu do the same, close the window: history not saved.

See the difference?