2063 lines
86 KiB
EmacsLisp
Executable file
2063 lines
86 KiB
EmacsLisp
Executable file
(setq gc-cons-threshold 100000000)
|
||
(add-hook 'after-init-hook (lambda () (setq gc-cons-threshold 800000)))
|
||
|
||
;; (add-hook 'emacs-startup-hook
|
||
;; (lambda ()
|
||
;; (message "Emacs loaded in %s with %d garbage collections."
|
||
;; (format "%.2f seconds"
|
||
;; (float-time
|
||
;; (time-subtract after-init-time before-init-time)))
|
||
;; gcs-done)))
|
||
|
||
;; (setq gc-cons-threshold 100000000)
|
||
;; (add-hook 'after-init-hook (lambda () (setq gc-cons-threshold 800000)))
|
||
|
||
;; (require 'server)
|
||
;; (or (eq (server-running-p) t)
|
||
;; (server-start))
|
||
|
||
;; (load "bundle--general")
|
||
|
||
(tool-bar-mode -1)
|
||
(menu-bar-mode -1)
|
||
(global-hl-line-mode 1)
|
||
(display-time-mode 1)
|
||
(global-prettify-symbols-mode -1)
|
||
|
||
;; (setq display-time-format "W%V %a %d %b %Y %R %z")
|
||
(setq-default display-time-format "W%V %a %d %b %R")
|
||
(setq-default display-time-24hr-format t)
|
||
|
||
;; Cursor and mouse
|
||
(column-number-mode 1)
|
||
(mouse-wheel-mode 1)
|
||
(blink-cursor-mode -1)
|
||
|
||
(setq-default grep-command "grep -i -nH -e ")
|
||
|
||
(when (eq system-type 'gnu/linux)
|
||
(setq-default shell-file-name "/bin/bash")
|
||
(setq-default tex-shell-file-name "/bin/bash"))
|
||
|
||
;; Files and sessions
|
||
(setq-default auto-save-timeout 60)
|
||
|
||
;; Tabs, spaces, lines and parenthesis
|
||
(show-paren-mode 1)
|
||
(setq-default tab-width 4)
|
||
(setq-default indent-tabs-mode nil)
|
||
(setq-default line-spacing nil)
|
||
(setq-default make-backup-files nil)
|
||
(setq-default next-line-add-newlines t)
|
||
|
||
;; Miscellaneous
|
||
(require 'cl-lib)
|
||
(setq-default default-major-mode 'text-mode)
|
||
(setq-default inhibit-startup-buffer-menu t inhibit-startup-screen t)
|
||
(put 'narrow-to-region 'disabled nil)
|
||
(put 'narrow-to-page 'disabled nil)
|
||
(add-hook 'text-mode-hook 'turn-on-auto-fill)
|
||
(defalias 'yes-or-no-p 'y-or-n-p)
|
||
|
||
(add-hook 'after-save-hook
|
||
'executable-make-buffer-file-executable-if-script-p)
|
||
|
||
(global-set-key (kbd "M-i") 'imenu)
|
||
(global-set-key (kbd "C-x C-b") 'ibuffer-list-buffers)
|
||
;;(global-set-key (kbd "M-[") 'tab-bar-history-back)
|
||
;;(global-set-key (kbd "M-]") 'tab-bar-history-forward)
|
||
|
||
(add-hook 'diary-display-hook 'fancy-diary-display)
|
||
(add-hook 'today-visible-calendar-hook 'calendar-mark-today)
|
||
(add-hook 'write-file-hooks 'delete-trailing-whitespace)
|
||
(add-hook 'diary-list-entries-hook 'diary-include-other-diary-files)
|
||
(add-hook 'diary-mark-entries-hook 'diary-mark-included-diary-files)
|
||
(setq-default compilation-ask-about-save nil)
|
||
(setq-default vc-handled-backends '(Git Hg)) ;; Only use Git and Hg for VC
|
||
|
||
(setq-default horizontal-scroll-bar nil)
|
||
(setq-default vertical-scroll-bar nil)
|
||
|
||
(setq-default mouse-wheel-scroll-amount '(1 ((shift) . 1) ((meta)) ((control) . text-scale)))
|
||
|
||
;; SIMPLE
|
||
(setq-default completion-auto-wrap t)
|
||
(setq-default completion-auto-select t)
|
||
|
||
;; MINIBUFFER
|
||
(setq completions-format 'horizontal)
|
||
(setq completions-header-format nil)
|
||
(setq completions-max-height 20)
|
||
|
||
;; (require 'ido)
|
||
;; (setq ido-enable-flex-matching t)
|
||
;; (setq ido-everywhere t)
|
||
;; (setq ido-create-new-buffer 'always)
|
||
;;(setq ido-file-extensions-order '(".org" ".lisp" ".py" ".txt" ".el" ".epub"))
|
||
(ido-mode t)
|
||
;; (fido-mode 1) ; replace icomplete mode
|
||
;; (fido-vertical-mode 1)
|
||
;; UTF-8 FTW
|
||
;; Prefer UTF-8 encoding
|
||
(prefer-coding-system 'utf-8)
|
||
(set-default-coding-systems 'utf-8)
|
||
(set-terminal-coding-system 'utf-8)
|
||
(set-keyboard-coding-system 'utf-8)
|
||
;; Treat clipboard input as UTF-8 string first; compound text next, etc.
|
||
(setq x-select-request-type '(UTF8_STRING COMPOUND_TEXT TEXT STRING))
|
||
;; Set default file encoding to UTF-8
|
||
(setq-default buffer-file-coding-system 'utf-8)
|
||
;; Force UTF-8 for new files
|
||
(setq default-buffer-file-coding-system 'utf-8)
|
||
(setenv "PYTHONIOENCODING" "UTF-8")
|
||
|
||
(when (eq system-type 'gnu/linux)
|
||
(setq-default epg-pinentry-mode 'loopback)
|
||
|
||
(setq-default custom-file "~/.emacs.d/bundle/custom_gnu.el"
|
||
browse-url-secondary-browser-function 'browse-url-firefox)
|
||
(unless (file-directory-p "~/cl-sites/")
|
||
(async-shell-command "git clone git@git.sr.ht:~marcuskammer/cl-sites ~/cl-sites")))
|
||
|
||
(when (eq system-type 'windows-nt)
|
||
(setq-default explicit-shell-file-name
|
||
(seq-find 'file-executable-p
|
||
'("C:\\Program Files\\PowerShell\\7\\pwsh.exe"
|
||
"C:\\Windows\\System32\\WindowsPowerShell\\v1.0\\powershell.exe")))
|
||
(setq-default explicit-powershell.exe-args '("-NoProfile" "-InputFormat" "Text"))
|
||
(setq-default custom-file "~/.emacs.d/bundle/custom_win32.el")
|
||
|
||
(when (string= system-name "XPS-8930")
|
||
(cd "~/")
|
||
(setq-default custom-file "~/.emacs.d/bundle/custom_win32_XPS8930.el"))
|
||
|
||
(when (string= system-name "EVG03435NB")
|
||
(cd "~/OneDrive - Siemens AG/")
|
||
(setq-default custom-file "~/.emacs.d/bundle/custom_win32_EVG03435NB.el")))
|
||
|
||
(load custom-file :noerror)
|
||
|
||
(setq package-archives
|
||
'(("melpa" . "https://melpa.org/packages/")
|
||
("org" . "https://orgmode.org/elpa/")
|
||
("elpa" . "https://elpa.gnu.org/packages/")
|
||
("nongnu" . "https://elpa.nongnu.org/nongnu/")))
|
||
(package-initialize)
|
||
(unless package-archive-contents
|
||
(package-refresh-contents))
|
||
(unless (package-installed-p 'use-package)
|
||
(package-install 'use-package))
|
||
(eval-when-compile (require 'use-package))
|
||
(setq use-package-always-ensure t)
|
||
|
||
(use-package doom-themes
|
||
:init
|
||
(load-theme 'doom-one t)
|
||
:config
|
||
(setq doom-themes-enable-bold t
|
||
doom-themes-enable-italic t))
|
||
|
||
;; (load "bundle--gui")
|
||
|
||
(setq-default mode-line-format
|
||
'("%e" mode-line-front-space "%Z" " " "%b %*%n %I %l:%c %p" (vc-mode vc-mode) " " mode-line-modes mode-line-misc-info mode-line-end-spaces))
|
||
|
||
(unless (memq 'hs-headline mode-line-format)
|
||
(setq mode-line-format
|
||
(append '(" " hs-headline) mode-line-format)))
|
||
|
||
(set-face-attribute 'mode-line nil
|
||
:slant 'italic
|
||
:weight 'bold
|
||
:background (face-attribute 'default :background)
|
||
:foreground
|
||
(cond ((member 'doom-one custom-enabled-themes) "#5B6268")
|
||
((member 'doom-nord custom-enabled-themes) "#9099AB")
|
||
(t (face-attribute 'mode-line-inactive :foreground)))
|
||
:box '(:line-width (1 . 8) :style flat-button))
|
||
|
||
(set-face-attribute 'mode-line-inactive nil
|
||
:inherit 'mode-line
|
||
:weight 'normal
|
||
:box '(:line-width (1 . 8) :style flat-button))
|
||
|
||
(use-package tab-bar
|
||
:custom
|
||
(tab-bar-auto-width nil)
|
||
(tab-bar-auto-width-max '(250 25))
|
||
(tab-bar-format '(tab-bar-format-history tab-bar-format-tabs-groups))
|
||
(tab-bar-tab-name-function 'tab-bar-tab-name-truncated)
|
||
(tab-bar-close-button-show nil)
|
||
(tab-bar-new-button-show nil)
|
||
:config
|
||
(set-face-attribute 'tab-bar nil
|
||
:inherit 'mode-line-inactive
|
||
:background (face-attribute 'mode-line-inactive :background))
|
||
|
||
(set-face-attribute 'tab-bar-tab nil
|
||
:inherit 'mode-line
|
||
:foreground (face-attribute 'mode-line :foreground)
|
||
:box '(:line-width 8 :style flat-button))
|
||
|
||
(set-face-attribute 'tab-bar-tab-inactive nil
|
||
:inherit 'mode-line-inactive
|
||
:box '(:line-width 8 :style flat-button)))
|
||
|
||
(setq default-frame-alist
|
||
`((font . "MonoLisa-11")
|
||
(width . 85)
|
||
(height . 50)
|
||
(vertical-scroll-bars)
|
||
,@(cond ((eq system-type 'gnu/linux)
|
||
'((fullscreen . maximized))))))
|
||
|
||
(setq frame-resize-pixelwise t)
|
||
|
||
(defun center-frame (&optional frame)
|
||
"Center FRAME on the screen."
|
||
(interactive)
|
||
(let ((frame (or frame (selected-frame))))
|
||
(let ((frame-width (frame-pixel-width frame))
|
||
(frame-height (frame-pixel-height frame))
|
||
(display-width (display-pixel-width))
|
||
(display-height (display-pixel-height)))
|
||
(set-frame-position frame
|
||
(/ (- display-width frame-width) 2)
|
||
(/ (- display-height frame-height) 2)))))
|
||
|
||
(add-hook 'after-make-frame-functions #'center-frame)
|
||
|
||
(use-package all-the-icons
|
||
:commands all-the-icons-install-fonts
|
||
:init
|
||
(unless (find-font (font-spec :name "all-the-icons"))
|
||
(all-the-icons-install-fonts t)))
|
||
|
||
(use-package all-the-icons-dired
|
||
:after all-the-icons
|
||
:hook (dired-mode . all-the-icons-dired-mode))
|
||
|
||
(use-package emojify
|
||
:hook (erc-mode . emojify-mode)
|
||
:commands emojify-mode
|
||
:config
|
||
(when (member "Segoe UI Emoji" (font-family-list))
|
||
(set-fontset-font
|
||
t 'symbol (font-spec :family "Segoe UI Emoji") nil 'prepend))
|
||
(setq emojify-display-style 'unicode)
|
||
(setq emojify-emoji-styles '(unicode))
|
||
(bind-key* (kbd "C-c .") #'emojify-insert-emoji))
|
||
|
||
;; (defun my-vc-info ()
|
||
;; (when vc-mode
|
||
;; (concat (substring vc-mode 5)
|
||
;; " ["
|
||
;; (substring (vc-working-revision (buffer-file-name)) 0 8)
|
||
;; "] ")))
|
||
|
||
;; (defun my-project-name ()
|
||
;; (let ((proj (project-current)))
|
||
;; (if proj (file-name-base (directory-file-name (project-root proj)))
|
||
;; "NoProject")))
|
||
|
||
;; (setq-default header-line-format
|
||
;; (list "-%M"
|
||
;; '(:eval (my-project-name)) " "
|
||
;; system-name " " user-login-name " "
|
||
;; "-%-"))
|
||
|
||
;; (setq-default mode-line-format
|
||
;; (list "-%b %*%n %I %l:%c %p "
|
||
;; '(:eval mode-name) " "
|
||
;; '(:eval (my-vc-info))
|
||
;; '(:eval (if mode-line-process (concat ":" mode-line-process " ") ""))
|
||
;; 'default-directory
|
||
;; "-%-"))
|
||
|
||
;; (set-face-attribute 'mode-line nil :weight 'bold)
|
||
;; (set-face-attribute 'header-line nil :weight 'bold)
|
||
|
||
;; (use-package doom-modeline
|
||
;; :hook (after-init . doom-modeline-mode)
|
||
;; :custom
|
||
;; (doom-modeline-height 30)
|
||
;; (doom-modeline-bar-width 4)
|
||
;; (doom-modeline-icon nil)
|
||
;; (doom-modeline-major-mode-icon nil)
|
||
;; (doom-modeline-unicode-fallback nil)
|
||
;; (doom-modeline-minor-modes nil)
|
||
;; (doom-modeline-buffer-encoding nil)
|
||
;; (doom-modeline-battery nil))
|
||
|
||
(use-package helpful
|
||
:commands (helpful-callable helpful-variable helpful-command helpful-key)
|
||
:bind ([remap describe-command] . helpful-command) ([remap describe-key] . helpful-key))
|
||
|
||
(use-package rainbow-delimiters
|
||
:hook (prog-mode . rainbow-delimiters-mode))
|
||
|
||
(use-package olivetti
|
||
:custom (olivetti-body-width 83)
|
||
:bind ("<f6>" . olivetti-mode))
|
||
|
||
(add-hook 'Info-mode-hook
|
||
(lambda ()
|
||
(make-local-variable 'olivetti-body-width)
|
||
(setq olivetti-body-width 75)
|
||
(olivetti-mode)))
|
||
|
||
(use-package ace-window :init (global-set-key (kbd "M-o") 'ace-window))
|
||
|
||
;; (use-package vertico :init (vertico-mode))
|
||
|
||
(use-package webjump
|
||
:bind ("C-c j" . webjump)
|
||
:custom
|
||
(webjump-sites
|
||
(append '(("Wikipedia_de" . [simple-query "de.wikipedia.org" "https://de.wikipedia.org/wiki/" ""])
|
||
("leo.org" . [simple-query "dict.leo.org" "https://dict.leo.org/german-english/" ""]))
|
||
webjump-sample-sites)))
|
||
|
||
(use-package doc-view
|
||
:ensure nil
|
||
:custom
|
||
(doc-view-continuous nil)
|
||
(doc-view-scale-internally nil)
|
||
(doc-view-cache-size 32)
|
||
(doc-view-prefetch-pages t)
|
||
(doc-view-dvipdfm-program "mutool")
|
||
(doc-view-odf->odf-converter-program "soffice")
|
||
(dov-view-odf->pdf-converter-function 'doc-view-odf->pdf-converter-soffice)
|
||
(doc-view-pdf->png-converter-function 'doc-view-pdf->png-converter-mupdf)
|
||
(doc-view-resolution 200))
|
||
|
||
(use-package hideshow
|
||
:hook ((prog-mode . (lambda () (hs-minor-mode 1))))
|
||
:bind (:map prog-mode-map
|
||
("M-<return>" . hs-toggle-hiding))
|
||
:custom
|
||
(hs-allow-nesting t))
|
||
|
||
(add-hook 'prog-mode-hook (lambda () (setq line-spacing 4)))
|
||
|
||
;; (load "bundle--package")
|
||
|
||
(require 'package)
|
||
|
||
(defun get-auth-key (host)
|
||
"Retrieve the Anthropics API key using 'auth-source'."
|
||
(require 'auth-source)
|
||
(let* ((auth-source-creation-prompts
|
||
'((secret . "API key for %u@%h: ")))
|
||
(found (nth 0 (auth-source-search
|
||
:max 1
|
||
:host host
|
||
:user "apikey"
|
||
:require '(:secret)
|
||
:create t)))
|
||
(secret (plist-get found :secret)))
|
||
(if (functionp secret)
|
||
(funcall secret)
|
||
secret)))
|
||
|
||
(use-package htmlize)
|
||
|
||
(use-package time
|
||
:ensure nil
|
||
:config
|
||
(setq world-clock-time-format "%a %d %b %R %Z")
|
||
(setq world-clock-list
|
||
'(("America/Los_Angeles" "Seattle")
|
||
("America/New_York" "New York")
|
||
("Europe/London" "London")
|
||
("Europe/Paris" "Paris")
|
||
("Europe/Sofia" "Sofia")
|
||
("Asia/Calcutta" "Bangalore")
|
||
("Asia/Tokyo" "Tokyo"))))
|
||
|
||
(use-package autoinsert
|
||
:ensure nil
|
||
:init (auto-insert-mode 1)
|
||
:config
|
||
(setq auto-insert-query nil)
|
||
(let ((new-templates
|
||
'((("\\.sh\\'" . "Shell script header") nil "#!/bin/bash\n# -*- mode: shell-script; coding: utf-8; -*-\n")
|
||
(("\\.js\\'" . "JavaScript header") nil "#!/usr/bin/env node\n// -*- mode: js; coding: utf-8; -*-\n")
|
||
(("\\.css\\'" . "CSS header") nil "/* -*- mode: css; coding: utf-8; -*-\n * Dependencies: none\n */\n")
|
||
(("\\.html\\'" . "HTML header") nil "<!-- -*- mode: web; coding: utf-8; -*- -->\n")
|
||
(("\\.lisp\\'" . "Lisp header") nil ";;;; -*- mode: common-lisp; coding: utf-8; -*-\n"))))
|
||
(setq auto-insert-alist (nconc new-templates auto-insert-alist))))
|
||
|
||
(use-package tramp
|
||
:ensure nil
|
||
:config
|
||
(when (eq system-type 'windows-nt)
|
||
(setq tramp-default-method "sshx")))
|
||
|
||
(use-package shr
|
||
:custom
|
||
(shr-use-colors nil)
|
||
(shr-use-fonts nil)
|
||
(shr-inhibit-images t)
|
||
(shr-cookie-policy nil)
|
||
(shr-width nil))
|
||
|
||
(use-package shrface
|
||
:hook ((eww-after-render . shrface-mode)
|
||
(nov-mode . shrface-mode))
|
||
:custom
|
||
(shrface-href-versatile t)
|
||
(shrface-toggle-bullets t)
|
||
:config
|
||
(shrface-basic)
|
||
(shrface-trial)
|
||
(shrface-default-keybindings))
|
||
|
||
(defun hunspell-available-p ()
|
||
"Check if Hunspell is available on the system."
|
||
(cond
|
||
;; Check for Windows
|
||
((eq system-type 'windows-nt)
|
||
(or (executable-find "hunspell.exe")
|
||
(executable-find "hunspell")))
|
||
;; Check for Linux and other Unix-like systems
|
||
((or (eq system-type 'gnu/linux)
|
||
(eq system-type 'darwin)
|
||
(eq system-type 'berkeley-unix))
|
||
(executable-find "hunspell"))
|
||
;; Return nil for unsupported systems
|
||
(t nil)))
|
||
|
||
(when (hunspell-available-p)
|
||
(progn
|
||
(use-package flyspell
|
||
:hook ((LaTeX-mode . flyspell-mode)
|
||
(org-mode . flyspell-mode)
|
||
(text-mode . flyspell-mode)
|
||
(prog-mode . flyspell-prog-mode)))
|
||
|
||
(use-package ispell
|
||
:ensure nil
|
||
:config
|
||
;; On windows: Copy *.aff and *.dic files to C:\msys64\ucrt64\share\hunspell
|
||
;; `hunspell -D`, the program will display the dictionaries and affix files it
|
||
;; finds and loads.
|
||
;; (when (eq system-type 'windows-nt)
|
||
;; (setq ispell-program-name "c:/msys64/ucrt64/bin/hunspell.exe"))
|
||
(setq ispell-program-name "hunspell")
|
||
(setq ispell-dictionary "german,english")
|
||
(setq ispell-local-dictionary-alist
|
||
'(("german" "[[:alpha:]]" "[^[:alpha:]]" "[']" t ("-d" "de_DE_frami,de_AT_frami,de_CH_frami") nil utf-8)
|
||
("english" "[[:alpha:]]" "[^[:alpha:]]" "[']" nil ("-d" "en_US,en_GB") nil utf-8)
|
||
("german,english" "[[:alpha:]]" "[^[:alpha:]]" "[']" nil ("-d" "de_DE_frami,en_US") nil utf-8)))
|
||
(setq ispell-hunspell-dictionary-alist ispell-local-dictionary-alist))))
|
||
|
||
(defun mk/nov-font-settings ()
|
||
(setq-local line-spacing 2))
|
||
|
||
(use-package browse-url
|
||
:custom
|
||
(browse-url-browser-function 'eww-browse-url))
|
||
|
||
(use-package eww
|
||
:config
|
||
(require 'shrface))
|
||
|
||
(use-package nov
|
||
:defer t
|
||
:hook ((nov-mode . visual-line-mode)
|
||
(nov-mode . mk/nov-font-settings))
|
||
:mode ("\\.epub\\'" . nov-mode)
|
||
:custom
|
||
(nov-header-line-format nil)
|
||
(nov-text-width 82)
|
||
(nov-variable-pitch nil)
|
||
:config
|
||
(require 'shrface)
|
||
(setq nov-shr-rendering-functions '((img . nov-render-img) (title . nov-render-title)))
|
||
(setq nov-shr-rendering-functions (append nov-shr-rendering-functions shr-external-rendering-functions)))
|
||
;; (when (eq system-type 'windows-nt)
|
||
;; (setq nov-unzip-program "c:/msys64/usr/bin/unzip.exe")))
|
||
|
||
(use-package eglot
|
||
:hook ((typescript-mode . eglot-ensure)
|
||
(js2-mode . eglot-ensure))
|
||
:config
|
||
(if (eq system-name 'windows-nt)
|
||
;; %USERPROFILE%\AppData\Local\Programs\clangd-windows-17.0.3\clangd_17.0.3\bin
|
||
(add-to-list 'eglot-server-programs '((c++-mode c-mode) "clangd"))
|
||
(add-to-list 'eglot-server-programs '((c++-mode c-mode) "ccls"))))
|
||
|
||
|
||
(use-package sql
|
||
:defer t
|
||
:config
|
||
(setq sql-connection-alist
|
||
'((finance-db
|
||
(sql-product 'sqlite)
|
||
(sql-database "~/Documents/org/data/FINANCE.db"))))
|
||
(when (eq system-type 'windows-nt)
|
||
(setq sql-postgres-program "C:/Program Files/PostgreSQL/16/bin/psql.exe")
|
||
(setq sql-sqlite-options '("-interactive"))
|
||
(setq sql-mariadb-options '("-C" "-t" "-f" "-n"))
|
||
(setq sql-mysql-options '("-C" "-t" "-f" "-n"))))
|
||
|
||
;; (defun me/c-mode-style-hook ()
|
||
;; ;; https://www.gnu.org/prep/standards/html_node/Writing-C.html
|
||
;; ;; if linux kernel source use linux style, else use gnu style
|
||
;; (c-set-style
|
||
;; (if (and (buffer-file-name)
|
||
;; (string-match "/usr/src/linux" (buffer-file-name)))
|
||
;; "linux"
|
||
;; "gnu")))
|
||
|
||
;; (use-package cc-mode
|
||
;; :defer t
|
||
;; :ensure nil
|
||
;; :hook ((c-mode-common . c-toggle-auto-newline)
|
||
;; (c-mode-common . me/c-mode-style-hook))
|
||
;; :custom
|
||
;; (fill-column 79)
|
||
;; (c-basic-offset 2)
|
||
;; (indent-tabs-mode nil)
|
||
;; :config
|
||
;; (define-key c-mode-base-map (kbd "RET") 'newline-and-indent))
|
||
|
||
;; (defun me/c-mode-compile-command-hook ()
|
||
;; ;; if no makefile use gcc for compile command
|
||
;; (unless (or (file-exists-p "makefile")
|
||
;; (file-exists-p "Makefile"))
|
||
;; (set (make-local-variable 'compile-command)
|
||
;; (concat "gcc " "-Wall " "-g " buffer-file-name " -o "
|
||
;; (file-name-sans-extension buffer-file-name)))))
|
||
|
||
;; (add-hook 'c-mode-common-hook 'me/c-mode-compile-command-hook)
|
||
|
||
;; (defun me/c-mode-compile-on-save ()
|
||
;; ;; compile on save hook
|
||
;; (make-local-variable 'after-save-hook)
|
||
;; (add-hook 'after-save-hook (lambda () (compile compile-command))))
|
||
|
||
;; (add-hook 'c-mode-common-hook 'me/c-mode-compile-on-save)
|
||
|
||
;; (use-package js-mode
|
||
;; :ensure nil
|
||
;; :hook (js-mode . eglot-ensure)
|
||
;; :mode (("\\.webmanifest\\'" . js-mode)
|
||
;; ("\\.js\\'" . js-mode)
|
||
;; ("\\.mjs\\'" . js-mode)
|
||
;; ("\\.cjs\\'" . js-mode)))
|
||
|
||
(use-package js2-mode
|
||
:mode
|
||
(("\\.webmanifest\\'" . js2-mode)
|
||
("\\.js\\'" . js2-mode)
|
||
("\\.mjs\\'" . js2-mode)
|
||
("\\.cjs\\'" . js2-mode))
|
||
:config
|
||
(add-to-list 'interpreter-mode-alist '("node" . js2-mode)))
|
||
|
||
;; (use-package go-mode
|
||
;; :defer t
|
||
;; :mode ("\\.go\\'" . go-mode)
|
||
;; :hook ((before-save . gofmt-before-save)
|
||
;; (go-mode . eglot-ensure))
|
||
;; :config
|
||
;; (defun me/go-mode-compile-command-hook ()
|
||
;; ;; if no makefile use go vet for compile command
|
||
;; (unless (or (file-exists-p "makefile")
|
||
;; (file-exists-p "Makefile"))
|
||
;; (set (make-local-variable 'compile-command)
|
||
;; (concat "go " "vet " buffer-file-name))))
|
||
;; (add-hook 'go-mode-hook 'me/go-mode-compile-command-hook)
|
||
;; (defun me/go-mode-compile-on-save ()
|
||
;; ;; compile on save hook
|
||
;; (make-local-variable 'after-save-hook)
|
||
;; (add-hook 'after-save-hook (lambda () (compile compile-command)))))
|
||
;; ;; (add-hook 'go-mode-hook 'me/go-mode-compile-on-save)))
|
||
|
||
(use-package web-mode
|
||
;; :hook html-mode
|
||
:mode (("\\.html?\\'" . web-mode)
|
||
("\\.xhtml?\\'" . web-mode)
|
||
("\\.tmpl\\'" . web-mode)
|
||
("\\.hbs\\'" . web-mode)
|
||
("\\.handlebars\\'" . web-mode))
|
||
:custom
|
||
(web-mode-markup-indent-offset 2)
|
||
(web-mode-css-indent-offset 2)
|
||
(web-mode-code-indent-offset 2)
|
||
(web-mode-enable-auto-pairing nil)
|
||
(web-mode-enable-auto-closing t)
|
||
(web-mode-enable-current-element-highlight t)
|
||
(web-mode-enable-current-column-highlight t))
|
||
|
||
(use-package python
|
||
:mode (("\\.py\\'" . python-mode)
|
||
("\\.wsgi$" . python-mode)
|
||
("\\.j2" . python-mode))
|
||
:hook (python-mode . abbrev-mode)
|
||
:init
|
||
(setq python-interpreter
|
||
(cond ((executable-find "python3") "python3")
|
||
((executable-find "python") "python")
|
||
(t "python3")))
|
||
(setq python-indent-guess-indent-offset nil)
|
||
(setq python-indent-offset 4)
|
||
(setq python-shell-interpreter "ipython")
|
||
(setq python-shell-interpreter-args "-i --simple-prompt --InteractiveShell.display_page=True")
|
||
:custom
|
||
(fill-column 79))
|
||
|
||
;; (use-package simple-httpd
|
||
;; :defer t)
|
||
|
||
(use-package go-translate
|
||
:bind (("C-c t" . gt-do-translate))
|
||
:config
|
||
(setq gt-polyglot-p t)
|
||
(setq gt-langs '(en de fr it es))
|
||
(setq gt-default-translator
|
||
(gt-translator
|
||
:taker (gt-taker :langs '(en fr de it es) :text 'paragaph :pick nil)
|
||
:engines (list (gt-bing-engine) (gt-google-engine))
|
||
:render (gt-buffer-render))))
|
||
|
||
(use-package magit
|
||
:defer t
|
||
:bind ("C-x g" . magit-status)
|
||
:init
|
||
(when (eq system-type 'windows-nt)
|
||
(setq magit-git-executable "C:/Program Files/Git/mingw64/libexec/git-core/git.exe"))
|
||
:custom
|
||
(magit-diff-refine-hunk 'all)
|
||
(magit-display-buffer-function 'magit-display-buffer-fullcolumn-most-v1)
|
||
(magit-ediff-dwim-show-on-hunks t)
|
||
(magit-log-arguments '("--graph" "--color" "--decorate" "--show-signature" "--follow" "-n256"))
|
||
(magit-log-margin-show-committer-date t)
|
||
(magit-log-remove-graph-args '("--follow" "--grep" "-G" "-S" "-L"))
|
||
(magit-todos-insert-after '(bottom))
|
||
:config
|
||
(global-set-key (kbd "C-x M-g") 'magit-dispatch))
|
||
|
||
(use-package yaml-mode
|
||
:mode "\\.yml\\'"
|
||
:hook
|
||
(yaml-mode . (lambda () (auto-fill-mode -1))))
|
||
|
||
(use-package csv-mode
|
||
:mode "\\.csv\\'")
|
||
|
||
(use-package markdown-mode
|
||
:mode "\\.md\\'")
|
||
|
||
;; (use-package typescript-mode
|
||
;; :defer t
|
||
;; :mode "\\.ts\\'"
|
||
;; :hook (typescript-mode . eglot-ensure)
|
||
;; :config (setq typescript-indent-level 2))
|
||
|
||
(when (eq system-type 'gnu/linux)
|
||
(use-package spotify
|
||
:bind ("S-<pause>" . spotify-playpause)))
|
||
|
||
(use-package mastodon
|
||
:defer t
|
||
:custom
|
||
(mastodon-instance-url "https://emacs.ch")
|
||
(mastodon-active-user "qhBidG3d"))
|
||
|
||
(use-package jabber
|
||
:defer t
|
||
:bind (("C-x j c" . jabber-connect)
|
||
("C-x j d" . jabber-disconnect))
|
||
:init
|
||
(setq jabber-activity-mode nil)
|
||
(setq jabber-account-list '(("marcus.kammer@mailbox.org")))
|
||
:custom
|
||
(jabber-muc-decorate-presence-patterns
|
||
'(("enters the room" . nil)
|
||
("has entered the room" . nil)
|
||
("joined the room" . nil)
|
||
("has left the chatroom" . nil)))
|
||
(jabber-muc-autojoin
|
||
'("lisp@conference.a3.pm"
|
||
"emacs@conference.conversations.im"
|
||
"community@conference.jabber.fsfe.org"
|
||
"ml-survey@conference.mailbox.org"
|
||
"userexperience@conference.mailbox.org"))
|
||
(jabber-muc-default-nicknames
|
||
'(("lisp@conference.a3.pm" . "marcus")
|
||
("emacs@conference.conversations.im" . "marcus")
|
||
("ml-survey@conference.mailbox.org" . "marcus")
|
||
("userexperience@conference.mailbox.org" . "marcus"))))
|
||
|
||
;; (use-package hyperbole
|
||
;; :config
|
||
;; (setq hyrolo-date-format "%Y-%m-%d %H:%M:%S")
|
||
;; (add-hook 'hyperbole-init-hook
|
||
;; (lambda ()
|
||
;; (setq hyrolo-file-list
|
||
;; (append (hyrolo-initialize-file-list)
|
||
;; (cons "~/.rolo.otl"
|
||
;; (directory-files-recursively org-directory (rx "." (or "org" "otl") eos))))))))
|
||
|
||
(use-package plantuml-mode
|
||
:mode ("\\.puml\\'" "\\.plantuml\\'")
|
||
:custom
|
||
(plantuml-default-exec-mode 'jar)
|
||
(plantuml-jar-path "~/plantuml.jar")
|
||
(org-plantuml-jar-path "~/plantuml.jar")
|
||
(plantuml-java-args '("-DPLANTUML_DPI=300" "-Djava.awt.headless=true" "-jar" "--illegal-access=deny")))
|
||
|
||
(use-package tex-mode
|
||
:defer t
|
||
:ensure auctex
|
||
:config
|
||
;; TeX mode settings for editing .tex files
|
||
(setq TeX-auto-save t) ; Enable auto-save
|
||
(setq TeX-electric-math (cons "$" "$")) ; Shortcut for math mode
|
||
(if (eq system-type 'windows-nt)
|
||
(progn
|
||
(setq TeX-view-program-list '(("SumatraPDF" "~/AppData/Local/SumatraPDF/SumatraPDF.exe %o")))
|
||
(setq TeX-view-program-selection '((output-pdf "SumatraPDF"))))
|
||
(setq TeX-view-program-selection '((output-pdf "Evince"))))
|
||
(setq TeX-source-correlate-start-server t) ; Enable source-correlate
|
||
(setq TeX-master nil) ; Default master file
|
||
(setq TeX-engine 'luatex) ; Set engine to XeTeX
|
||
(setq TeX-command-extra-options "-shell-escape")) ; Allow shell escape
|
||
|
||
(use-package auctex
|
||
:hook ((LaTeX-mode . turn-on-reftex)
|
||
(LaTeX-mode . LaTeX-math-mode))
|
||
:custom
|
||
(LaTeX-indent-level 4)
|
||
(LaTeX-item-indent 0))
|
||
|
||
(use-package epg
|
||
:ensure nil
|
||
:config
|
||
(when (eq system-type 'windows-nt)
|
||
(setq epg-gpg-home-directory "~/AppData/Roaming/gnupg"
|
||
epg-gpg-program "c:/Program Files (x86)/GnuPG/bin/gpg.exe"
|
||
epg-gpgconf-program "c:/Program Files (x86)/GnuPG/bin/gpgconf.exe")))
|
||
|
||
(use-package which-key
|
||
:init (which-key-mode))
|
||
|
||
(use-package ssh-config-mode
|
||
:mode ("/sshd_config\\'" . ssh-config-mode)
|
||
:config
|
||
(add-hook 'ssh-config-mode-hook 'turn-on-font-lock))
|
||
|
||
(use-package nginx-mode
|
||
:mode ("/nginx/.*\\'" . nginx-mode))
|
||
|
||
(use-package dashboard
|
||
:config
|
||
(dashboard-setup-startup-hook))
|
||
|
||
;; (use-package flymake-json)
|
||
|
||
;; (use-package json-mode
|
||
;; :ensure nil
|
||
;; :mode "\\.json\\'"
|
||
;; :hook (json-mode . flymake-json-load))
|
||
|
||
;; (use-package json-navigator
|
||
;; :defer t
|
||
;; :after json-mode)
|
||
|
||
;; (use-package jq-format
|
||
;; :defer t
|
||
;; :after json-mode)
|
||
|
||
(use-package gptel
|
||
:bind (("C-c g" . gptel-menu)
|
||
("C-c G" . gptel)
|
||
("C-c M-g" . gptel-send)
|
||
:map gptel-mode-map
|
||
("C-c C-c" . gptel-send)
|
||
("C-c C-k" . gptel-abort))
|
||
:config
|
||
(when (eq system-type 'windows-nt)
|
||
(setq gptel-use-curl nil))
|
||
(setq gptel-prompt-prefix-alist
|
||
'((markdown-mode . "# ")
|
||
(org-mode . "* ")
|
||
(text-mode . "# ")))
|
||
(setq gptel-default-mode 'org-mode)
|
||
(setq gptel-model "claude-3-5-sonnet-20240620")
|
||
(setq gptel-backend (gptel-make-anthropic "Claude" :stream t :key gptel-api-key))
|
||
(setq gptel-directives
|
||
'((default . "You are an expert Common Lisp developer specializing in web development with Hunchentoot and functional programming. Emphasize functional programming principles throughout, including pure functions, immutability, and higher-order functions. Provide concise code examples and best practices for each topic. You are using the following common lisp libraries: spinneret for html generation, hunchentoot as web server, and mito as ORM. If needed choose more libraries for different cases.")
|
||
(bash . "You are an experienced Bash scripting teacher. I want to learn how to write Bash scripts. Please explain concepts clearly, provide examples, and guide me through writing scripts step-by-step. Let's start with the basics and gradually move to more advanced topics. If I have questions or need further clarification, help me understand the material thoroughly.")
|
||
(cs-teacher . "You are a virtual teaching assistant for a high school computer science course. The course focuses on functional programming, data structures, and algorithms using Common Lisp. Your goal is to provide clear, engaging, and educational explanations, examples, and exercises to help students grasp complex concepts. Your responses should be appropriate for high school students, keeping explanations simple yet thorough.")
|
||
(statistic-teacher . "You are a virtual teaching assistant for a high school statistic and math course. The course focuses on statistics. Your goal is to provide clear, engaging, and educational explanations, examples, and exercises to help students grasp complex concepts. Your responses should be appropriate for high school students, keeping explanations simple yet thorough. Apply the theoretical concepts you are explaining to the field of user experience and usability and provide short examples.")
|
||
(cl-stats . "You are a high school math teacher specializing in teaching statistics. Your students are new to the subject and are eager to learn through clear, step-by-step explanations. Use simple language and real-world examples to make complex statistical concepts understandable. Focus on breaking down key ideas like mean, median, mode, standard deviation, probability, and hypothesis testing. Additionally, when providing coding examples, use Common Lisp with an emphasis on functional programming techniques. Ensure that the code is well-commented and easy for beginners to follow. Introduce students to basic functional programming concepts such as higher-order functions, recursion, and immutability within the context of statistical problems. Make sure to: Start with basic concepts and gradually progress to more advanced topics. Include practical examples and exercises that students can try on their own. Encourage critical thinking and exploration by posing questions and challenges related to the statistical material. Use functional programming principles when writing Common Lisp code, explaining how these principles apply to the statistical problem at hand. Be patient, encouraging, and supportive, as you would be in a real classroom."))))
|
||
|
||
(use-package gnuplot
|
||
:defer t)
|
||
|
||
(use-package docker)
|
||
|
||
(use-package dockerfile-mode
|
||
:mode ("\\.dockerfile\\'" . dockerfile-mode))
|
||
|
||
(use-package terraform-mode
|
||
:defer t
|
||
:custom
|
||
(terraform-format-on-save t))
|
||
|
||
;; (load "bundle--lisp")
|
||
|
||
(defvar mk/hyperspec-dir-locations
|
||
'("~/cl-sites/HyperSpec-7-0/HyperSpec/"
|
||
"~/HyperSpec-7-0/HyperSpec/")
|
||
"List of possible locations where the local HyperSpec could reside.")
|
||
|
||
(defun mk/hyperspec-dir ()
|
||
"Finds and returns the URI of the local HyperSpec directory.
|
||
Uses `mk/hyperspec-dir-locations' to find the directory."
|
||
(let ((dir (seq-find 'file-directory-p mk/hyperspec-dir-locations)))
|
||
(if dir
|
||
(concat "file://" (and (eq system-type 'windows-nt) "/") (expand-file-name dir))
|
||
nil)))
|
||
|
||
(setq common-lisp-hyperspec-root (mk/hyperspec-dir))
|
||
|
||
(use-package slime
|
||
:custom
|
||
(slime-autodoc-use-multiline-p 1)
|
||
:config
|
||
(define-key slime-mode-map (kbd "C-c C-q") 'slime-close-all-parens-in-sexp)
|
||
(slime-setup '(slime-autodoc
|
||
slime-tramp
|
||
slime-fancy
|
||
slime-asdf
|
||
slime-indentation
|
||
slime-editing-commands
|
||
slime-sbcl-exts))
|
||
|
||
;; To create a slime specific sbcl image:
|
||
;; shell$ sbcl
|
||
;; * (mapc 'require '(sb-bsd-sockets sb-posix sb-introspect sb-cltl2 asdf))
|
||
;; * (save-lisp-and-die "sbcl.core-for-slime")
|
||
|
||
;; Stop SLIME's REPL from grabbing DEL,
|
||
;; which is annoying when backspacing over a '('
|
||
|
||
;; (defun override-slime-repl-bindings-with-paredit ()
|
||
;; (define-key slime-repl-mode-map
|
||
;; (read-kbd-macro paredit-backward-delete-key) nil))
|
||
|
||
;; (add-hook 'slime-repl-mode-hook 'override-slime-repl-bindings-with-paredit)
|
||
|
||
(setq common-lisp-hyperspec-symbol-table
|
||
(concat common-lisp-hyperspec-root "Data/Map_Sym.txt"))
|
||
|
||
(setq common-lisp-hyperspec-issuex-table
|
||
(concat common-lisp-hyperspec-root "Data/Map_IssX.txt"))
|
||
|
||
(let ((image-path (expand-file-name "~/sbcl.core-for-slime")))
|
||
(if (file-exists-p image-path)
|
||
(setq slime-lisp-implementations
|
||
`((sbcl ("sbcl" "--noinform" "--core" ,image-path) :coding-system utf-8-unix)))
|
||
(setq slime-lisp-implementations
|
||
`((sbcl ("sbcl" "--noinform") :coding-system utf-8-unix)))))
|
||
|
||
(defvar mk/slime-remote-instances
|
||
'((:machine-instance "survey-metalisp"
|
||
:remote-host "survey.metalisp.dev"
|
||
:username "cl")
|
||
(:machine-instance "u1-marcsukammer"
|
||
:remote-host "u1.marcsukammer.dev"
|
||
:username "marcus")))
|
||
|
||
(mapc (lambda (instance)
|
||
(push (slime-create-filename-translator
|
||
:machine-instance (plist-get instance :machine-instance)
|
||
:remote-host (plist-get instance :remote-host)
|
||
:username (plist-get instance :username))
|
||
slime-filename-translations))
|
||
mk/slime-remote-instances)
|
||
|
||
;; syntax highlighting
|
||
(defvar slime-repl-font-lock-keywords lisp-font-lock-keywords-2)
|
||
|
||
(defun slime-repl-font-lock-setup ()
|
||
(setq font-lock-defaults
|
||
'(slime-repl-font-lock-keywords
|
||
;; From lisp-mode.el
|
||
nil nil (("+-*/.<>=!?$%_&~^:@" . "w")) nil
|
||
(font-lock-syntactic-face-function . lisp-font-lock-syntactic-face-function))))
|
||
|
||
(add-hook 'slime-repl-mode-hook 'slime-repl-font-lock-setup)
|
||
|
||
(defadvice slime-repl-insert-prompt (after font-lock-face activate)
|
||
(let ((inhibit-read-only t))
|
||
(add-text-properties
|
||
slime-repl-prompt-start-mark (point)
|
||
'(font-lock-face
|
||
slime-repl-prompt-face
|
||
rear-nonsticky
|
||
(slime-repl-prompt read-only font-lock-face intangible))))))
|
||
|
||
(use-package elisp-mode
|
||
:ensure nil
|
||
:hook ((emacs-lisp-mode . prettify-symbols-mode)
|
||
(emacs-lisp-mode . (lambda ()
|
||
(face-remap-add-relative 'font-lock-function-name-face nil :underline t)
|
||
(face-remap-add-relative 'font-lock-keyword-face nil :slant 'italic))))
|
||
:mode (("\\.el$" . emacs-lisp-mode))
|
||
:config
|
||
(setq-local lisp-indent-function 'lisp-indent-function)
|
||
(setq-local fill-column 84))
|
||
|
||
(use-package lisp-mode
|
||
:ensure nil
|
||
:hook ((lisp-mode . (lambda ()
|
||
(face-remap-add-relative 'font-lock-function-name-face nil :underline t)
|
||
(face-remap-add-relative 'font-lock-keyword-face nil :slant 'italic))))
|
||
:mode (("\\.lisp$" . lisp-mode)
|
||
("\\.lsp$" . lisp-mode)
|
||
("\\.cl$" . lisp-mode))
|
||
:init
|
||
(setq inferior-lisp-program "sbcl --noinform")
|
||
|
||
:config
|
||
(setq-local lisp-indent-function 'common-lisp-indent-function)
|
||
(setq-local fill-column 84)
|
||
(defvar g-cl-function-names
|
||
'("*" "+" "-" "/" "/=" "1+" "1-" "<" "<=" "=" ">"
|
||
">=" "abort" "abs" "acons" "acos" "acosh" "add-method" "adjoin"
|
||
"adjust-array" "adjustable-array-p" "allocate-instance" "alpha-char-p"
|
||
"alphanumericp" "and" "append" "apply" "apropos" "apropos-list" "aref"
|
||
"arithmetic-error-operands" "arithmetic-error-operation" "array-dimension"
|
||
"array-dimensions" "array-displacement" "array-element-type"
|
||
"array-has-fill-pointer-p" "array-in-bounds-p" "array-rank"
|
||
"array-row-major-index" "array-total-size" "arrayp" "ash" "asin" "asinh"
|
||
"assert" "assoc" "assoc-if" "assoc-if-not" "atan" "atanh" "atom" "bit"
|
||
"bit-and" "bit-andc1" "bit-andc2" "bit-eqv" "bit-ior" "bit-nand" "bit-nor"
|
||
"bit-not" "bit-orc1" "bit-orc2" "bit-vector-p" "bit-xor" "block" "boole"
|
||
"both-case-p" "boundp" "break" "broadcast-stream-streams" "butlast" "byte"
|
||
"byte-position" "byte-size" "caaaar" "caaadr" "caaar" "caadar" "caaddr"
|
||
"caadr" "caar" "cadaar" "cadadr" "cadar" "caddar" "cadddr" "caddr" "cadr"
|
||
"call-method" "car" "case" "catch" "ccase" "cdaaar" "cdaadr" "cdaar"
|
||
"cdadar" "cdaddr" "cdadr" "cdar" "cddaar" "cddadr" "cddar" "cdddar" "cddddr"
|
||
"cdddr" "cddr" "cdr" "ceiling" "cell-error-name" "cerror" "change-class"
|
||
"char" "char-code" "char-downcase" "char-equal" "char-greaterp" "char-int"
|
||
"char-lessp" "char-name" "char-not-equal" "char-not-greaterp"
|
||
"char-not-lessp" "char-upcase" "char/=" "char<" "char<=" "char=" "char>"
|
||
"char>=" "character" "characterp" "check-type" "cis" "class-name" "class-of"
|
||
"clear-input" "clear-output" "close" "clrhash" "code-char" "coerce"
|
||
"compile" "compile-file" "compile-file-pathname" "compiled-function-p"
|
||
"compiler-macro-function" "complement" "complex" "complexp"
|
||
"compute-applicable-methods" "compute-restarts" "concatenate"
|
||
"concatenated-stream-streams" "cond" "conjugate" "cons" "consp" "constantly"
|
||
"constantp" "continue" "copy-alist" "copy-list" "copy-pprint-dispatch"
|
||
"copy-readtable" "copy-seq" "copy-structure" "copy-symbol" "copy-tree" "cos"
|
||
"cosh" "count" "count-if" "count-if-not" "ctypecase" "decf" "declaim"
|
||
"decode-float" "decode-universal-time" "defclass" "defconstant" "defgeneric"
|
||
"define-compiler-macro" "define-condition" "define-method-combination"
|
||
"define-modify-macro" "define-setf-expander" "define-symbol-macro"
|
||
"defmacro" "defmethod" "defpackage" "defparameter" "defsetf" "defstruct"
|
||
"deftype" "defun" "defvar" "delete" "delete-duplicates" "delete-file"
|
||
"delete-if" "delete-if-not" "delete-package" "denominator" "deposit-field"
|
||
"describe" "describe-object" "destructuring-bind" "digit-char"
|
||
"digit-char-p" "directory" "directory-namestring" "disassemble" "do" "do*"
|
||
"do-all-symbols" "do-external-symbols" "do-symbols" "documentation" "dolist"
|
||
"dotimes" "dpb" "dribble" "ecase" "echo-stream-input-stream"
|
||
"echo-stream-output-stream" "ed" "eighth" "elt" "encode-universal-time"
|
||
"endp" "enough-namestring" "ensure-directories-exist"
|
||
"ensure-generic-function" "eq" "eql" "equal" "equalp" "error" "etypecase"
|
||
"eval" "eval-when" "evenp" "every" "exp" "export" "expt" "fboundp"
|
||
"fceiling" "fdefinition" "ffloor" "fifth" "file-author"
|
||
"file-error-pathname" "file-length" "file-namestring" "file-position"
|
||
"file-string-length" "file-write-date" "fill" "fill-pointer" "find"
|
||
"find-all-symbols" "find-class" "find-if" "find-if-not" "find-method"
|
||
"find-package" "find-restart" "find-symbol" "finish-output" "first" "flet"
|
||
"float" "float-digits" "float-precision" "float-radix" "float-sign" "floatp"
|
||
"floor" "fmakunbound" "force-output" "format" "formatter" "fourth"
|
||
"fresh-line" "fround" "ftruncate" "funcall" "function" "function-keywords"
|
||
"function-lambda-expression" "functionp" "gcd" "gensym" "gentemp" "get"
|
||
"get-decoded-time" "get-dispatch-macro-character" "get-internal-real-time"
|
||
"get-internal-run-time" "get-macro-character" "get-output-stream-string"
|
||
"get-properties" "get-setf-expansion" "get-universal-time" "getf" "gethash"
|
||
"go" "graphic-char-p" "handler-bind" "handler-case" "hash-table-count"
|
||
"hash-table-p" "hash-table-rehash-size" "hash-table-rehash-threshold"
|
||
"hash-table-size" "hash-table-test" "host-namestring" "identity" "if"
|
||
"ignore-errors" "imagpart" "import" "in-package" "incf"
|
||
"initialize-instance" "input-stream-p" "inspect" "integer-decode-float"
|
||
"integer-length" "integerp" "interactive-stream-p" "intern" "intersection"
|
||
"invalid-method-error" "invoke-debugger" "invoke-restart"
|
||
"invoke-restart-interactively" "isqrt" "keywordp" "labels" "lambda" "last"
|
||
"lcm" "ldb" "ldb-test" "ldiff" "length" "let" "let*"
|
||
"lisp-implementation-type" "lisp-implementation-version" "list" "list*"
|
||
"list-all-packages" "list-length" "listen" "listp" "load"
|
||
"load-logical-pathname-translations" "load-time-value" "locally" "log"
|
||
"logand" "logandc1" "logandc2" "logbitp" "logcount" "logeqv"
|
||
"logical-pathname" "logical-pathname-translations" "logior" "lognand"
|
||
"lognor" "lognot" "logorc1" "logorc2" "logtest" "logxor" "long-site-name"
|
||
"loop" "loop-finish" "lower-case-p" "machine-instance" "machine-type"
|
||
"machine-version" "macro-function" "macroexpand" "macroexpand-1" "macrolet"
|
||
"make-array" "make-broadcast-stream" "make-concatenated-stream"
|
||
"make-condition" "make-dispatch-macro-character" "make-echo-stream"
|
||
"make-hash-table" "make-instance" "make-instances-obsolete" "make-list"
|
||
"make-load-form" "make-load-form-saving-slots" "make-package"
|
||
"make-pathname" "make-random-state" "make-sequence" "make-string"
|
||
"make-string-input-stream" "make-string-output-stream" "make-symbol"
|
||
"make-synonym-stream" "make-two-way-stream" "makunbound" "map" "map-into"
|
||
"mapc" "mapcan" "mapcar" "mapcon" "maphash" "mapl" "maplist" "mask-field"
|
||
"max" "member" "member-if" "member-if-not" "merge" "merge-pathnames"
|
||
"method-combination-error" "method-qualifiers" "min" "minusp" "mismatch"
|
||
"mod" "muffle-warning" "multiple-value-bind" "multiple-value-call"
|
||
"multiple-value-list" "multiple-value-prog1" "multiple-value-setq"
|
||
"name-char" "namestring" "nbutlast" "nconc" "nintersection" "ninth"
|
||
"no-applicable-method" "no-next-method" "not" "notany" "notevery" "nreconc"
|
||
"nreverse" "nset-difference" "nset-exclusive-or" "nstring-capitalize"
|
||
"nstring-downcase" "nstring-upcase" "nsublis" "nsubst" "nsubst-if"
|
||
"nsubst-if-not" "nsubstitute" "nsubstitute-if" "nsubstitute-if-not" "nth"
|
||
"nth-value" "nthcdr" "null" "numberp" "numerator" "nunion" "oddp" "open"
|
||
"open-stream-p" "or" "output-stream-p" "package-error-package"
|
||
"package-name" "package-nicknames" "package-shadowing-symbols"
|
||
"package-use-list" "package-used-by-list" "packagep" "pairlis"
|
||
"parse-integer" "parse-namestring" "pathname" "pathname-device"
|
||
"pathname-directory" "pathname-host" "pathname-match-p" "pathname-name"
|
||
"pathname-type" "pathname-version" "pathnamep" "peek-char" "phase" "plusp"
|
||
"pop" "position" "position-if" "position-if-not" "pprint" "pprint-dispatch"
|
||
"pprint-exit-if-list-exhausted" "pprint-fill" "pprint-indent"
|
||
"pprint-linear" "pprint-logical-block" "pprint-newline" "pprint-pop"
|
||
"pprint-tab" "pprint-tabular" "prin1" "prin1-to-string" "princ"
|
||
"princ-to-string" "print" "print-not-readable-object" "print-object"
|
||
"print-unreadable-object" "probe-file" "proclaim" "prog" "prog*" "prog1"
|
||
"prog2" "progn" "progv" "provide" "psetf" "psetq" "push" "pushnew" "quote"
|
||
"random" "random-state-p" "rassoc" "rassoc-if" "rassoc-if-not" "rational"
|
||
"rationalize" "rationalp" "read" "read-byte" "read-char" "read-char-no-hang"
|
||
"read-delimited-list" "read-from-string" "read-line"
|
||
"read-preserving-whitespace" "read-sequence" "readtable-case" "readtablep"
|
||
"realp" "realpart" "reduce" "reinitialize-instance" "rem" "remf" "remhash"
|
||
"remove" "remove-duplicates" "remove-if" "remove-if-not" "remove-method"
|
||
"remprop" "rename-file" "rename-package" "replace" "require" "rest"
|
||
"restart-bind" "restart-case" "restart-name" "return" "return-from"
|
||
"revappend" "reverse" "room" "rotatef" "round" "row-major-aref" "rplaca"
|
||
"rplacd" "sbit" "scale-float" "schar" "search" "second" "set"
|
||
"set-difference" "set-dispatch-macro-character" "set-exclusive-or"
|
||
"set-macro-character" "set-pprint-dispatch" "set-syntax-from-char" "setf"
|
||
"setq" "seventh" "shadow" "shadowing-import" "shared-initialize" "shiftf"
|
||
"short-site-name" "signal" "signum" "simple-bit-vector-p"
|
||
"simple-condition-format-arguments" "simple-condition-format-control"
|
||
"simple-string-p" "simple-vector-p" "sin" "sinh" "sixth" "sleep"
|
||
"slot-boundp" "slot-exists-p" "slot-makunbound" "slot-missing"
|
||
"slot-unbound" "slot-value" "software-type" "software-version" "some" "sort"
|
||
"special-operator-p" "sqrt" "stable-sort" "standard-char-p" "step"
|
||
"store-value" "stream-element-type" "stream-error-stream"
|
||
"stream-external-format" "streamp" "string" "string-capitalize"
|
||
"string-downcase" "string-equal" "string-greaterp" "string-left-trim"
|
||
"string-lessp" "string-not-equal" "string-not-greaterp" "string-not-lessp"
|
||
"string-right-trim" "string-trim" "string-upcase" "string/=" "string<"
|
||
"string<=" "string=" "string>" "string>=" "stringp" "sublis" "subseq"
|
||
"subsetp" "subst" "subst-if" "subst-if-not" "substitute" "substitute-if"
|
||
"substitute-if-not" "subtypep" "svref" "sxhash" "symbol-function"
|
||
"symbol-macrolet" "symbol-name" "symbol-package" "symbol-plist"
|
||
"symbol-value" "symbolp" "synonym-stream-symbol" "tagbody" "tailp" "tan"
|
||
"tanh" "tenth" "terpri" "the" "third" "throw" "time" "trace"
|
||
"translate-logical-pathname" "translate-pathname" "tree-equal" "truename"
|
||
"truncate" "two-way-stream-input-stream" "two-way-stream-output-stream"
|
||
"type-error-datum" "type-error-expected-type" "type-of" "typecase" "typep"
|
||
"unbound-slot-instance" "unexport" "unintern" "union" "unless" "unread-char"
|
||
"untrace" "unuse-package" "unwind-protect"
|
||
"update-instance-for-different-class" "update-instance-for-redefined-class"
|
||
"upgraded-array-element-type" "upgraded-complex-part-type" "upper-case-p"
|
||
"use-package" "use-value" "user-homedir-pathname" "values" "values-list"
|
||
"vector" "vector-pop" "vector-push" "vector-push-extend" "vectorp" "warn"
|
||
"when" "wild-pathname-p" "with-accessors" "with-compilation-unit"
|
||
"with-condition-restarts" "with-hash-table-iterator"
|
||
"with-input-from-string" "with-open-file" "with-open-stream"
|
||
"with-output-to-string" "with-package-iterator" "with-simple-restart"
|
||
"with-slots" "with-standard-io-syntax" "write" "write-byte" "write-char"
|
||
"write-line" "write-sequence" "write-string" "write-to-string" "y-or-n-p"
|
||
"yes-or-no-p" "zerop"))
|
||
(defvar g-cl-value-names
|
||
'("*" "**" "***" "*break-on-signals*"
|
||
"*compile-file-pathname*" "*compile-file-truename*" "*compile-print*"
|
||
"*compile-verbose*" "*debug-io*" "*debugger-hook*"
|
||
"*default-pathname-defaults*" "*error-output*" "*features*"
|
||
"*gensym-counter*" "*load-pathname*" "*load-print*" "*load-truename*"
|
||
"*load-verbose*" "*macroexpand-hook*" "*modules*" "*package*"
|
||
"*print-array*" "*print-base*" "*print-case*" "*print-circle*"
|
||
"*print-escape*" "*print-gensym*" "*print-length*" "*print-level*"
|
||
"*print-lines*" "*print-miser-width*" "*print-pprint-dispatch*"
|
||
"*print-pretty*" "*print-radix*" "*print-readably*" "*print-right-margin*"
|
||
"*query-io*" "*random-state*" "*read-base*" "*read-default-float-format*"
|
||
"*read-eval*" "*read-suppress*" "*readtable*" "*standard-input*"
|
||
"*standard-output*" "*terminal-io*" "*trace-output*" "+" "++" "+++" "-" "/"
|
||
"//" "///" "array-dimension-limit" "array-rank-limit"
|
||
"array-total-size-limit" "boole-1" "boole-2" "boole-and" "boole-andc1"
|
||
"boole-andc2" "boole-c1" "boole-c2" "boole-clr" "boole-eqv" "boole-ior"
|
||
"boole-nand" "boole-nor" "boole-orc1" "boole-orc2" "boole-set" "boole-xor"
|
||
"call-arguments-limit" "char-code-limit" "double-float-epsilon"
|
||
"double-float-negative-epsilon" "internal-time-units-per-second"
|
||
"lambda-list-keywords" "lambda-parameters-limit"
|
||
"least-negative-double-float" "least-negative-long-float"
|
||
"least-negative-normalized-double-float"
|
||
"least-negative-normalized-long-float"
|
||
"least-negative-normalized-short-float"
|
||
"least-negative-normalized-single-float" "least-negative-short-float"
|
||
"least-negative-single-float" "least-positive-double-float"
|
||
"least-positive-long-float" "least-positive-normalized-double-float"
|
||
"least-positive-normalized-long-float"
|
||
"least-positive-normalized-short-float"
|
||
"least-positive-normalized-single-float" "least-positive-short-float"
|
||
"least-positive-single-float" "long-float-epsilon"
|
||
"long-float-negative-epsilon" "most-negative-double-float"
|
||
"most-negative-fixnum" "most-negative-long-float"
|
||
"most-negative-short-float" "most-negative-single-float"
|
||
"most-positive-double-float" "most-positive-fixnum"
|
||
"most-positive-long-float" "most-positive-short-float"
|
||
"most-positive-single-float" "multiple-values-limit" "nil" "pi"
|
||
"short-float-epsilon" "short-float-negative-epsilon" "single-float-epsilon"
|
||
"single-float-negative-epsilon" "t"))
|
||
(defface g-cl-character-face
|
||
'((default :inherit font-lock-constant-face))
|
||
"The face used to highlight Common Lisp character literals.")
|
||
(defface g-cl-standard-function-face
|
||
'((default :inherit font-lock-keyword-face))
|
||
"The face used to highlight standard Common Lisp function symbols.")
|
||
(defface g-cl-standard-value-face
|
||
'((default :inherit font-lock-variable-name-face))
|
||
"The face used to highlight standard Common Lisp value symbols.")
|
||
(defvar g-cl-font-lock-keywords
|
||
(let* ((character-re (concat "#\\\\" lisp-mode-symbol-regexp "\\_>"))
|
||
(function-re (concat "(" (regexp-opt g-cl-function-names t) "\\_>"))
|
||
(value-re (regexp-opt g-cl-value-names 'symbols)))
|
||
`((,character-re . 'g-cl-character-face)
|
||
(,function-re
|
||
(1 'g-cl-standard-function-face))
|
||
(,value-re . 'g-cl-standard-value-face))))
|
||
(defvar g-cl-font-lock-defaults
|
||
'((g-cl-font-lock-keywords)
|
||
nil ; enable syntaxic highlighting
|
||
t ; case insensitive highlighting
|
||
nil ; use the lisp-mode syntax table
|
||
(font-lock-mark-block-function . mark-defun)
|
||
(font-lock-extra-managed-props help-echo)
|
||
(font-lock-syntactic-face-function
|
||
. lisp-font-lock-syntactic-face-function)))
|
||
|
||
(defun g-init-lisp-font-lock ()
|
||
(setq font-lock-defaults g-cl-font-lock-defaults))
|
||
|
||
(add-hook 'lisp-mode-hook 'g-init-lisp-font-lock))
|
||
|
||
(when (eq system-type 'gnu/linux)
|
||
(use-package geiser
|
||
:init
|
||
(setq geiser-repl-prompt-read-only t)
|
||
(setq geiser-repl-highlight-error-messages t)
|
||
(setq geiser-active-implementations '(racket guile))
|
||
(setq geiser-default-implementation 'guile)
|
||
:hook (scheme-mode . geiser-mode)))
|
||
|
||
;; (use-package racket-mode
|
||
;; :mode "\\.rkt\\'")
|
||
|
||
;; (use-package geiser-racket
|
||
;; :defer t
|
||
;; :after geiser
|
||
;; :config
|
||
;; (when (eq system-type 'windows-nt)
|
||
;; (setq geiser-racket-binary "c:/Program Files/Racket/Racket.exe")))
|
||
|
||
(when (eq system-type 'gnu/linux)
|
||
(use-package geiser-guile
|
||
:defer t
|
||
:after geiser
|
||
:custom (geiser-guile-binary "guile")))
|
||
|
||
;; (use-package ac-slime
|
||
;; :after (slime auto-complete)
|
||
;; :config
|
||
;; (add-hook 'slime-mode-hook 'set-up-slime-ac)
|
||
;; (add-hook 'slime-repl-mode-hook 'set-up-slime-ac))
|
||
|
||
(use-package paredit
|
||
:hook ((emacs-lisp-mode . paredit-mode)
|
||
(eval-expression-minibuffer-setup . paredit-mode)
|
||
(ielm-mode . paredit-mode)
|
||
(lisp-mode . paredit-mode)
|
||
(lisp-interaction-mode . paredit-mode)
|
||
(scheme-mode . paredit-mode))
|
||
:bind (:map paredit-mode-map
|
||
("M-s" . nil)
|
||
("C-M-s" . paredit-splice-sexp)))
|
||
|
||
;; (load "bundle--irc")
|
||
|
||
(defun mk/start-irc (nick)
|
||
(interactive "sTell me your nick please: ")
|
||
(erc-tls :server "irc.libera.chat"
|
||
:port 6697
|
||
:nick nick
|
||
:full-name "Jay Edgar Hoover"))
|
||
|
||
(use-package erc
|
||
:defer t
|
||
:custom
|
||
(erc-track-exclude '("#emacs"))
|
||
(erc-track-exclude-types '("JOIN" "NICK" "QUIT" "MODE" "AWAY"))
|
||
(erc-hide-list '("JOIN" "NICK" "QUIT" "MODE" "AWAY"))
|
||
(erc-track-exclude-server-buffer t)
|
||
(erc-fill-column 80)
|
||
(erc-fill-function 'erc-fill-static)
|
||
(erc-fill-static-center 20)
|
||
(erc-prompt-for-nickserv-password nil)
|
||
(erc-track-shorten-start 8)
|
||
(erc-auto-query 'bury)
|
||
(erc-network-hide-list '(("libera.chat" "JOIN" "PART" "QUIT")))
|
||
(erc-rename-buffers t)
|
||
(erc-interpret-mirc-color t)
|
||
(erc-kill-buffer-on-part t)
|
||
(erc-kill-queries-on-quit t)
|
||
(erc-kill-server-buffer-on-quit t)
|
||
(erc-modules
|
||
'(autojoin ; Set away status automatically
|
||
button ; Join channels automatically
|
||
completion ; Complete nicknames and commands (programmable)
|
||
fill ; Wrap long lines
|
||
irccontrols ; Highlight or remove IRC control characters
|
||
match ; Highlight pals, fools, and other keywords
|
||
menu ; Display a menu in ERC buffers
|
||
netsplit ; Detect netsplits
|
||
noncommands ; Don’t display non-IRC commands after evaluation
|
||
readonly ; Make displayed lines read-only
|
||
ring ; Enable an input history
|
||
services ; Identify to Nickserv (IRC Services) automatically
|
||
smiley ; Convert smileys to pretty icons
|
||
stamp ; Add timestamps to messages
|
||
truncate ; Truncate buffers to a certain size
|
||
)))
|
||
|
||
(use-package erc-hl-nicks
|
||
:after erc
|
||
:config
|
||
(add-to-list 'erc-modules 'hl-nicks))
|
||
|
||
(use-package erc-image
|
||
:after erc
|
||
:config
|
||
(setq erc-image-inline-rescale 300)
|
||
(add-to-list 'erc-modules 'image))
|
||
|
||
;; (load "bundle--news")
|
||
|
||
(use-package elfeed
|
||
:bind ("C-x w" . elfeed)
|
||
:init (setq elfeed-feeds
|
||
'(("https://netzpolitik.org/feed/" netz politik news)
|
||
("https://www.marcuskammer.dev/weblog/index.xml" personal)
|
||
("https://www.guyrutenberg.com/feed/" linux blog)
|
||
("https://blog.mozilla.org/en/feed/" browser web)
|
||
("https://blog.chromium.org/feeds/posts/default" browser web)
|
||
("https://hacks.mozilla.org/feed/" browser web)
|
||
("https://mailbox.org/share/feed-de-mailbox.xml" email mailbox web)
|
||
("https://feeds.feedburner.com/GoogleWebFonts" fonts blog google)
|
||
("https://twobithistory.org/feed.xml" history blog coding)
|
||
("https://blog.getbootstrap.com/feed.xml" web bootstrap blog)
|
||
("https://blog.mozilla.org/en/feed/" web firefox blog)
|
||
("https://fsfe.org/news/news.de.rss" fsfe news free-software)
|
||
("https://planet.lisp.org/rss20.xml" planet lisp)
|
||
("https://emacsconf.org/index.atom" emacs lisp conference)
|
||
("https://jameshunt.us/feeds/main" lisp blog)
|
||
("https://xenodium.com/rss.xml" emacs blog)
|
||
("https://stevelosh.com/rss.xml" lisp blog personal)
|
||
("https://planet.lisp.org/rss20.xml" lisp blogs)
|
||
("https://m-x-erlangen.gitlab.io/atom.xml" lisp meetup)
|
||
("https://takeonrules.com/index.atom" lisp emacs blog)
|
||
("https://emacsredux.com/atom.xml" emacs blog)
|
||
("https://planet.emacslife.com/atom.xml" emacs)
|
||
("https://yiming.dev/rss.xml" coding emacs lisp blog)
|
||
("https://endlessparentheses.com/atom.xml" emacs elisp blog)
|
||
("https://www.philnewton.net/blog/feed/" emacs blog)
|
||
("https://emacsredux.com/atom.xml" emacs blog)
|
||
("https://marcus3santos.github.io/index.xml" emacs blog)
|
||
("https://olddeuteronomy.github.io/index.xml" emacs blog)
|
||
("https://www.colinmclear.net/posts/index.xml" research emacs blog)
|
||
("https://howardism.org/index.xml" emacs blog)
|
||
("https://www.timmons.dev/rss.xml" lisp blog)
|
||
("https://batsov.com/atom.xml" lisp emacs blog)
|
||
("https://notes.eatonphil.com/rss.xml" lisp emacs blog)
|
||
("https://stackoverflow.com/feeds/tag?tagnames=hunchentoot&sort=newest" lisp stackoverflow)
|
||
("https://stackoverflow.com/feeds/tag?tagnames=common-lisp&sort=newest" lisp stackoverflow)
|
||
("https://stackoverflow.com/feeds/tag?tagnames=elisp&sort=newest" lisp emacs stackoverflow)
|
||
("https://stackoverflow.com/feeds/tag?tagnames=org-mode&sort=newest" emacs orgmode stackoverflow)
|
||
("https://stackoverflow.com/feeds/tag?tagnames=xmpp&sort=newest" xmpp stackoverflow)
|
||
;;("https://stackoverflow.com/feeds/tag?tagnames=postgresql&sort=newest" sql stackoverflow)
|
||
;;("https://stackoverflow.com/feeds/tag?tagnames=mariadb&sort=newest" sql stackoverflow)
|
||
("https://stackoverflow.com/feeds/tag?tagnames=guile&sort=newest" guile scheme lisp stackoverflow)
|
||
("https://stackoverflow.com/feeds/tag?tagnames=sbcl&sort=newest" sbcl lisp stackoverflow)
|
||
("https://stackoverflow.com/feeds/tag?tagnames=sbcl+emacs&sort=newest" sbcl emacs lisp stackoverflow)
|
||
("https://stackoverflow.com/feeds/tag?tagnames=sbcl+common-lisp+linux&sort=newest" sbcl lisp linux stackoverflow)
|
||
("https://sourceforge.net/p/sbcl/activity/feed" lisp sbcl)
|
||
("https://fukamachi.hashnode.dev/rss.xml" lisp blog)
|
||
("https://sourceforge.net/projects/sbcl/rss?path=/sbcl" lisp sbcl sourceforge)
|
||
("https://threatpost.com/feed/" security)
|
||
("https://krebsonsecurity.com/feed/" security blog)
|
||
("https://www.schneier.com/feed/atom/" security blog)
|
||
("https://www.nngroup.com/feed/rss/" ux design)
|
||
("https://feedpress.me/UXmatters" ux design)
|
||
("https://uxmovement.com/feed" ux design)
|
||
("https://www.uxbeginner.com/feed/" ux design)
|
||
("https://jeffgothelf.com/feed/" lean ux design blog)
|
||
("https://uxwritinghub.com/feed/" ux writing blog)
|
||
("https://www.w3.org/WAI/feed.xml" ux wai aria w3c)
|
||
("https://measuringu.com/feed/" ux blog)
|
||
("https://ux.stackexchange.com/feeds" ux stackexchange)
|
||
("https://emacs.stackexchange.com/feeds" emacs stackexchange)
|
||
("https://www.mdr.de/nachrichten/podcast/general/russland-angriff-krieg-ukraine100-podcast.xml" krieg ukraine podcast)
|
||
("https://www.deutschlandfunk.de/umwelt-und-verbraucher-100.rss" umwelt verbraucher klima podcast)
|
||
("https://jung-naiv.podigee.io/feed/mp3" politik podcast)
|
||
("https://www.ndr.de/nachrichten/info/podcast4696.xml" podcast umwelt klima)
|
||
("https://ct-uplink.podigee.io/feed/mp3" podcast technik computer)
|
||
("https://feeds.soundcloud.com/users/soundcloud:users:261098918/sounds.rss" podcast osint)
|
||
("https://hacks.mozilla.org/feed/" blog firefox web)
|
||
("https://karthinks.com/index.xml" blog emacs)
|
||
("https://www.destatis.de/SiteGlobals/Functions/RSSFeed/DE/RSSNewsfeed/Aktuell.xml" destatis aktuelles presse)
|
||
("http://www.umweltbundesamt.de/rss/presse" uba aktuelles presse)
|
||
("https://www.test.de/rss/geldanlage-banken/" test geld finanzen)
|
||
("https://www.test.de/rss/steuern-recht/" test steuern recht)
|
||
("https://thefetishistas.com/feed/" latex fetish news)
|
||
("https://tonsky.me/atom.xml" blog computer)
|
||
("https://www.copernicus.eu/news/rss" klima)
|
||
("https://gegenblende.dgb.de/@@rss?count=10&feed=b3b8f76e-53f1-11e6-a380-525400e5a74a" arbeit gewerkschaft news)
|
||
("https://drewdevault.com/blog/index.xml" blog programming computer)
|
||
("https://inkppl.com/en/rss.xml" tattoo magazin people culture)
|
||
("https://novaramedia.com/feed/" politics capitalism climate left media)
|
||
("https://www.youtube.com/feeds/videos.xml?channel_id=UCN29LJGZ8FY30ysxdTnDsaw" youtube video)
|
||
("https://www.youtube.com/feeds/videos.xml?channel_id=UC5Ghe5TBQGYIOANuiNW4hDQ" youtube video)
|
||
("https://www.youtube.com/feeds/videos.xml?channel_id=UC0p5jTq6Xx_DosDFxVXnWaQ" youtube video)
|
||
("https://www.youtube.com/feeds/videos.xml?channel_id=UC0p5jTq6Xx_DosDFxVXnWaQ" youtube video)
|
||
("https://www.vag.de/rss/meldungen" ubahn opnv vag)
|
||
("https://feeds.feedblitz.com/sethsblog" management author blog)
|
||
("https://ourworldindata.org/atom-data-insights.xml" data world)
|
||
("https://ourworldindata.org/atom.xml" data world)
|
||
("https://www.amazon.science/index.rss" science blog amazon data)
|
||
("https://feed.theregister.com/atom?a=Liam%20Proven" register foss)
|
||
("https://benswift.me/feed.xml" blog creative technology emacs computing)
|
||
("https://media.rss.com/l0wl1f3podcast/feed.xml" cyberpunk podcast)
|
||
("https://sachachua.com/blog/feed/" emacs blog lisp programming)
|
||
))
|
||
:custom
|
||
(elfeed-search-filter "@7-day-ago +unread")
|
||
:config
|
||
(let ((feeds (expand-file-name "~/feeds.el")))
|
||
(when (file-exists-p feeds)
|
||
(load-file feeds))))
|
||
|
||
;; (load "bundle--calendar")
|
||
|
||
(setq holiday-oriental-holidays nil)
|
||
(setq holiday-islamic-holidays nil)
|
||
(setq holiday-bahai-holidays nil)
|
||
(setq holiday-hebrew-holidays nil)
|
||
(setq holiday-general-holidays
|
||
'((holiday-fixed 1 1 "Neujahr")
|
||
(holiday-fixed 5 1 "1. Mai")
|
||
(holiday-fixed 10 3 "Tag der Deutschen Einheit")))
|
||
(setq holiday-christian-holidays
|
||
'((holiday-float 12 0 -4 "1. Advent" 24)
|
||
(holiday-float 12 0 -3 "2. Advent" 24)
|
||
(holiday-float 12 0 -2 "3. Advent" 24)
|
||
(holiday-float 12 0 -1 "4. Advent" 24)
|
||
(holiday-fixed 12 25 "1. Weihnachtstag")
|
||
(holiday-fixed 12 26 "2. Weihnachtstag")
|
||
(holiday-fixed 1 6 "Heilige Drei Könige")
|
||
(holiday-easter-etc -48 "Rosenmontag")
|
||
;; (holiday-easter-etc -3 "Gründonnerstag")
|
||
(holiday-easter-etc -2 "Karfreitag")
|
||
(holiday-easter-etc 0 "Ostersonntag")
|
||
(holiday-easter-etc +1 "Ostermontag")
|
||
(holiday-easter-etc +39 "Christi Himmelfahrt")
|
||
(holiday-easter-etc +49 "Pfingstsonntag")
|
||
(holiday-easter-etc +50 "Pfingstmontag")
|
||
(holiday-easter-etc +60 "Fronleichnam")
|
||
(holiday-fixed 8 15 "Mariae Himmelfahrt")
|
||
(holiday-fixed 11 1 "Allerheiligen")
|
||
;; (holiday-float 11 3 1 "Buss- und Bettag" 16)
|
||
(holiday-float 11 0 1 "Totensonntag" 20)))
|
||
|
||
(use-package calendar
|
||
:ensure nil
|
||
:config
|
||
(setq calendar-latitude 49.4)
|
||
(setq calendar-longitude 11.0)
|
||
(setq calendar-location-name "Nuremberg, DE")
|
||
:custom
|
||
(european-calendar-style t)
|
||
(calendar-christian-all-holidays-flag t)
|
||
(calendar-date-style (quote iso))
|
||
(calendar-view-diary-initially-flag t)
|
||
(calendar-week-start-day 1)
|
||
(calendar-intermonth-text
|
||
'(propertize
|
||
(format "%2d"
|
||
(car
|
||
(calendar-iso-from-absolute
|
||
(calendar-absolute-from-gregorian
|
||
(list month day year )))))
|
||
'font-lock-face 'font-lock-function-name-face)))
|
||
|
||
;; (load "bundle--email")
|
||
|
||
(setq mml-default-sign-method "pgpmime"
|
||
mml-default-encrypt-method "pgpmime"
|
||
mml-secure-openpgp-sign-with-sender t
|
||
mail-user-agent 'message-user-agent
|
||
compose-mail-user-agent-warnings nil)
|
||
|
||
(defun mk/sign-email ()
|
||
;; Sign an Email using the key of the sender.
|
||
(interactive)
|
||
(mml-secure-message-sign-pgpmime))
|
||
|
||
(defun mk/encrypt-email ()
|
||
;; Encrypt an Email using the key of the recipient.
|
||
(interactive)
|
||
(mml-secure-message-encrypt-pgpmime))
|
||
|
||
(defvar mk/gps-location
|
||
(eval '(let ((float-output-format "%.1f"))
|
||
(format "%s%s, %s%s"
|
||
(if (numberp calendar-latitude)
|
||
(abs calendar-latitude)
|
||
(+ (aref calendar-latitude 0)
|
||
(/ (aref calendar-latitude 1) 60.0)))
|
||
(if (numberp calendar-latitude)
|
||
(if (> calendar-latitude 0) "N" "S")
|
||
(if (eq (aref calendar-latitude 2) 'north) "N" "S"))
|
||
(if (numberp calendar-longitude)
|
||
(abs calendar-longitude)
|
||
(+ (aref calendar-longitude 0)
|
||
(/ (aref calendar-longitude 1) 60.0)))
|
||
(if (numberp calendar-longitude)
|
||
(if (> calendar-longitude 0) "E" "W")
|
||
(if (eq (aref calendar-longitude 2) 'east) "E" "W"))))))
|
||
|
||
(defvar mk/signature-name
|
||
(concat "Cheers, "
|
||
user-full-name
|
||
" ("
|
||
calendar-location-name
|
||
", "
|
||
mk/gps-location
|
||
")\n"))
|
||
|
||
(defvar mk/signature-gpg "GnuPG Key: https://meta.sr.ht/~marcuskammer.pgp\nFingerprint: 86DB 0F30 F9F1 661A 54E2 1664 C374 817B E285 268F")
|
||
|
||
(defun mk/signature-time ()
|
||
(format-time-string "Written on: %a, %d %b %Y %R %z\n"))
|
||
|
||
(defun mk/signature ()
|
||
(concat
|
||
;;mk/signature-name
|
||
;;(mk/signature-time)
|
||
mk/signature-gpg))
|
||
|
||
(use-package smtpmail
|
||
:custom
|
||
(smtpmail-smtp-server "smtp.mailbox.org")
|
||
(smtpmail-smtp-service 465)
|
||
(smtpmail-stream-type 'ssl)
|
||
(smtpmail-auth-credentials (expand-file-name "~/.authinfo.gpg")))
|
||
|
||
(add-hook 'message-signature-setup-hook (lambda () (setf message-signature (mk/signature))))
|
||
;; (add-hook 'mail-send-hook #'ispell-message)
|
||
;; (add-hook 'message-send-hook #'ispell-message)
|
||
(add-hook 'message-mode-hook 'turn-on-auto-fill)
|
||
|
||
(setq message-directory "~/Maildir")
|
||
(setq message-auto-save-directory "~/Maildir/Drafts")
|
||
(setq message-send-mail-function 'smtpmail-send-it)
|
||
|
||
(use-package gnus
|
||
:defer t
|
||
:custom
|
||
(gnus-use-full-window nil)
|
||
(gnus-summary-line-format "%O%U%R%z%d %B%(%[%4L: %-22,22f%]%) %s\n")
|
||
(gnus-summary-mode-line-format "Gnus: %p [%A / Sc:%4z] %Z")
|
||
(gnus-summary-same-subject "")
|
||
(gnus-summary-make-false-root 'adopt)
|
||
(gnus-summary-make-false-root-always nil)
|
||
(gnus-sum-thread-tree-indent " ")
|
||
(gnus-sum-thread-tree-root "* ")
|
||
(gnus-sum-thread-tree-false-root "")
|
||
(gnus-sum-thread-tree-single-indent "")
|
||
(gnus-sum-thread-tree-leaf-with-other "+-+> ")
|
||
(gnus-sum-thread-tree-vertical "|")
|
||
(gnus-sum-thread-tree-single-leaf "=--> ")
|
||
(gnus-thread-sort-functions '(gnus-thread-sort-by-subject gnus-thread-sort-by-most-recent-date))
|
||
(gnus-large-newsgroup nil)
|
||
(gnus-inhibit-startup-message t)
|
||
(gnus-check-new-newsgroups nil)
|
||
(gnus-select-method '(nnnil ""))
|
||
(gnus-secondary-select-methods
|
||
'((nntp "news.eternal-september.org"
|
||
(nntp-open-connection-function nntp-open-ssl-stream)
|
||
(nntp-port-number 563)
|
||
(nntp-authinfo-file "~/.authinfo.gpg"))
|
||
(nnimap "mailbox"
|
||
(nnimap-address "imap.mailbox.org")
|
||
(nnimap-inbox "INBOX")
|
||
(nnimap-server-port 993)
|
||
(nnimap-stream ssl)
|
||
(nnimap-authinfo-file "~/.authinfo.gpg"))))
|
||
:config
|
||
(add-hook 'gnus-summary-prepare-hook 'gnus-summary-sort-by-most-recent-date))
|
||
|
||
(when (eq system-type 'gnu/linux)
|
||
(let ((mu4e-dir (expand-file-name "/usr/share/emacs/site-lisp/mu4e/")))
|
||
(when (file-directory-p mu4e-dir)
|
||
(add-to-list 'load-path mu4e-dir)
|
||
(use-package mu4e
|
||
:ensure nil
|
||
:hook (mu4e-compose-pre . (lambda () (setf mu4e-compose-signature (mk/signature))))
|
||
:custom
|
||
(mu4e-confirm-quit nil)
|
||
(mu4e-change-filenames-when-moving t)
|
||
(mu4e-drafts-folder "/Drafts")
|
||
(mu4e-get-mail-command "mbsync -a")
|
||
(mu4e-headers-date-format "%Y-%m-%d %H:%M")
|
||
(mu4e-refile-folder "/Archive")
|
||
(mu4e-sent-folder "/Sent")
|
||
(mu4e-trash-folder "/Trash")
|
||
(mu4e-split-view 'horizontal)
|
||
(mu4e-update-interval (* 10 60))))))
|
||
|
||
;; (load "bundle--org")
|
||
|
||
(use-package org
|
||
:ensure nil
|
||
:defer t
|
||
:hook ((org-mode . turn-on-auto-fill))
|
||
:init (org-clock-persistence-insinuate)
|
||
:bind
|
||
(("C-c l" . org-store-link)
|
||
("C-c a" . org-agenda)
|
||
("C-c c" . org-capture)
|
||
("C-c b" . org-switchb))
|
||
:init
|
||
;; (org-babel-lob-ingest "~/.emacs.d/library-of-babel.org")
|
||
(setq org-capture-templates '())
|
||
:custom
|
||
(abbrev-suggest t)
|
||
(org-hide-block-startup t)
|
||
(org-hide-emphasis-markers nil)
|
||
(org-default-notes-file "notes.org")
|
||
(org-insert-mode-line-in-empty-file t)
|
||
(org-adapt-indentation nil)
|
||
(org-agenda-prefix-format
|
||
'((agenda . " %i %-12:c%?-12t%-6e% s")
|
||
(todo . " %i %-12:c %-6e")
|
||
(tags . " %i %-12:c")
|
||
(search . " %i %-12:c")))
|
||
(org-agenda-dim-blocked-tasks nil)
|
||
(org-agenda-inhibit-startup nil)
|
||
(org-agenda-span 14)
|
||
(org-agenda-start-on-weekday 1)
|
||
(org-agenda-include-diary t)
|
||
(org-attach-dir-relative nil)
|
||
(org-attach-auto-tag nil)
|
||
(org-attach-archive-delete t)
|
||
(org-attach-use-inheritance nil)
|
||
(org-clock-out-remove-zero-time-clocks t)
|
||
(org-clock-persist t)
|
||
(org-clock-rounding-minutes 30)
|
||
(org-confirm-babel-evaluate nil)
|
||
(org-duration-format (quote h:mm))
|
||
(org-export-dispatch-use-expert-ui nil)
|
||
(org-export-default-language "en")
|
||
(org-export-with-smart-quotes t)
|
||
(org-export-with-emphasize t)
|
||
(org-export-with-special-strings t)
|
||
(org-export-with-fixed-width t)
|
||
(org-export-with-timestamps nil)
|
||
(org-export-preserve-breaks nil)
|
||
(org-export-with-sub-superscripts nil)
|
||
(org-export-with-archived-trees nil)
|
||
(org-export-with-author t)
|
||
(org-export-with-broken-links t)
|
||
(org-export-with-clocks nil)
|
||
(org-export-with-creator nil)
|
||
(org-export-with-drawers nil)
|
||
(org-export-with-date t)
|
||
(org-export-with-entities t)
|
||
(org-export-with-email t)
|
||
(org-export-with-footnotes t)
|
||
(org-export-headline-levels 3)
|
||
(org-export-with-inlinetasks nil)
|
||
(org-export-with-section-numbers t)
|
||
(org-export-with-planning nil)
|
||
(org-export-with-priority nil)
|
||
(org-export-with-properties nil)
|
||
(org-export-with-statistics-cookies nil)
|
||
(org-export-with-tags nil)
|
||
(org-export-with-tasks nil)
|
||
(org-export-with-latex t)
|
||
(org-export-time-stamp-file nil)
|
||
(org-export-with-title t)
|
||
(org-export-with-toc t)
|
||
(org-export-with-todo-keywords nil)
|
||
(org-export-with-tables t)
|
||
(org-export-date-timestamp-format "%a, %d %b %Y %R %z")
|
||
(org-export-backends '(ascii html latex md odt texinfo))
|
||
(org-global-properties '(("EFFORT_ALL" . "0:30 1:00 2:00 3:00 5:00 8:00")))
|
||
(org-html-doctype "html5")
|
||
(org-html-html5-fancy t)
|
||
(org-html-head-include-default-style nil)
|
||
(org-log-done (quote time))
|
||
(org-refile-targets '((nil :maxlevel . 3)))
|
||
(org-startup-folded t)
|
||
(org-startup-truncated nil)
|
||
(org-src-fontify-natively t)
|
||
(org-src-tab-acts-natively t)
|
||
(org-src-window-setup 'other-window)
|
||
(org-time-stamp-rounding-minutes '(30 30))
|
||
(org-todo-keywords
|
||
'((sequence "TODO" "DOING(!)" "DONE(!)")
|
||
(sequence "RECRUIT" "INTERVIEW" "QDA" "DOC" "REVIEW")))
|
||
(org-use-property-inheritance nil)
|
||
(org-attach-store-link-p 'attached)
|
||
(org-agenda-custom-commands
|
||
'(("p" "Projects"
|
||
((tags "PROJECT")))))
|
||
(org-latex-packages-alist
|
||
'(("" "listings")
|
||
("" "booktabs")
|
||
("AUTO" "polyglossia" t ("xelatex" "lualatex"))
|
||
("" "grffile")
|
||
("" "unicode-math")
|
||
("" "xcolor")
|
||
("expansion,protrusion=true" "microtype")))
|
||
;; Define the process to convert Org to PDF using XeLaTeX
|
||
(org-latex-pdf-process '("latexmk -lualatex -shell-escape -quiet -f %f"))
|
||
;; Set the compiler to XeLaTeX
|
||
(org-latex-compiler "lualatex")
|
||
(org-latex-tables-booktabs t)
|
||
(org-latex-images-centered t)
|
||
;; Enable listings and other table-related features
|
||
(org-latex-listings t)
|
||
;; Customize the appearance of listings (source code blocks)
|
||
(org-latex-listings-options
|
||
'(("basicstyle" "\\ttfamily\\color[rgb]{0.30, 0.34, 0.42}") ; nord3
|
||
("showstringspaces" "false")
|
||
("keywordstyle" "\\color[rgb]{0.23, 0.26, 0.32}\\textbf") ; nord1
|
||
("commentstyle" "\\color[rgb]{0.26, 0.30, 0.37}") ; nord2
|
||
("stringstyle" "\\color[rgb]{0.18, 0.20, 0.25}") ; nord0
|
||
("frame" "single")
|
||
("numbers" "left")
|
||
("numbersep" "5pt")
|
||
("numberstyle" "\\ttfamily\\color[rgb]{0.30, 0.34, 0.42}") ; nord3
|
||
("keepspaces" "true")
|
||
("showspaces" "false")
|
||
("showstringspaces" "false")
|
||
("showtabs" "false")
|
||
("breaklines" "true")
|
||
("breakatwhitespace" "false")
|
||
("tabsize" "2")
|
||
("columns" "fullflexible")))
|
||
(org-latex-inputenc-alist '((\"utf8\" . \"utf8x\")))
|
||
:config
|
||
(add-to-list 'org-file-apps '("\\.pdf\\'" . emacs))
|
||
(if (eq system-type 'windows-nt)
|
||
(setq org-babel-python-command "python")
|
||
(setq org-babel-python-command "python3"))
|
||
(setq time-stamp-active t
|
||
time-stamp-start "#\\+[dD][aA][tT][eE]: [\t]*"
|
||
time-stamp-end "$"
|
||
time-stamp-inserts t
|
||
time-stamp-format "[%Y-%m-%d %H:%M]")
|
||
(add-hook 'before-save-hook 'time-stamp nil)
|
||
;; (when (eq system-type 'windows-nt)
|
||
;; (setq org-babel-sqlite3-command "c:/msys64/ucrt64/bin/sqlite3.exe"))
|
||
(org-babel-do-load-languages
|
||
'org-babel-load-languages
|
||
'((emacs-lisp . t)
|
||
(lisp . t)
|
||
(gnuplot . t)
|
||
(python . t)
|
||
(sqlite . t)
|
||
(shell . t)
|
||
(plantuml . t)
|
||
(C . t)
|
||
(js . t)
|
||
(scheme . t)
|
||
(dot . t)))
|
||
;; work with org-agenda dispatcher [c] "Today Clocked Tasks" to view today's clocked tasks.
|
||
:custom-face
|
||
(org-tag ((t (:weight normal :height 0.8))))
|
||
(org-level-1 ((t (:slant italic :inherit outline-1 :height 1.6))))
|
||
(org-level-2 ((t (:slant italic :inherit outline-2 :height 1.4))))
|
||
(org-level-3 ((t (:slant italic :inherit outline-3 :height 1.2))))
|
||
(org-level-4 ((t (:slant italic :inherit outline-4 :height 1.0))))
|
||
(org-level-5 ((t (:slant italic :inherit outline-5 :height 1.0)))))
|
||
|
||
;; Define custom LaTeX class with specific formatting
|
||
(with-eval-after-load 'ox-latex
|
||
(add-to-list 'org-latex-classes
|
||
'("koma-general"
|
||
"\\documentclass[a4paper,10pt,captions=tableheading,twoside=false]{scrartcl}
|
||
\\linespread{1.25}
|
||
% ~/.emacs.d/texmf/tex/latex/mycustomstyles/
|
||
\\usepackage{komageneral}"
|
||
("\\section{%s}" . "\\section*{%s}")
|
||
("\\subsection{%s}" . "\\subsection*{%s}")
|
||
("\\subsubsection{%s}" . "\\subsubsection*{%s}")
|
||
("\\paragraph{%s}" . "\\paragraph*{%s}")
|
||
("\\subparagraph{%s}" . "\\subparagraph*{%s}")))
|
||
|
||
(setq org-latex-default-class "koma-general"))
|
||
|
||
(setq org-html-protect-char-alist
|
||
'(("&" . "&")
|
||
("<" . "<")
|
||
(">" . ">")
|
||
(":lambda:" . "λ")
|
||
(":python:" . "🐍")
|
||
(":whale:" . "🐳")
|
||
(":turtle:" . "🐢")
|
||
(":dash:" . "💨")
|
||
(":party:" . "🥳")
|
||
(":see-no-evil:" . "🙈")
|
||
(":cloud:" . "☁️")
|
||
(":abacus:" . "🧮")
|
||
(":desktop:" . "🖥️")
|
||
(":rocket:" . "🚀")
|
||
(":unicorn:" . "🦄")
|
||
(":recycling:" . "♻")
|
||
(":crystalball:" . "🔮")
|
||
(":photography:" . "📷")
|
||
(":money:" . "💵")
|
||
(":-)" . "😊")
|
||
(":-(" . "😞")))
|
||
|
||
;; Note Capture Template
|
||
;; Purpose: To capture general notes. These notes can optionally be linked to a currently clocked-in task.
|
||
;; Fields: Heading, optional task link, initial content, and a timestamp.
|
||
(add-to-list 'org-capture-templates
|
||
`("n" "Note" entry (file "notes.org")
|
||
,(concat "* %? :NOTE:\n"
|
||
":PROPERTIES:\n"
|
||
":ID: %(org-id-new)\n"
|
||
"%(mk/link-to-current-task)"
|
||
":END:\n"
|
||
"Entered on: %U\n")))
|
||
|
||
;; Task Capture Template
|
||
;; Purpose: To capture tasks and automatically assign a unique ID to each task.
|
||
;; Fields: Heading, unique ID, timestamp, and link to where the capture was made.
|
||
(add-to-list 'org-capture-templates
|
||
`("t" "Task" entry (file "agenda/tasks.org")
|
||
,(format "* TODO %%? :TASK:\n:PROPERTIES:\n:ID: %s\n:Project: %%^{Project}\n:END:\nEntered on %%U\n" (org-id-new))))
|
||
|
||
;; Journal Capture Template
|
||
;; Purpose: To capture end-of-day reflections.
|
||
;; Fields: Heading, timestamp, and prompts for what went well, what could be improved, and focus for tomorrow.
|
||
(add-to-list 'org-capture-templates
|
||
'("j" "Journal" entry (file+olp+datetree "agenda/journal.org")
|
||
"* %T - End of Day Reflection :JOURNAL:\n- Was ist heute gut gelaufen?\n %?\n- Was könnte verbessert werden?\n \n- Worauf konzentriere ich mich morgen?\n "
|
||
:empty-lines 1))
|
||
|
||
;; Updated Appointment Capture Template
|
||
;; Purpose: To capture and plan detailed appointments with agenda and preparation tasks.
|
||
;; Fields: Title, Date/Time, Location, Attendees, Agenda Items, Preparation Tasks, Notes.
|
||
(add-to-list 'org-capture-templates
|
||
'("a" "Appointment" entry (file "agenda/appt.org")
|
||
"* %^{Title} %^g
|
||
:PROPERTIES:
|
||
:LOCATION: %^{Location}
|
||
:ATTENDEES: %^{Attendees}
|
||
:END:
|
||
%^{Date}t
|
||
** Agenda
|
||
%?
|
||
** Preparation Tasks
|
||
- [ ]
|
||
- [ ]
|
||
- [ ]
|
||
** Notes
|
||
" :empty-lines 1))
|
||
|
||
;; Meeting Capture Template
|
||
;; Purpose: To capture meeting notes and automatically start a clock for time tracking.
|
||
;; Fields: Topic, timestamp, and additional notes.
|
||
(add-to-list 'org-capture-templates
|
||
'("m" "Meeting" entry (file "agenda/meetings.org")
|
||
"* %^{Topic} \n%T\n%?"
|
||
:clock-in t
|
||
:empty-lines 1))
|
||
|
||
;; Log Capture Template
|
||
;; Purpose: To capture activities in a chronological order and automatically start a clock for time tracking.
|
||
;; Fields: Timestamp, activity description.
|
||
(add-to-list 'org-capture-templates
|
||
'("l" "Log" entry (file+olp+datetree "logbook.org")
|
||
"* %T - %^{Activity} :LOG:\n%?"
|
||
:clock-in t
|
||
:empty-lines 1))
|
||
|
||
;; UTM Parameters Capture Template
|
||
;; Purpose: To capture UTM parameters for marketing tracking.
|
||
;; Fields: Campaign name, source, medium, term, and content.
|
||
(add-to-list 'org-capture-templates
|
||
'("u" "UTM Parameters" entry (file+headline "utm.org" "UTM Parameters")
|
||
"* %^{Campaign Name}\n:PROPERTIES:\n:Source: %^{utm_source}\n:Medium: %^{utm_medium}\n:Term: %^{utm_term}\n:Content: %^{utm_content}\n:END:\n"))
|
||
|
||
;; Bookmark Capture Template
|
||
;; Purpose: To capture bookmarks with tags and a timestamp.
|
||
;; Fields: URL, tags, timestamp.
|
||
(add-to-list 'org-capture-templates
|
||
'("b" "Bookmark" table-line (file+headline "bookmarks.org" "Bookmarks")
|
||
"| %^{URL} | %^{Tags} | %u |" :prepend t))
|
||
|
||
;; Code Snippet Capture Template
|
||
;; Purpose: To capture code snippets and specify the programming language.
|
||
;; Fields: Code snippet, language specification.
|
||
(add-to-list 'org-capture-templates
|
||
'("c" "Code Snippet" entry (file+headline "code.org" "Snippets")
|
||
"* %?\n#+begin_src %^{language}\n%i\n#+end_src"))
|
||
|
||
;; Capture Templates for Interviews
|
||
;;
|
||
;; The following capture templates are designed to facilitate the collection
|
||
;; of questions and insights for user interviews. Given the importance of
|
||
;; user-centered design in experience architecture, these templates aim to
|
||
;; streamline the preparation process for interviews.
|
||
|
||
;; Interview Sub-menu
|
||
;;
|
||
;; This entry serves as a sub-menu for all interview-related capture templates.
|
||
(add-to-list 'org-capture-templates
|
||
'("i" "Interviews"))
|
||
|
||
;; How Might We (HMW) Template
|
||
;;
|
||
;; This template is designed to capture "How Might We" questions that are often
|
||
;; used to frame problems and opportunities in user interviews. These questions
|
||
;; can be crucial for guiding the interview in a direction that yields
|
||
;; actionable insights.
|
||
(add-to-list 'org-capture-templates
|
||
'("ih" "How Might We" entry (file+headline "interviews.org" "HMW Questions")
|
||
"* WKW/HMW %? :HMW:\n%U\n:PROPERTIES:\n:Interviewee: %^{Interviewee}\n:Context: %^{Context}\n:END:"))
|
||
|
||
;; Interview Question Template
|
||
;;
|
||
;; Use this template to quickly capture questions that you intend to ask during
|
||
;; user interviews. The template prompts for the topic of the interview and
|
||
;; the project it is associated with, allowing for easy categorization and
|
||
;; retrieval later.
|
||
(add-to-list 'org-capture-templates
|
||
'("iq" "Interview Question" entry (file+headline "interviews.org" "Interview Questions")
|
||
"* %^{Interview Topic} :INTERVIEW:\n:PROPERTIES:\n:Project: %^{Project Name}\n:Date: %T\n:END:\n- %?\n"))
|
||
|
||
;; User Interview Quotes Capture Template
|
||
;; Purpose: To capture important quotes from user interviews.
|
||
;; Fields: Quote, Interviewee, Timestamp in Video, Project, Context
|
||
(add-to-list 'org-capture-templates
|
||
'("io" "Quote from User Interview" entry (file+headline "interviews.org" "Quotes")
|
||
"* %^{Quote} :QUOTE:\n:PROPERTIES:\n:Interviewee: %^{Interviewee}\n:Timestamp: %^{Timestamp in Video}\n:Project: %^{Project}\n:Context: %^{Context}\n:END:\n"))
|
||
|
||
;; Capture Templates for Project Management and Achievements
|
||
;;
|
||
;; These templates are designed to facilitate the tracking of project details
|
||
;; and individual achievements. Given the focus on agile methodologies and
|
||
;; continuous improvement, these templates aim to provide a structured way
|
||
;; to capture essential information.
|
||
|
||
;; Project Template
|
||
;;
|
||
;; This template captures the essential details of a new project. It prompts
|
||
;; for the project name, start date, and end date, and provides sections for
|
||
;; outlining the project's objectives and challenges. Each project is assigned
|
||
;; a unique ID for easy referencing.
|
||
(add-to-list 'org-capture-templates
|
||
`("p" "Project" entry (file "agenda/projects.org")
|
||
,(format "* %%^{Project Name} :PROJECT:\n:PROPERTIES:\n:ID: %s\n:Start Date: %%T\n:End Date: %%^{End Date}\n:END:\n** Objective\n%%?\n** Challenges\n- [ ] %%^{Challenge 1}\n- [ ] %%^{Challenge 2}\n" (org-id-new))))
|
||
|
||
;; Achievement Template
|
||
;;
|
||
;; This template is designed to capture individual achievements. It prompts for
|
||
;; the title of the achievement, the project it is associated with, and the date.
|
||
;; Additionally, it provides fields for describing the achievement, its impact,
|
||
;; and any associated tasks. This can be particularly useful for end-of-year
|
||
;; reviews or for maintaining a portfolio of accomplishments.
|
||
(add-to-list 'org-capture-templates
|
||
`("v" "Achievement" entry (file+olp+datetree "achievements.org")
|
||
,(concat "* %^{Achievement Title} :ACHIEVEMENT:\n"
|
||
":PROPERTIES:\n"
|
||
":Project: %^{Project}\n"
|
||
":Date: %T\n"
|
||
":END:\n"
|
||
"- Description: %?\n"
|
||
"- Impact: %^{Impact}\n"
|
||
"- Associated Tasks: %^{Tasks}\n")))
|
||
|
||
(add-to-list 'org-capture-templates
|
||
'("A" "Accounting"))
|
||
|
||
;; Expense Tracking
|
||
;; Purpose: To capture individual expenses for accounting in a table.
|
||
;; Fields: Amount, Category, Note, Date
|
||
(add-to-list 'org-capture-templates
|
||
'("Ae" "Expense" table-line (file+headline "accounting.org" "Expenses")
|
||
"| %U | %^{Amount} | %^{Category} | %? |"))
|
||
|
||
;; Income Tracking
|
||
;; Purpose: To capture instances of income for accounting in a table.
|
||
;; Fields: Amount, Source, Date
|
||
(add-to-list 'org-capture-templates
|
||
'("Ai" "Income" table-line (file+headline "accounting.org" "Income")
|
||
"| %U | %^{Amount} | %^{Source} | %? |"))
|
||
|
||
;; Invoice Tracking
|
||
;; Purpose: To capture invoices sent for services or products in a table.
|
||
;; Fields: Client, Amount, Due Date
|
||
(add-to-list 'org-capture-templates
|
||
'("AI" "Invoice" table-line (file+headline "accounting.org" "Invoices")
|
||
"| %T | %^{Client} | %^{Amount} | %^{Due Date} | %? |"))
|
||
|
||
;; Budget Planning
|
||
;; Purpose: To capture budget plans for personal or business accounting in a table.
|
||
;; Fields: Estimated Income, Estimated Expenses
|
||
(add-to-list 'org-capture-templates
|
||
`("Ab" "Budget" table-line (file+headline "accounting.org" "Budget")
|
||
,(concat "| " (format-time-string "%Y") " | " (format-time-string "%B") " | %^{Estimated Income} | %^{Estimated Expenses} | %? |")))
|
||
|
||
;; Investment Tracking
|
||
;; Purpose: To capture investment details for accounting in a table.
|
||
;; Fields: Type, Amount, Notes
|
||
(add-to-list 'org-capture-templates
|
||
'("Av" "Investment" table-line (file+headline "accounting.org" "Investments")
|
||
"| %U | %^{Type} | %^{Amount} | %? |"))
|
||
|
||
;; Stock Recommendation Capture Template
|
||
;; Purpose: To capture stock recommendations for potential investment.
|
||
;; Fields: Stock Symbol, Recommender, Notes, Date
|
||
(add-to-list 'org-capture-templates
|
||
'("s" "Stock Recommendation" entry (file+headline "stocks.org" "Stock Recommendations")
|
||
"* %^{Stock Name} :STOCK:\n:PROPERTIES:\n:Date: %T\n:WKN: %^{WKN}\n:ISIN: %^{ISIN}\n:END:\n%?"))
|
||
|
||
(add-to-list 'org-capture-templates
|
||
'("B" "Bücherliste" table-line
|
||
(file+headline "books.org" "Meine Bücherliste")
|
||
"| %^{Buchtitel} | %^{Autor} | %^{Status||Geplant|In Bearbeitung|Fertig} | %U |" :kill-buffer t))
|
||
|
||
(require 'request)
|
||
|
||
(use-package org-roam
|
||
:defer t
|
||
:after org
|
||
:init
|
||
(setq org-roam-db-autosync-mode t)
|
||
(setq org-roam-v2-ack t)
|
||
(setq org-roam-db-location "~/org-roam.db")
|
||
(require 'org-roam-dailies)
|
||
:bind (("C-c r l" . org-roam-buffer-toggle)
|
||
("C-c r f" . org-roam-node-find)
|
||
("C-c r g" . org-roam-graph)
|
||
("C-c r i" . org-roam-node-insert)
|
||
("C-c r c" . org-roam-capture)
|
||
("C-c r j" . org-roam-dailies-map)
|
||
:map org-roam-dailies-map
|
||
("t" . org-roam-dailies-capture-today)
|
||
("y" . org-roam-dailies-capture-yesterday)
|
||
("T" . org-roam-dailies-capture-tomorrow)
|
||
:map org-mode-map
|
||
("C-M-i" . completion-at-point))
|
||
:custom
|
||
(org-roam-completion-everywhere nil)
|
||
(org-roam-dailies-capture-templates
|
||
'(("d" "default" entry "* %<%R> %?"
|
||
:if-new (file+head "%<%F>.org" "#+title: %<%F>\n"))))
|
||
(org-roam-capture-templates
|
||
'(("d" "default" plain
|
||
"%?"
|
||
:if-new (file+head "%<%Y%m%d%H%M%S>-${slug}.org" "#+title: ${title}\n")
|
||
:unnarrowed t)
|
||
("r" "Research" plain
|
||
"* Hypothesis:\n%?\n* Methodology:\n* Results:\n* Conclusions:\n"
|
||
:if-new (file+head "research/%<%Y%m%d%H%M%S>-${slug}.org" "#+title: ${title}\n")
|
||
:unnarrowed t)
|
||
("m" "Meeting" plain
|
||
"* Participants:\n%?\n* Discussion topics:\n* Action points:\n"
|
||
:if-new (file+head "meetings/%<%Y%m%d%H%M%S>-${slug}.org" "#+title: ${title}\n")
|
||
:unnarrowed t)
|
||
("p" "Project" plain
|
||
"* Goals:\n%?\n* Milestones:\n* Resources:\n"
|
||
:if-new (file+head "projects/%<%Y%m%d%H%M%S>-${slug}.org" "#+title: ${title}\n")
|
||
:unnarrowed t)
|
||
("l" "Literature" plain
|
||
"* Authors:\n%?\n* Main theses:\n* Own thoughts:\n"
|
||
:if-new (file+head "literature/%<%Y%m%d%H%M%S>-${slug}.org" "#+title: ${title}\n")
|
||
:unnarrowed t))))
|
||
|
||
(use-package org-tree-slide
|
||
:bind ("<f5>" . org-tree-slide-mode)
|
||
:custom
|
||
(org-image-actual-width nil))
|
||
|
||
(use-package org-web-tools
|
||
:defer t
|
||
:custom (org-web-tools-pandoc-sleep-time 0.4))
|
||
|
||
;; (use-package ob-go
|
||
;; :after org)
|
||
|
||
(use-package ox-reveal
|
||
:after org)
|
||
|
||
;; (use-package ox-pandoc
|
||
;; :after org
|
||
;; :custom
|
||
;; (org-pandoc-options-for-beamer-pdf '((pdf-engine . "xelatex"))))
|
||
|
||
;; (defun me/write-readme-md-on-save ()
|
||
;; ;; when README.org, also write README.md on save
|
||
;; (when (string-match "README" (buffer-file-name))
|
||
;; (make-local-variable 'after-save-hook)
|
||
;; (add-hook 'after-save-hook
|
||
;; (lambda () (let ((outfile (org-export-output-file-name ".md")))
|
||
;; (org-export-to-file 'md outfile))))))
|
||
;; (add-hook 'org-mode-hook 'me/write-readme-md-on-save)
|
||
|
||
;; (use-package ob-go
|
||
;; :after org
|
||
;; :config
|
||
;; (append '((go . t)) org-babel-load-languages))
|
||
|
||
(use-package ob-http
|
||
:after org
|
||
:config
|
||
(append '((http . t)) org-babel-load-languages))
|
||
|
||
(when (eq system-type 'windows-nt)
|
||
(use-package ob-powershell
|
||
:after org))
|
||
|
||
;; (use-package ob-racket
|
||
;; :after org
|
||
;; :pin manual
|
||
;; :config
|
||
;; (append '((racket . t) (scribble . t)) org-babel-load-languages))
|
||
|
||
;; (use-package ox-rss
|
||
;; :after org)
|
||
|
||
;; (use-package ob-restclient
|
||
;; :after org
|
||
;; :config
|
||
;; (append '((restclient . t)) org-babel-load-languages))
|
||
|
||
(let ((bundle-dir (expand-file-name "~/.emacs.d/bundle/")))
|
||
(when (file-directory-p bundle-dir)
|
||
(add-to-list 'load-path bundle-dir)
|
||
(load "bundle--mk")))
|