I'm looking to have a hook that triggers when a buffer marked read-only is attempted to be written. It's more of a convenience than necessary, I'm aware of Cx Cq which is currently where the function triggers (a Perforce p4-edit command), but it seems cleaner to do this when I begin to type (Much like the Visual Studio P4 plugin I believe).
Any help much appreciated as I've ran out of ideas.
Thanks, Jon.
This is an error which you can catch:
http://www.gnu.org/software/emacs/elisp/html_node/Handling-Errors.html
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.