by michaelmior · 3y ago · 0 comments
# Allow Ctrl-z to toggle between suspend and resume
function Resume {
fg
zle push-input
BUFFER=""
zle accept-line
}
zle -N Resume
bindkey "^Z" ResumeThrew it in my .zshrc right away. Thank you sir.
bind \cz 'fg 2>/dev/null; commandline -f repaint'
from: https://github.com/fish-shell/fish-shell/issues/7152#issueco...Saw this in the internets
if [[ $- == i ]]; then
stty susp undef
bind '"\C-z":" fg\015"'
fiThat said, if you wanted to continue running in the background with `bg`, you could make that substitution to allow you to double tap Ctrl-z to do so.