From e0dd59640f57c98fd4db1b2712e4911dde703e05 Mon Sep 17 00:00:00 2001 From: insects Date: Sat, 11 Jan 2025 15:18:55 +0100 Subject: [PATCH] set up typst support for emacs --- dot_config/doom/config.el | 11 ++++++++++- dot_config/doom/packages.el | 9 +++++++++ 2 files changed, 19 insertions(+), 1 deletion(-) diff --git a/dot_config/doom/config.el b/dot_config/doom/config.el index c3496dc..52b13a7 100644 --- a/dot_config/doom/config.el +++ b/dot_config/doom/config.el @@ -1,6 +1,6 @@ ;;; $DOOMDIR/config.el -*- lexical-binding: t; -*- -(setq user-full-name "pelsh" +(setq user-full-name "insects" user-mail-address "mail@liv.nrw") ;; Set fonts and window sizes @@ -34,6 +34,15 @@ :custom (mood-line-gylph-alist mood-line-glyphs-fira-code)) +;; Map some typst-ts-mode keys +(map! :map typst-ts-mode-map + :localleader + "p p" #'typst-preview-start + "p o" #'typst-preview-open-browser + "p k" #'typst-preview-stop + "c c" #'typst-ts-compile + "c p" #'typst-ts-preview) + ;; Whenever you reconfigure a package, make sure to wrap your config in an ;; `after!' block, otherwise Doom's defaults may override your settings. E.g. ;; diff --git a/dot_config/doom/packages.el b/dot_config/doom/packages.el index acc2f93..4e2ffc4 100644 --- a/dot_config/doom/packages.el +++ b/dot_config/doom/packages.el @@ -14,6 +14,15 @@ ;; Custom modeline (package! mood-line) +;; Typst TS mode +(package! typst-ts-mode + :recipe (:host codeberg :repo "meow_king/typst-ts-mode")) + +;; Typst preview +(package! websocket) +(package! typst-preview + :recipe (:host github :repo "havarddj/typst-preview.el")) + ;; To install SOME-PACKAGE from MELPA, ELPA or emacsmirror: ;; (package! some-package)