Search code examples
zshfishstty

make stty raw -echo works with zsh or fish


I would like to know if someone has a way to make stty raw -echo works on fish or zsh.

I used it to upgrade a reverse shell but when I do fg i can't press "enter" etc

I got this result :

enter image description here

Thanks !


Solution

  • Fish restores terminal modes to a specific (and uncustomizable) set whenever it regains control, but not after each command, so you can run both commands in one commandline, like

    stty raw -echo; fg
    

    instead of separately.