Added edit-server, use conf-mode for /etc/conf.d/.

This commit is contained in:
tastytea 2019-05-05 15:56:38 +02:00
parent 35639c13b7
commit a5ed9c62c5
2 changed files with 26 additions and 8 deletions

32
init.el
View File

@ -1,5 +1,5 @@
;;; init.el --- tastytea's Emacs init file.
;; Time-stamp: <2019-05-02T18:29:43+00:00>
;; Time-stamp: <2019-05-05T13:51:28+00:00>
;;; Commentary:
;; I am using this file with Emacs 26, but most of it will probably work with
@ -632,10 +632,10 @@ With argument, do this that many times."
(whitespace-space ((nil :foreground "gray18"))))
;; Spell checking.
(if (or (executable-find "aspell")
(executable-find "hunspell")
(executable-find "ispell"))
(unless slow-computer
(unless slow-computer
(if (or (executable-find "aspell")
(executable-find "hunspell")
(executable-find "ispell"))
(use-package flyspell
:custom
(ispell-dictionary "english")
@ -751,6 +751,11 @@ With argument, do this that many times."
:hook
(find-file . auto-insert))
;; Use conf-mode for openrc config files.
(use-package conf-mode
:mode
("\\`/etc/conf.d/" . conf-mode))
;;;;;;;;;;;;;;;;;;;; LaTeX ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(if (executable-find "xetex")
(use-package tex-site
@ -871,6 +876,8 @@ With argument, do this that many times."
:hook
(yaml-mode . my/set-fill-column-80))
(use-package mediawiki)
;;;;;;;;;;;;;;;;;;;; Server / Remote editing ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Edit remote files.
(unless slow-computer
@ -906,8 +913,19 @@ With argument, do this that many times."
"phahw2ohVoh0oopheish7IVie9desh8aequeenei3uo8wahShe%thuadaeNa4ieh")
:config
(if (not (eq (server-running-p) t)) ; Run server if not t.
(server-start))
)))
(server-start)))
;; Server for Firefox-extension that allows to use Emacs to edit textareas.
;; https://addons.mozilla.org/de/firefox/addon/edit-with-emacs1/
(use-package edit-server
:config
(edit-server-start)
:custom
(edit-server-url-major-mode-alist
'(("\\`likeable\\.space" . markdown-mode)
("\\`wiki\\.gentoo\\.org" . mediawiki-mode)
)))
))
;; Set garbage collection threshold to original value.
(setq gc-cons-threshold (car (get 'gc-cons-threshold 'standard-value)))

View File

@ -1,2 +1,2 @@
127.0.0.1:51313 17176
127.0.0.1:51313 26773
phahw2ohVoh0oopheish7IVie9desh8aequeenei3uo8wahShe%thuadaeNa4ieh