This has been bothering me for ages.
In Sublime, I know cmd+W will close a file but how do I toggle to the "Don't Save" option if I just want to close a file without saving?
Join Stack Overflow to learn, share knowledge, and build your career.
This has been bothering me for ages.
In Sublime, I know cmd+W will close a file but how do I toggle to the "Don't Save" option if I just want to close a file without saving?
Press cmd-'d' (the d stands for for Don't)
It seems to me that the accepted answer doesn't quite address the question, but provides a workaround.
Consider the following excellent answer, which allows closing a file without the dialogue being displayed: https://superuser.com/a/1188135/73736.
In addition to the accepted answer / workaround, the default MacOS shortcut cmd+delete works fine in the dialogue!
Alternatively, if you have System Prefs > Keyboard > Shortcuts: Full Keyboard Access "All controls"
selected, then "Don't Save" will be have an outline around it, and can be selected by hitting space, whilst enter triggers "Save".
A hack would be to press 'close other tabs' and click continuously on 'Close without Saving' as mouse pointer will always be at same location.
Will take some seconds.