summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--emacs/inits/20-programming.el18
-rw-r--r--emacs/inits/21-functional.el21
-rw-r--r--emacs/inits/23-text-related.el137
-rw-r--r--emacs/inits/24-latex.el202
-rw-r--r--emacs/inits/27-gemini.el47
-rw-r--r--xkb_vlomwide1
6 files changed, 181 insertions, 245 deletions
diff --git a/emacs/inits/20-programming.el b/emacs/inits/20-programming.el
index 7d9c42f..d1085d2 100644
--- a/emacs/inits/20-programming.el
+++ b/emacs/inits/20-programming.el
@@ -1,4 +1,4 @@
-;; Time-stamp: <2024-02-03 18h41 CET (81828d54)>
+;; Time-stamp: <2024-05-27 20h15 CEST (83a9252e)>
;; -----------------------------------------------------------------------------
;; General setup
@@ -37,11 +37,14 @@
(dtrt-indent-global-mode t))
(defun programming-setup ()
+ (interactive)
+ (spell-fu-mode -1)
(subword-mode 1)
(electric-pair-local-mode)
(set-fill-column 80)
- (hs-minor-mode)
(display-line-numbers-mode 1)
+ (when (not (eq major-mode 'text-mode))
+ (hs-minor-mode))
(setq auto-hscroll-mode t)
(when (not (eq major-mode 'python-mode))
(keymap-set (current-local-map) "M-/" 'completion-at-point))
@@ -251,11 +254,16 @@
;; -------------------------------------------------------------------
;; Misc languages
+(add-to-list 'auto-mode-alist
+ '("\\.jinja\\'" . (lambda ()
+ (text-mode)
+ (auto-fill-mode -1)
+ (programming-setup))))
+
(use-package json-mode
:ensure t
:defer t
- :mode (("\\.json\\.jinja\\'" . json-mode)
- ("\\.jinja" . json-mode))
+ :mode (("\\.json\\.jinja\\'" . json-mode))
:hook (json-mode . (lambda ()
(programming-setup)
(setq standard-indent 2)
@@ -348,8 +356,6 @@
(require 'bqn-keymap-mode)
(require 'bqn-glyph-mode)
(setq save-abbrevs 'silently)
- ;; (set-face-font 'bqn-default "Berkeley Mono")
- (set-face-attribute 'bqn-default nil :height 320)
(define-abbrev-table 'bqn-mode-abbrev-table
'( ;; funtions
("abs" "│")
diff --git a/emacs/inits/21-functional.el b/emacs/inits/21-functional.el
index 3bec067..130de21 100644
--- a/emacs/inits/21-functional.el
+++ b/emacs/inits/21-functional.el
@@ -1,8 +1,12 @@
-;; Time-stamp: <2024-01-23 21h50 CET (1c015732)>
+;; Time-stamp: <2024-05-27 20h11 CEST (83a9252e)>
;; -----------------------------------------------------------------------------
;; Haskell
+(use-package consult-hoogle
+ :ensure t
+ :defer)
+
(use-package haskell-mode
:ensure t
:bind (:map haskell-mode-map
@@ -24,17 +28,16 @@
(interactive-haskell-mode)
(turn-on-haskell-doc-mode)
(turn-on-haskell-decl-scan)
- (eglot-ensure)
- (haskell-mode-stylish-buffer))))
+ (haskell-mode-stylish-buffer)
+ (eglot-ensure))))
:config
(setq haskell-doc-show-global-types t
haskell-doc-show-prelude t
- haskell-doc-show-user-defined t
haskell-doc-show-reserved t
+ haskell-doc-show-user-defined t
haskell-interactive-mode-eval-pretty t
- haskell-process-type 'auto
- haskell-stylish-on-save t
- haskell-process-use-presentation-mode t
- haskell-process-suggest-imports t
+ haskell-process-show-debug-tips nil
haskell-process-suggest-hoogle-imports t
- haskell-process-show-debug-tips nil))
+ haskell-process-suggest-imports t
+ haskell-process-use-presentation-mode t
+ haskell-stylish-on-save t))
diff --git a/emacs/inits/23-text-related.el b/emacs/inits/23-text-related.el
index 797b0d0..7142980 100644
--- a/emacs/inits/23-text-related.el
+++ b/emacs/inits/23-text-related.el
@@ -1,4 +1,4 @@
-;; Time-stamp: <2023-01-13 12h54 CET (anker)>
+;; Time-stamp: <2024-05-26 11h27 CEST (00c25734)>
;; -----------------------------------------------------------------------------
;; Spelling
@@ -17,53 +17,12 @@
font-lock-keyword-face
font-lock-function-name-face
font-lock-variable-name-face)))
-
-;; (defun flyspell-correct-selectrum (candidates word)
-;; (let* ((save "[SAVE]")
-;; (accept-session "[ACCEPT (session)]")
-;; (accept-buffer "[ACCEPT (buffer)]")
-;; (skip "[SKIP]")
-;; (selectrucm-should-sort nil)
-;; (result (selectrum-completing-read
-;; (format "Correcting '%s': " word)
-;; (append candidates
-;; (list save accept-session accept-buffer skip)))))
-;; (cond
-;; ((string= result save)
-;; (cons 'save word))
-;; ((string= result accept-session)
-;; (cons 'session word))
-;; ((string= result accept-buffer)
-;; (cons 'buffer word))
-;; ((string= result skip)
-;; (cons 'skip word))
-;; (t
-;; result))))
-
-;; (use-package flyspell-correct
-;; :ensure t
-;; :defer t
-;; :config
-;; (setq flyspell-correct-interface #'flyspell-correct-selectrum))
-
-;; (use-package flyspell
-;; :ensure t
-;; :bind (:map flyspell-mode-map
-;; ("M-$" . flyspell-correct-wrapper)
-;; ("C-," . nil)
-;; ("C-." . nil)
-;; ("C-\"" . nil))
-;; :init
-;; (setq ispell-dictionary "british"
-;; flyspell-default-dictionary "british"))
-
(setq sentence-end-double-space nil)
(add-hook 'mail-mode-hook (lambda ()
(electric-pair-local-mode 1)
(turn-on-auto-fill)
(spell-fu-mode 1)
- ;; (flyspell-mode 1)
(company-mode 1)))
(add-hook 'text-mode-hook (lambda ()
@@ -72,18 +31,20 @@
(electric-pair-local-mode 1)
(turn-on-auto-fill)
(siege-mode 1)
- (spell-fu-mode 1)
- ;; (flyspell-mode 1)
- ))
+ (spell-fu-mode 1)))
(use-package dictionary :ensure t :defer t)
+(use-package ereader :ensure t :defer
+ :mode (("\\.epub$" . nov-mode)))
+
;; -----------------------------------------------------------------------------
;; Markdown
(use-package markdown-mode
:ensure t
:defer t
+ :mode (("\\.md'" . markdown-mode))
:hook (markdown-mode . (lambda ()
(auto-fill-mode -1)
(visual-line-mode))))
@@ -92,73 +53,35 @@
;; -----------------------------------------------------------------------------
;; Org
-(use-package org
- :defer t
- :bind (:map org-mode-map
- ("M-h" . nil))
- ;; :hook (org-mode . (lambda ()
- ;; (activate-input-method default-input-method)))
- :config
- (setq org-use-sub-superscripts (quote {})
- org-modules nil))
+;; (use-package org
+;; :defer t
+;; :bind (:map org-mode-map
+;; ("M-h" . nil))
+;; ;; :hook (org-mode . (lambda ()
+;; ;; (activate-input-method default-input-method)))
+;; :config
+;; (setq org-use-sub-superscripts (quote {})
+;; org-modules nil))
;; -----------------------------------------------------------------------------
;; Deft
-(use-package deft
- :ensure t
- :defer t
- :commands (deft)
- :bind (("C-c C-z" . deft))
- :config
- (setq deft-default-extension "org"
- deft-directory "~/store/notes"
- deft-use-filename-as-title nil
- deft-use-filter-string-for-filename t
- deft-file-naming-rules '((noslash . "_")
- (nospace . "_")
- (case-fn . downcase))
- deft-org-mode-title-prefix t)
-
- ;; (defvar deft-take-note-pre-grab
- ;; '((region-thing . (let ((r (if (region-active-p)
- ;; (buffer-substring (region-beginning) (region-end))
- ;; (thing-at-point 'line))))
- ;; (if r (concat r "\n") "")))
- ;; (bfn . (let ((f (buffer-file-name))
- ;; (b (buffer-name))) (if f f (concat b " (no file associated)")))))
- ;; "List of pairs of symbol names and (functions evaluating to)
- ;; strings evaluated before the buffer is created, and made
- ;; available for deft-take-note-default-contents.")
-
- ;; (defvar deft-take-note-post-grab '()
- ;; "List of pairs of symbol names and (functions evaluating to)
- ;; strings evaluated after the buffer is created, and made
- ;; available for deft-take-note-default-contents.")
-
- ;; (defvar deft-take-note-default-contents '(region-thing bfn "\n")
- ;; "List with string literals and symbols defined in the pre and
- ;; post grab lists to be inserted into the buffer.")
-
- ;; (defun deft-take-note ()
- ;; (interactive)
- ;; (let ((pre-alist (mapcar #'(lambda (elt) `(,(car elt) . ,(eval (cdr elt))))
- ;; deft-take-note-pre-grab)))
- ;; (let ((bn (concat (format-time-string "%Y%m%d-%H:%M:%S.%N-%Z") "."
- ;; deft-default-extension)))
- ;; (switch-to-buffer bn)
- ;; (set-visited-file-name (expand-file-name
- ;; (concat deft-directory "/" bn)))
- ;; (let ((complete-alist
- ;; (append pre-alist
- ;; (mapcar #'(lambda (elt) `(,(car elt) . ,(eval (cdr elt))))
- ;; deft-take-note-post-grab))))
- ;; (mapc #'(lambda (elt) (if (eq (type-of elt) 'string)
- ;; (insert elt)
- ;; (insert (cdr (assoc elt complete-alist)))))
- ;; deft-take-note-default-contents)))))
- )
+;; (use-package deft
+;; :ensure t
+;; :defer t
+;; :commands (deft)
+;; :bind (("C-c C-z" . deft))
+;; :config
+;; (setq deft-default-extension "md"
+;; deft-directory "~/notes"
+;; deft-use-filename-as-title nil
+;; deft-use-filter-string-for-filename t
+;; deft-file-naming-rules '((noslash . "_")
+;; (nospace . "_")
+;; (case-fn . downcase))
+;; deft-org-mode-title-prefix t)
+;; )
;; -----------------------------------------------------------------------------
;; Useful keybinds
diff --git a/emacs/inits/24-latex.el b/emacs/inits/24-latex.el
index 4922cf1..4b9e908 100644
--- a/emacs/inits/24-latex.el
+++ b/emacs/inits/24-latex.el
@@ -1,4 +1,4 @@
-;; Time-stamp: <2023-07-15 19h45 CEST (anker)>
+;; Time-stamp: <2024-05-27 20h16 CEST (83a9252e)>
(defvar latex-template-dir (expand-file-name "~/typeset/latex-templates"))
(defun prompt-latex-file-template ()
@@ -7,17 +7,17 @@ interactively. If neither, prompt to insert from a template
populated from the directory *latex-template-dir*"
(interactive)
(when (and (if (file-exists-p (buffer-file-name))
- (called-interactively-p 'interactive)
- t)
- (yes-or-no-p "Insert template?"))
+ (called-interactively-p 'interactive)
+ t)
+ (yes-or-no-p "Insert template?"))
(let* ((tfiles (directory-files latex-template-dir nil "\\.tex"))
- (template (completing-read "Select template: " tfiles nil t)))
+ (template (completing-read "Select template: " tfiles nil t)))
(when template
- (goto-char (point-min))
- (insert-file-contents (concat latex-template-dir "/" template))
- (search-forward "begin{document}")
- (forward-line)
- (save-buffer)))))
+ (goto-char (point-min))
+ (insert-file-contents (concat latex-template-dir "/" template))
+ (search-forward "begin{document}")
+ (forward-line)
+ (save-buffer)))))
(use-package cdm-mode
:load-path "~/.emacs.d/scripts/")
@@ -27,25 +27,25 @@ populated from the directory *latex-template-dir*"
(use-package latex
:ensure auctex
:bind (:map LaTeX-mode-map
- ("<" . LaTeX-insert-left-brace)
- ;; ("|" . LaTeX-insert-left-brace)
- ("'" . better-TeX-insert-single-quote)
- ;; ("TAB" . LaTeX-indent-line)
- ("M-TAB" . TeX-complete-symbol)
- ("M-q" . unfill-paragraph)
- ("C-c e" . LaTeX-environment)
- ("C-c C-d" . TeX-view))
+ ("<" . LaTeX-insert-left-brace)
+ ;; ("|" . LaTeX-insert-left-brace)
+ ("'" . better-TeX-insert-single-quote)
+ ;; ("TAB" . LaTeX-indent-line)
+ ("M-TAB" . TeX-complete-symbol)
+ ("M-q" . unfill-paragraph)
+ ("C-c e" . LaTeX-environment)
+ ("C-c C-d" . TeX-view))
:hook (LaTeX-mode . (lambda ()
- (latex-setup-visual-aesthetics)
- (latex-setup-text-environment)
- (latex-setup-special-minor-modes)
- (latex-setup-completions)
- (prompt-latex-file-template)))
+ (latex-setup-visual-aesthetics)
+ (latex-setup-text-environment)
+ (latex-setup-special-minor-modes)
+ (latex-setup-completions)
+ (prompt-latex-file-template)))
:init
(defun latex-setup-visual-aesthetics ()
(interactive)
- (variable-pitch-mode 1)
+ (variable-pitch-mode -1)
(auto-fill-mode -1)
(visual-line-mode)
(display-line-numbers-mode))
@@ -76,37 +76,37 @@ populated from the directory *latex-template-dir*"
(defun better-TeX-insert-single-quote ()
(interactive)
(let ((old-open TeX-open-quote)
- (old-close TeX-close-quote))
+ (old-close TeX-close-quote))
(unwind-protect (progn
- (setq TeX-open-quote "`"
- TeX-close-quote "'")
- (call-interactively 'TeX-insert-quote))
- (setq TeX-open-quote old-open
- TeX-close-quote old-close))))
+ (setq TeX-open-quote "`"
+ TeX-close-quote "'")
+ (call-interactively 'TeX-insert-quote))
+ (setq TeX-open-quote old-open
+ TeX-close-quote old-close))))
:config
(setq TeX-debug-bad-boxes t
- TeX-command-list '(("XeLaTeX" "xelatex %t"
- TeX-run-TeX nil (latex-mode doctex-mode) :help "Run XeLaTeX")
- ("TeX" "%(PDF)%(tex) %(file-line-error) %`%(extraopts) %S%(PDFout)%(mode)%' %t"
- TeX-run-TeX nil (plain-tex-mode ams-tex-mode texinfo-mode) :help "Run plain TeX")
- ("LaTeX" "%`%l%(mode)%' %T"
- TeX-run-TeX nil (latex-mode doctex-mode) :help "Run LaTeX")
- ("Biber" "biber %s %(output-dir)" TeX-run-Biber nil
- (plain-tex-mode latex-mode doctex-mode ams-tex-mode texinfo-mode) :help "Run Biber")
- ("BibTeX" "bibtex %s" TeX-run-BibTeX nil
- (plain-tex-mode latex-mode doctex-mode ams-tex-mode texinfo-mode context-mode) :help "Run BibTeX")
- ("View" "%V" TeX-run-discard-or-function t t :help "Run External Viewer")
- ("View internally" "(find-file \"%o\")" TeX-run-function nil t :help "Run Viewer")
- ("Spell" "(TeX-ispell-document \"\")" TeX-run-function nil t :help "Spell-check the document")
- ("Clean" "TeX-clean" TeX-run-function nil t :help "Delete generated intermediate files")
- ("Clean All" "(TeX-clean t)" TeX-run-function nil t :help "Delete generated intermediate and output files")
- ("Other" "" TeX-run-command t t :help "Run an arbitrary command")))
+ TeX-command-list '(("XeLaTeX" "xelatex %t"
+ TeX-run-TeX nil (latex-mode doctex-mode) :help "Run XeLaTeX")
+ ("TeX" "%(PDF)%(tex) %(file-line-error) %`%(extraopts) %S%(PDFout)%(mode)%' %t"
+ TeX-run-TeX nil (plain-tex-mode ams-tex-mode texinfo-mode) :help "Run plain TeX")
+ ("LaTeX" "%`%l%(mode)%' %T"
+ TeX-run-TeX nil (latex-mode doctex-mode) :help "Run LaTeX")
+ ("Biber" "biber %s %(output-dir)" TeX-run-Biber nil
+ (plain-tex-mode latex-mode doctex-mode ams-tex-mode texinfo-mode) :help "Run Biber")
+ ("BibTeX" "bibtex %s" TeX-run-BibTeX nil
+ (plain-tex-mode latex-mode doctex-mode ams-tex-mode texinfo-mode context-mode) :help "Run BibTeX")
+ ("View" "%V" TeX-run-discard-or-function t t :help "Run External Viewer")
+ ("View internally" "(find-file \"%o\")" TeX-run-function nil t :help "Run Viewer")
+ ("Spell" "(TeX-ispell-document \"\")" TeX-run-function nil t :help "Spell-check the document")
+ ("Clean" "TeX-clean" TeX-run-function nil t :help "Delete generated intermediate files")
+ ("Clean All" "(TeX-clean t)" TeX-run-function nil t :help "Delete generated intermediate and output files")
+ ("Other" "" TeX-run-command t t :help "Run an arbitrary command")))
(setq TeX-electric-sub-and-superscript t
- TeX-electric-math '("$" . "$")
- TeX-electric-escape nil
- LaTeX-electric-left-right-brace t)
+ TeX-electric-math '("$" . "$")
+ TeX-electric-escape nil
+ LaTeX-electric-left-right-brace t)
;; no idea why this is not a default ... ?
(push '("<" . ">") TeX-braces-association)
@@ -114,13 +114,13 @@ populated from the directory *latex-template-dir*"
(setq reftex-plug-into-AUCTeX t)
;; (setq-default TeX-master nil)
(setq TeX-auto-save t
- TeX-parse-self t
- TeX-PDF-mode t
- TeX-source-correlate-mode 'synctex
- TeX-view-program-selection '(((output-dvi style-pstricks) "dvips and gv")
- (output-dvi "xdvi")
- (output-pdf "Zathura")
- (output-html "xdg-open")))
+ TeX-parse-self t
+ TeX-PDF-mode t
+ TeX-source-correlate-mode 'synctex
+ TeX-view-program-selection '(((output-dvi style-pstricks) "dvips and gv")
+ (output-dvi "xdvi")
+ (output-pdf "Zathura")
+ (output-html "xdg-open")))
;; for PDF tools
;; (add-hook 'TeX-after-compilation-finished-functions #'TeX-revert-document-buffer)
@@ -130,50 +130,50 @@ populated from the directory *latex-template-dir*"
(use-package cdlatex
:ensure t
:bind (:map cdlatex-mode-map
- ("(" . nil)
- ("{" . nil)
- ("[" . nil)
- ("|" . nil)
- ("<" . nil)
- ("'" . nil)
- ("TAB" . cdlatex-tab)
- ;; ("C-c e" . cdlatex-environment)
- ("~" . cdlatex-math-modify)
- ("`" . cdlatex-math-symbol))
+ ("(" . nil)
+ ("{" . nil)
+ ("[" . nil)
+ ("|" . nil)
+ ("<" . nil)
+ ("'" . nil)
+ ("TAB" . cdlatex-tab)
+ ;; ("C-c e" . cdlatex-environment)
+ ("~" . cdlatex-math-modify)
+ ("`" . cdlatex-math-symbol))
:init
(setq cdlatex-math-modify-prefix ?~
- cdlatex-math-symbol-prefix ?`
- cdlatex-math-modify-alist '((?a "\\mathbb" nil t nil nil)
- (?c "\\mathcal" "\\textsc" t nil nil)
- (?v "\\texttt" "\\texttt" t nil nil)
- (?k "\\mathfrak" nil t nil nil)
- (?- "\\overline" nil t nil nil)
- (?_ "\\underline" nil t nil nil))
- cdlatex-math-symbol-alist '((?^ ("\\widehat{?}" "\\hat{?}"))
- (?' ("^{\\prime}" "\\prime"))
- (?* ("\\times" "\\otimes" "\\star"))
- (?+ ("+" "\\oplus"))
- (?- ("\\dashv" "\\vdash" "\\setminus"))
- (?. ("\\circ" "\\sq" "\\cdot"))
- (?0 ("\\emptyset" "\\circ"))
- (?< ("\\leftarrow" "\\leftharpoonup" "\\xleftarrow"))
- (?> ("\\to" "\\rightharpoonup" "\\xrightarrow"))
- (?B ("\\bullet"))
- (?C ("\\widecheck{?}" "\\check{?}"))
- (?f ("\\varphi" "\\phi"))
- (?F ("\\Phi" "\\Varphi"))
- (?M ("\\begin{bsmallmatrix}?\\end{bsmallmatrix}"))
- (?P ("\\Prod{?}" "\\Pi" "\\partial"))
- (?S ("\\Sigma" "\\Sum{?}" "\\arcsin"))
- (?\"("^{\\prime\\prime}" "\\prime\\prime"))
- (?a ("\\alpha" "\\cap" "\\sqcap"))
- (?c ("\\cat{?}" "\\catn{?}"))
- (?e ("\\varepsilon" "\\epsilon" "\\exp{?}"))
- (?i ("\\iota" "\\in"))
- (?j ("{\\id^{h}}_{?}" "{\\id^{v}}_{?}"))
- (?r ("\\rho" "\\varrho" "\\restrict{?}"))
- (?u ("\\upsilon" "\\cup" "\\sqcup"))
- (?y ("\\psi" "\\Psi"))
- (?{ ("\\subseteq" "\\subsetneq"))
- (?} ("\\supseteq" "\\supsetneq"))
- )))
+ cdlatex-math-symbol-prefix ?`
+ cdlatex-math-modify-alist '((?a "\\mathbb" nil t nil nil)
+ (?c "\\mathcal" "\\textsc" t nil nil)
+ (?v "\\texttt" "\\texttt" t nil nil)
+ (?k "\\mathfrak" nil t nil nil)
+ (?- "\\overline" nil t nil nil)
+ (?_ "\\underline" nil t nil nil))
+ cdlatex-math-symbol-alist '((?^ ("\\widehat{?}" "\\hat{?}"))
+ (?' ("^{\\prime}" "\\prime"))
+ (?* ("\\times" "\\otimes" "\\star"))
+ (?+ ("+" "\\oplus"))
+ (?- ("\\dashv" "\\vdash" "\\setminus"))
+ (?. ("\\circ" "\\sq" "\\cdot"))
+ (?0 ("\\emptyset" "\\circ"))
+ (?< ("\\leftarrow" "\\leftharpoonup" "\\xleftarrow"))
+ (?> ("\\to" "\\rightharpoonup" "\\xrightarrow"))
+ (?B ("\\bullet"))
+ (?C ("\\widecheck{?}" "\\check{?}"))
+ (?f ("\\varphi" "\\phi"))
+ (?F ("\\Phi" "\\Varphi"))
+ (?M ("\\begin{bsmallmatrix}?\\end{bsmallmatrix}"))
+ (?P ("\\Prod{?}" "\\Pi" "\\partial"))
+ (?S ("\\Sigma" "\\Sum{?}" "\\arcsin"))
+ (?\"("^{\\prime\\prime}" "\\prime\\prime"))
+ (?a ("\\alpha" "\\cap" "\\sqcap"))
+ (?c ("\\cat{?}" "\\catn{?}"))
+ (?e ("\\varepsilon" "\\epsilon" "\\exp{?}"))
+ (?i ("\\iota" "\\in"))
+ (?j ("{\\id^{h}}_{?}" "{\\id^{v}}_{?}"))
+ (?r ("\\rho" "\\varrho" "\\restrict{?}"))
+ (?u ("\\upsilon" "\\cup" "\\sqcup"))
+ (?y ("\\psi" "\\Psi"))
+ (?{ ("\\subseteq" "\\subsetneq"))
+ (?} ("\\supseteq" "\\supsetneq"))
+ )))
diff --git a/emacs/inits/27-gemini.el b/emacs/inits/27-gemini.el
index 26a4724..7a2a1ae 100644
--- a/emacs/inits/27-gemini.el
+++ b/emacs/inits/27-gemini.el
@@ -1,14 +1,16 @@
-;; Time-stamp: <2023-01-18 20h54 CET (anker)>
+;; Time-stamp: <2024-05-27 20h18 CEST (83a9252e)>
(use-package elpher
:ensure t
- :defer)
+ :demand
+ :config
+ (setq elpher-default-url-type "gemini"))
(use-package visual-fill-column
:ensure t
:defer)
-(defvar gemlog-directory (expand-file-name "~/logs/l-3.space/"))
+(defvar gemlog-directory (expand-file-name "~/hobbies/l-3.space/"))
(defvar gemlog-file-name "%y%02m%02d")
(defvar gemlog-time-string "%Y-%02m-%02d %02Hh%02M %Z")
(defvar gemlog-time-zone "UTC")
@@ -16,33 +18,35 @@
(defun gemlog-new-entry ()
(interactive)
(let* ((title (read-string "Title: "))
- (number 1)
- (file (format "%s/log-%s-%d.gmi"
- gemlog-directory
- (format-time-string gemlog-file-name nil t)
- number)))
+ (number 1)
+ (file (format "%s/log-%s-%d.gmi"
+ gemlog-directory
+ (format-time-string gemlog-file-name nil t)
+ number)))
(while (file-exists-p file)
(setq number (+ 1 number))
(setq file (format "%s/log-%s-%d.gmi"
- gemlog-directory
- (format-time-string gemlog-file-name nil t)
- number)))
+ gemlog-directory
+ (format-time-string gemlog-file-name nil t)
+ number)))
(find-file file)
(setq-local time-stamp-time-zone gemlog-time-zone
- time-stamp-format gemlog-time-string)
+ time-stamp-format gemlog-time-string)
(insert "Time-stamp: <>") (newline) (newline)
(insert "# " title) (newline) (newline)
- (time-stamp)))
+ (time-stamp)
+ (require 'gemini-mode)
+ (gemini-mode)))
(defvar gemini-footnote-symbols '("⁰" "¹" "²" "³" "⁴" "⁵" "⁶" "⁷" "⁸" "⁹" "ᵃ" "ᵇ" "ᶜ" "ᵈ" "ᵉ" "ᶠ"))
(defun gemini-insert-footnote ()
(interactive)
(let ((symb (car gemini-footnote-symbols))
- (n 0))
+ (n 0))
(while (and symb (save-excursion (beginning-of-buffer) (search-forward symb nil t)))
(setq n (1+ n)
- symb (nth n gemini-footnote-symbols)))
+ symb (nth n gemini-footnote-symbols)))
(if (not symb) (message "Ran out of footnote symbols. Customise `gemini-footnote-symbols'.")
(insert symb)
(end-of-buffer)
@@ -51,11 +55,12 @@
(use-package gemini-mode
:ensure t
+ :demand
:bind (:map gemini-mode-map
- ("C-c C-f" . gemini-insert-footnote))
+ ("C-c C-f" . gemini-insert-footnote))
:hook (gemini-mode . (lambda ()
- (setq time-stamp-time-zone gemlog-time-zone
- time-stamp-format gemlog-time-string)
- (setq-local indent-tabs-mode nil)
- (auto-fill-mode -1)
- (set-fill-column 80))))
+ (setq time-stamp-time-zone gemlog-time-zone
+ time-stamp-format gemlog-time-string)
+ (setq-local indent-tabs-mode nil)
+ (auto-fill-mode -1)
+ (set-fill-column 80))))
diff --git a/xkb_vlomwide b/xkb_vlomwide
index 1aacb7f..325605a 100644
--- a/xkb_vlomwide
+++ b/xkb_vlomwide
@@ -56,6 +56,5 @@ xkb_symbols "vlomwide" {
key <AB10> { [ b, B ] };
key <RTSH> { [ comma, less ] };
- key <CAPS> { [ BackSpace, BackSpace ] };
key <SPCE> { [ space, space ] };
};