diff --git a/Customization.md b/Customization.md index 386f8d0..cd8e1bc 100644 --- a/Customization.md +++ b/Customization.md @@ -68,4 +68,20 @@ function! g:goyo_after() endfunction let g:goyo_callbacks = [function('g:goyo_before'), function('g:goyo_after')] +``` + +## Ensure `:q` to quit even when Goyo is active + +Suggested by [mm2703](https://github.com/mm2703) and [axelGschaider](https://github.com/axelGschaider) in [#16](https://github.com/junegunn/goyo.vim/issues/16) + +```vim +" Quitting whether Goyo is active or not +ca wq :w:call Quit() +ca q :call Quit() +function! Quit() + if exists('#goyo') + Goyo + endif + quit +endfunction ``` \ No newline at end of file