Update emacs.el

Changed files
+22
+22
emacs.el
···
+
;; Save all by default
(global-set-key (kbd "C-x s")
(lambda ()
(interactive)
(save-some-buffers t)))
+
;; Get rid of backup files
(setq make-backup-files nil)
(setq create-lockfiles nil)
(auto-save-visited-mode)
+
;; Command-line reformatters should reload
+
(global-auto-revert-mode t)
+
+
;; Sometimes hit C-x C-c and lose state. Forbid this.
(defun exit ()
(interactive)
(save-buffers-kill-terminal t))
(defun remove-exit ()
(interactive)
(global-set-key (kbd "C-x C-c") nil))
+
+
(setq compilation-always-kill t)
+
(setq compilation-ask-about-save nil)
+
(setq compile-command "")
+
(global-set-key (kbd "C-c c") 'compile)
+
+
;; TODO: Do I want keybindings for this?
+
(defun osc52-encode-utf8-base64 (string &rest base64-encode-args)
+
(apply 'base64-encode-string
+
(encode-coding-string string 'utf-8)
+
base64-encode-args))
+
(defun osc52-select-text (string &rest args)
+
(send-string-to-terminal
+
(concat "\e]52;c;"
+
(osc52-encode-utf8-base64 string t)
+
"\07")))