Compare commits

..

14 Commits

Author SHA1 Message Date
Jacopo De Simoi c78580d644 Colourize the other contexts 3 months ago
Jacopo De Simoi 2238ef7ca9 Ellama stuff 3 months ago
Jacopo De Simoi ae559b0550 Add a few providers for bibretrieve 3 months ago
Jacopo De Simoi f6702e40fd Add a few bindings for avy-goto-char 3 months ago
Jacopo De Simoi 6b5a17b96d Restyle the agenda 3 months ago
Jacopo De Simoi b789981ffb Stub for local holidays 3 months ago
Jacopo De Simoi 20a42ce7fd Use pdf-view for reading pdfs 3 months ago
Jacopo De Simoi 119569acae Add new contexts for editorial purposes 3 months ago
Jacopo De Simoi 24906d37e8 Add header-line to μ-compose to show the context 3 months ago
Jacopo De Simoi 8e005ccd9c Whitespace cleanup 3 months ago
Jacopo De Simoi 5a3a65cf45 Silence mouse hints 3 months ago
Jacopo De Simoi 8dba116f2c Update todo tracker 3 months ago
Jacopo De Simoi 374b7ead7b Update lunarized theme 3 months ago
Jacopo De Simoi 29e3a66400 Update customize stuff 3 months ago
  1. 2
      custom.el
  2. 2
      emacs-color-theme-solarized
  3. 412
      global.org

@ -84,7 +84,7 @@
("melpa-stable" . "http://stable.melpa.org/packages/") ("melpa-stable" . "http://stable.melpa.org/packages/")
("org" . "http://orgmode.org/elpa/"))) ("org" . "http://orgmode.org/elpa/")))
'(package-selected-packages '(package-selected-packages
'(adaptive-wrap aggressive-indent async csv-mode elfeed epl '(adaptive-wrap aggressive-indent async csv-mode elfeed ellama epl
excorporate f flycheck geiser-guile ghub git-commit excorporate f flycheck geiser-guile ghub git-commit
git-gutter graphql helm helm-ag helm-core git-gutter graphql helm helm-ag helm-core
helm-flycheck helm-projectile helm-tramp helm-xref helm-flycheck helm-projectile helm-tramp helm-xref

@ -1 +1 @@
Subproject commit 381574f191c0fc357d1605165a61d9e3e3bc1555 Subproject commit d3ecade4fb229b70b38c692516478738089bc19d

@ -4,15 +4,34 @@
#+options: *:t ::t #+options: *:t ::t
* TODO Tasks that need attention * TODO Tasks that need attention
** TODO files saved with mu4e have restrictive permissions. ** TODO Add directory name somewhere in mu4e:headers
** TODO Mouse still shows tooltips in mu4e:view mode ** TODO Mouse still shows tooltips in mu4e:view mode
** TODO Find something to put the C-z prefix to good use ** TODO Remove mouse hints from modeline (maybe done?)
Maybe this is done… I still need to understand if there are other
help-echo stuff lying around
There are mouse hints in flyspell
** TODO org-babel open-line creates two newlines. ** TODO org-babel open-line creates two newlines.
** TODO BUG!!!!!!!!!!!! invalid target location, and the capture is gone. ** TODO BUG!!!!!!!!!!!! invalid target location, and the capture is gone.
** TODO C-a does not work as expected when the subtree is expanded
** TODO migrate from patching org-mode to a more sustainable option ** TODO migrate from patching org-mode to a more sustainable option
the issue is that I wanted to make sure that nothing would break by the issue is that I wanted to make sure that nothing would break by
managing conflicts by hand, but this is not happening in practice managing conflicts by hand, but this is not happening in practice
** TODO Fix git diff stuff being unreadable
** TODO The window management is sometimes frustrating
** TODO Autosort token for some subtrees
I forgot; perhaps we can do it on save?
** TODO Work on a "welcome" read-only org page for each activity in
which we put links to what should be done in that activity. For
instance
** TODO explore [[https://blog.modelworks.ch/managing-papers-with-org-mode-and-reftex/][this possibility]] about org-mode paper managing
** TODO Find something to put the C-z prefix to good use
** DONE fix the issue with highlighting bleeding over the margin for
~ace-window~
** DONE files saved with mu4e have restrictive permissions.
[[*Save attachments with more reasonable permissions][Fixed here]]
** DONE can we run a task with an org-link? ** DONE can we run a task with an org-link?
For instance, I want to call kmail in "zero inbox proton" For instance, I want to call kmail in "zero inbox proton"
i can run elisp code... i can run elisp code...
@ -22,24 +41,10 @@
candidates candidates
- [ ] Implement action for ignoring contacts - [ ] Implement action for ignoring contacts
** TODO remove duplicates in contacts list with double spaces and such
** DONE take care of the "dear To" when completing the name in an email ** DONE take care of the "dear To" when completing the name in an email
** DONE make an alist for names to nicknames when completing the name… ** DONE make an alist for names to nicknames when completing the name…
** TODO how to "open with" attachments with mu4e?
** DONE investigate what is wrong with inline-pdf image width ** DONE investigate what is wrong with inline-pdf image width
I need to cycle the mode on/off to make it work as intended I need to cycle the mode on/off to make it work as intended
** TODO fix the issue with highlighting bleeding over the margin for
~ace-window~
** TODO The window management is sometimes frustrating
** TODO Autosort token for some subtrees
** TODO Work on a "welcome" read-only org page for each activity in
which we put links to what should be done in that activity. For
instance
** TODO revert org-files on frame activation.
What was the deal with auto-revert-mode again?
** TODO explore [[https://blog.modelworks.ch/managing-papers-with-org-mode-and-reftex/][this possibility]] about org-mode paper managing
* TODO Features to explore * TODO Features to explore
** Study how to implement no-scroll mode ** Study how to implement no-scroll mode
@ -486,6 +491,8 @@
'("%e" mode-line-format-left '("%e" mode-line-format-left
mode-line-separator mode-line-separator
mode-line-format-right)) mode-line-format-right))
(setq mode-line-default-help-echo nil)
#+end_src #+end_src
The following has been found in [[https://www.masteringemacs.org/article/hiding-replacing-modeline-strings][here]] to clean up the modeline The following has been found in [[https://www.masteringemacs.org/article/hiding-replacing-modeline-strings][here]] to clean up the modeline
I modified it marginally to avoid using the loop monster I modified it marginally to avoid using the loop monster
@ -711,6 +718,13 @@
(propertize "." 'display `((margin left-margin) (propertize "." 'display `((margin left-margin)
,(propertize "×" 'face 'flyspell-margin-incorrect)))) ,(propertize "×" 'face 'flyspell-margin-incorrect))))
#+end_src #+end_src
#+begin_src emacs-lisp
(advice-add 'make-flyspell-overlay :filter-return (lambda (overlay)
(overlay-put overlay 'help-echo nil)
overlay))
#+end_src
** Fringe treatment ** Fringe treatment
*** Add margin marker for current line *** Add margin marker for current line
Add marker for current line in the margin (see Add marker for current line in the margin (see
@ -888,116 +902,138 @@
** mu4e ** mu4e
These are some standard config items These are some standard config items
#+begin_src emacs-lisp #+begin_src emacs-lisp
(require 'smtpmail) (require 'smtpmail)
(require 'mu4e) (require 'mu4e)
(require 'helm-mu) (require 'helm-mu)
(global-set-key (kbd "C-x μ") 'mu4e) (global-set-key (kbd "C-x μ") 'mu4e)
(global-set-key (kbd "C-x 5 μ") (eval-with-new-frame (mu4e))) (global-set-key (kbd "C-x 5 μ") (eval-with-new-frame (mu4e)))
(defalias 'μ 'mu4e) (defalias 'μ 'mu4e)
(setq mu4e-maildir "~/.mail" (setq mu4e-maildir "~/.mail"
mu4e-attachment-dir "~/attachments" mu4e-attachment-dir "~/attachments"
mu4e-html2text-command "w3m -dump -T text/html -cols 72 -o display_link_number=true -o auto_image=false -o display_image=false -o ignore_null_img_alt=true" mu4e-html2text-command "w3m -dump -T text/html -cols 72 -o display_link_number=true -o auto_image=false -o display_image=false -o ignore_null_img_alt=true"
mu4e-headers-show-threads nil mu4e-headers-show-threads nil
mu4e-headers-sort-direction "descending" mu4e-headers-sort-direction "descending"
mail-user-agent 'mu4e-user-agent mail-user-agent 'mu4e-user-agent
read-mail-command 'mu4e read-mail-command 'mu4e
mu4e-update-interval 120 mu4e-update-interval 120
mu4e-view-use-gnus t mu4e-view-use-gnus t
message-kill-buffer-on-exit t message-kill-buffer-on-exit t
mu4e-compose-format-flowed t mu4e-compose-format-flowed t
fill-flowed-encode-column 998 fill-flowed-encode-column 998
mm-text-html-renderer 'gnus-w3m mm-text-html-renderer 'gnus-w3m
mu4e-read-option-use-builtin nil mu4e-read-option-use-builtin nil
mu4e-completing-read-function 'completing-read mu4e-completing-read-function 'completing-read
mu4e-modeline-support nil mu4e-modeline-support nil
)
(let (p1 p2 myLine)
(setq p1 (line-beginning-position) )
(setq p2 (line-end-position) )
(setq myLine (buffer-substring-no-properties p1 p2)))
(defun get-buffer-current-line ()
(let ((p (line-beginning-position))
(q (line-end-position)))
(buffer-substring-no-properties p q)))
(defun get-buffer-to-eol ()
(let ((p (point))
(q (line-end-position)))
(buffer-substring-no-properties p q)))
(defun format-zoom-meeting ()
(if (boundp 'zoom-link)
(if (boundp 'zoom-passcode)
(concat zoom-summary
" [[" zoom-link "][link]] (" zoom-passcode ")\n SCHEDULED: " zoom-scheduled-time)
(concat zoom-summary
" [[" zoom-link "][link]]\n SCHEDULED: " zoom-scheduled-time))
(concat zoom-summary "\n SCHEDULED: " zoom-scheduled-time)))
(defun create-item-for-meeting (msg)
"Search for messages sent by the sender of the message at point."
(makunbound 'zoom-link)
(makunbound 'zoom-passcode)
(save-excursion
(beginning-of-buffer)
(cond ((search-forward "Join Zoom Meeting" nil t)
(message "found zoom meeting")
(right-char)
(setq zoom-link (get-buffer-current-line))
(when (search-forward "Passcode:" nil t)
(setq zoom-passcode (get-buffer-current-line)))
(beginning-of-buffer)
(search-forward "Time:")
(search-forward "<")
(left-char)
(setq zoom-scheduled-time (get-buffer-to-eol))
(search-backward "Summary:")
(right-word)
(right-word)
(left-word)
(setq zoom-summary (get-buffer-to-eol))
(org-capture nil "z"))
((search-forward "Accept ]")
(message "found generic meeting")
(search-forward "Summary:")
(right-word)
(right-word)
(left-word)
(setq zoom-summary (get-buffer-to-eol))
(search-forward "Location:")
(right-word)
(left-word)
(setq zoom-summary (concat zoom-summary " @" (get-buffer-to-eol)))
(search-forward "Time:")
(search-forward "<")
(left-char)
(setq zoom-scheduled-time (get-buffer-to-eol))
(org-capture nil "z")))))
;; define 'z' as the shortcut
(add-to-list 'mu4e-view-actions
'("zCreate agenda item for meeting" . create-item-for-meeting) t)
(advice-add 'mu4e-update-mail-and-index :around
(lambda (orig-fun &rest args)
"Only trigger an update if the server is the one that should
currently be active; otherwise each mu4e instance will trigger an
update"
(when (string-equal server-name (kde-current-activity-name))
(apply orig-fun args))))
(advice-add 'mu4e~header-line-format :around )
(lambda (orig-fun &rest args)
(let ((mu4e-use-fancy-chars t)
(mu4e--mark-fringe-len 5))
(apply orig-fun args))))
(let (p1 p2 myLine)
(setq p1 (line-beginning-position) )
(setq p2 (line-end-position) )
(setq myLine (buffer-substring-no-properties p1 p2)))
(defun get-buffer-current-line ()
(let ((p (line-beginning-position))
(q (line-end-position)))
(buffer-substring-no-properties p q)))
(defun get-buffer-to-eol ()
(let ((p (point))
(q (line-end-position)))
(buffer-substring-no-properties p q)))
(defun format-zoom-meeting ()
(if (boundp 'zoom-link)
(if (boundp 'zoom-passcode)
(concat zoom-summary
" [[" zoom-link "][link]] (" zoom-passcode ")\n SCHEDULED: " zoom-scheduled-time)
(concat zoom-summary
" [[" zoom-link "][link]]\n SCHEDULED: " zoom-scheduled-time))
(concat zoom-summary "\n SCHEDULED: " zoom-scheduled-time)))
(defun create-item-for-meeting (msg)
"Search for messages sent by the sender of the message at point."
(makunbound 'zoom-link)
(makunbound 'zoom-passcode)
(save-excursion
(beginning-of-buffer)
(cond ((search-forward "Join Zoom Meeting" nil t)
(message "found zoom meeting")
(right-char)
(setq zoom-link (get-buffer-current-line))
(when (search-forward "Passcode:" nil t)
(setq zoom-passcode (get-buffer-current-line)))
(beginning-of-buffer)
(search-forward "Time:")
(search-forward "<")
(left-char)
(setq zoom-scheduled-time (get-buffer-to-eol))
(search-backward "Summary:")
(right-word)
(right-word)
(left-word)
(setq zoom-summary (get-buffer-to-eol))
(org-capture nil "z"))
((search-forward "Accept ]")
(message "found generic meeting")
(search-forward "Summary:")
(right-word)
(right-word)
(left-word)
(setq zoom-summary (get-buffer-to-eol))
(search-forward "Location:")
(right-word)
(left-word)
(setq zoom-summary (concat zoom-summary " @" (get-buffer-to-eol)))
(search-forward "Time:")
(search-forward "<")
(left-char)
(setq zoom-scheduled-time (get-buffer-to-eol))
(org-capture nil "z")))))
;; define 'z' as the shortcut
(add-to-list 'mu4e-view-actions
'("zCreate agenda item for meeting" . create-item-for-meeting) t)
(advice-add 'mu4e-update-mail-and-index :around
(lambda (orig-fun &rest args)
"Only trigger an update if the server is the one that should
currently be active; otherwise each mu4e instance will trigger an
update"
(when (string-equal server-name (kde-current-activity-name))
(apply orig-fun args))))
(advice-add 'mu4e~header-line-format :around
(lambda (orig-fun &rest args)
(let ((mu4e-use-fancy-chars t)
(mu4e--mark-fringe-len 5))
(apply orig-fun args))))
#+end_src
*** This is an attempt to highlight the current context when composing
#+begin_src emacs-lisp
(add-hook 'mu4e-compose-mode-hook
(defun my-do-compose-stuff ()
(setq header-line-format-right '("Context: "
(:eval (mu4e-context-name (mu4e-context-current))))
header-line-separator
'(:eval (let* ((len-left 0)
(len-right (length (format-mode-line header-line-format-right)))
(len-separator (- (+ (window-width) 2 2 2) (+ len-left len-right))))
(format (format "%%%ds" len-separator) ""))))
(put 'header-line-format-right 'risky-local-variable t)
(put 'header-line-separator 'risky-local-variable t)
(setq header-line-format '("" header-line-separator
header-line-format-right))))
#+end_src
*** Save attachments with more reasonable permissions
#+begin_src emacs-lisp
(setq mm-attachment-file-modes #o644)
#+end_src #+end_src
*** Recipient handling *** Recipient handling
Add aliases (i.e. mailing groups) to [[file://~/.mailrc][the .mailrc file]] Add aliases (i.e. mailing groups) to [[file://~/.mailrc][the .mailrc file]]
@ -1088,7 +1124,7 @@
"Professor · U Toronto\n")))) "Professor · U Toronto\n"))))
,(make-mu4e-context ,(make-mu4e-context
:name "CMP Editor" :name (propertize "CMP Editor" 'face 'org-level-1)
:enter-func :enter-func
(lambda () (mu4e-message "Switch to the CMP Editor context")) (lambda () (mu4e-message "Switch to the CMP Editor context"))
:leave-func :leave-func
@ -1109,6 +1145,53 @@
( mu4e-compose-signature . (concat ( mu4e-compose-signature . (concat
"Jacopo De Simoi (he · him)\n" "Jacopo De Simoi (he · him)\n"
"Associate Editor for CMP\n" "Associate Editor for CMP\n"
"Professor · U Toronto\n"))))
,(make-mu4e-context
:name (propertize "JMD Editor" 'face 'org-level-2)
:enter-func
(lambda () (mu4e-message "Switch to the JMD Editor context"))
:leave-func
(lambda () (mu4e-message "Leave the JMD Editor context"))
;; we match based on the maildir of the message
:match-func (lambda (msg)
(when msg
(string-match-p "^/math/editorial.JMD" (mu4e-message-field
msg :maildir))))
:vars '( ( user-mail-address . "jacopods@math.utoronto.ca" )
( user-full-name . "Jacopo De Simoi" )
( mu4e-sent-folder . "/math/Sent")
( mu4e-drafts-folder . "/math/Drafts")
( mu4e-trash-folder . "/math/Trash")
( mu4e-refile-folder . "/math/editorial.JMD.Archive")
( smtpmail-stream-type . starttls )
( smtpmail-smtp-service . 587 )
( mu4e-compose-signature . (concat
"Jacopo De Simoi (he · him)\n"
"Editor for JMD\n"
"Professor · U Toronto\n"))))
,(make-mu4e-context
:name (propertize "AMQ Editor" 'face 'org-level-3)
:enter-func
(lambda () (mu4e-message "Switch to the AMQ Editor context"))
:leave-func
(lambda () (mu4e-message "Leave the AMQ Editor context"))
;; we match based on the maildir of the message
:match-func (lambda (msg)
(when msg
(string-match-p "^/math/editorial.AMQ" (mu4e-message-field
msg :maildir))))
:vars '( ( user-mail-address . "jacopods@math.utoronto.ca" )
( user-full-name . "Jacopo De Simoi" )
( mu4e-sent-folder . "/math/Sent")
( mu4e-drafts-folder . "/math/Drafts")
( mu4e-trash-folder . "/math/Trash")
( mu4e-refile-folder . "/math/editorial.AMQ.Archive")
( smtpmail-stream-type . starttls )
( smtpmail-smtp-service . 587 )
( mu4e-compose-signature . (concat
"Jacopo De Simoi (he · him)\n"
"Editor for AMQ\n"
"Professor · U Toronto\n")))))) "Professor · U Toronto\n"))))))
;; set `mu4e-context-policy` and `mu4e-compose-policy` to tweak when mu4e should ;; set `mu4e-context-policy` and `mu4e-compose-policy` to tweak when mu4e should
@ -1386,8 +1469,7 @@
(setq org-file-apps (setq org-file-apps
'((auto-mode . emacs) '((auto-mode . emacs)
("\\.x?html?\\'" . "xdg-open %s") ("\\.x?html?\\'" . "xdg-open %s")
("\\.djvu\\'" . "xdg-open \"%s\"") ("\\.djvu\\'" . "xdg-open \"%s\"")))
("\\.pdf\\'" . "xdg-open \"%s\"")))
#+end_src #+end_src
*** Agenda *** Agenda
Set the canonical binding for the agenda Set the canonical binding for the agenda
@ -1506,7 +1588,12 @@
; the bit below adds a blank line before the first scheduled item ; the bit below adds a blank line before the first scheduled item
(mapconcat #'identity list "\n"))) (mapconcat #'identity list "\n")))
#+end_src #+end_src
- Local holidays
#+begin_src emacs-lisp
(setq ontario-statutory-holidays
'((holiday-fixed 1 1 "New Year's Day")
(holiday-float 2 1 3 "Family Day")))
#+end_src
- Sleeker time-grid - Sleeker time-grid
#+begin_src emacs-lisp #+begin_src emacs-lisp
(setq org-agenda-sort-notime-is-late nil) (setq org-agenda-sort-notime-is-late nil)
@ -1561,11 +1648,6 @@
(year (nth 2 date)) (year (nth 2 date))
(iso-week (org-days-to-iso-week (iso-week (org-days-to-iso-week
(calendar-absolute-from-gregorian date))) (calendar-absolute-from-gregorian date)))
;; (weekyear (cond ((and (= month 1) (>= iso-week 52))
;; (1- year))
;; ((and (= month 12) (<= iso-week 1))
;; (1+ year))
;; (t year)))
(weekstring (format " W%02d" iso-week) (weekstring (format " W%02d" iso-week)
)) ))
(format "%s%s - %4d·%02d·%02d" (format "%s%s - %4d·%02d·%02d"
@ -1595,29 +1677,16 @@
(t year))) (t year)))
(weekstring (format " W%02d" iso-week))) (weekstring (format " W%02d" iso-week)))
;; (format (concat "\n"
;; "%9s %s %4d%s\n"
;; "%9s \n"
;; "%9s %-10s\n"
;; "%9s \n"
;; "%9s %s\n")
;; (figlet-num day 0) monthname year weekstring
;; (figlet-num day 1)
;; (figlet-num day 2) dayname
;; (figlet-num day 3)
;; (figlet-num day 4) (sunrise-sunset))
(let ((solar-info (solar-sunrise-sunset-string-list (calendar-current-date))) (let ((solar-info (solar-sunrise-sunset-string-list (calendar-current-date)))
(spacer " ") (spacer " "))
)
(concat "\n" (concat "\n"
(format " %4d·%02d " year month) "\n" (format " %4d·%02d " year month) "\n"
(format "%9s" (figlet-num day 0 2)) spacer (format "%s%s" dayname weekstring) "\n" (format "%9s" (figlet-num day 0 2)) spacer (format "%s%s" dayname weekstring) "\n"
(format "%9s" (figlet-num day 1 2)) spacer (car solar-info) "\n" (format "%9s" (figlet-num day 1 2)) spacer (car solar-info) "\n"
(format "%9s" (figlet-num day 2 2)) spacer (cadr solar-info) "\n" (format "%9s" (figlet-num day 2 2)) spacer (cadr solar-info) "\n"
(format "%9s" (figlet-num day 3 2)) spacer (caddr solar-info) "\n" (format "%9s" (figlet-num day 3 2)) spacer (caddr solar-info) "\n"
(format "%9s" (figlet-num day 4 2)) "\n" (format "%9s" (figlet-num day 4 2)) "\n")))))
)))))
(require 'solar) (require 'solar)
(defun solar-sunrise-sunset-string-list (date &optional nolocation) (defun solar-sunrise-sunset-string-list (date &optional nolocation)
"String of *local* times of sunrise, sunset, and daylight on Gregorian DATE. "String of *local* times of sunrise, sunset, and daylight on Gregorian DATE.
@ -1633,8 +1702,6 @@
(format "%s hours daylight" (format "%s hours daylight"
(nth 2 l))))) (nth 2 l)))))
(solar-sunrise-sunset-string-list (calendar-current-date))
(defun left-right-align (s1 s2) (defun left-right-align (s1 s2)
(concat s1 (make-string (- (window-body-width) (length s1) (length s2)) ?\ ) s2 "\n")) (concat s1 (make-string (- (window-body-width) (length s1) (length s2)) ?\ ) s2 "\n"))
@ -1644,10 +1711,10 @@
(setq org-agenda-format-date #'org-agenda-format-date-figlet) (setq org-agenda-format-date #'org-agenda-format-date-figlet)
(setq org-agenda-prefix-format (setq org-agenda-prefix-format
'((agenda . " %i %6c %s %?-12t") '((agenda . " %i %7c %s %?-12t")
(todo . " %i %6c · ") (todo . " %i %7c · ")
(tags . " %i %6c · ") (tags . " %i %7c · ")
(search . " %i %6c · "))) (search . " %i %7c · ")))
(advice-add 'org-agenda-get-scheduled :around (advice-add 'org-agenda-get-scheduled :around
(lambda (orig-fun &rest args) (lambda (orig-fun &rest args)
@ -3092,7 +3159,9 @@
#+begin_src emacs-lisp #+begin_src emacs-lisp
(byte-recompile-directory "~/.emacs.d/bibretrieve" 0) (byte-recompile-directory "~/.emacs.d/bibretrieve" 0)
(load "bibretrieve") (load "bibretrieve")
(setq bibretrieve-backends '(("msn" . 10))) (setq bibretrieve-backends '(("msn" . 10)
("arxiv" . 10)
("zbm" . 5)))
(require 'biblio) (require 'biblio)
#+end_src #+end_src
@ -3506,7 +3575,10 @@
("C-SPC" . avy-goto-word-or-subword-1) ("C-SPC" . avy-goto-word-or-subword-1)
("M-s" . avy-goto-word-or-subword-1) ("M-s" . avy-goto-word-or-subword-1)
("M-g M-g" . avy-goto-line) ("M-g M-g" . avy-goto-line)
("M-g g" . avy-goto-line))) ("M-g g" . avy-goto-line)
("M-g M-c" . avy-goto-char)
("M-g c" . avy-goto-char)
))
(require 'ace-window) (require 'ace-window)
(global-set-key (kbd "M-o") 'ace-window) (global-set-key (kbd "M-o") 'ace-window)
(setq aw-keys '(?f ?j ?d ?k ?s ?l ?a ?g ?h) (setq aw-keys '(?f ?j ?d ?k ?s ?l ?a ?g ?h)
@ -3540,6 +3612,32 @@
(add-hook 'nov-mode-hook (add-hook 'nov-mode-hook
#'(lambda () (setq-local show-trailing-whitespace nil))) #'(lambda () (setq-local show-trailing-whitespace nil)))
#+end_src
** ediff
#+begin_src emacs-lisp
(setq ediff-window-setup-function 'ediff-setup-windows-plain)
(defvar my-ediff-last-windows nil)
(defun my-store-pre-ediff-winconfig ()
(setq my-ediff-last-windows (current-window-configuration)))
(defun my-restore-pre-ediff-winconfig ()
(set-window-configuration my-ediff-last-windows))
(add-hook 'ediff-before-setup-hook #'my-store-pre-ediff-winconfig)
(add-hook 'ediff-quit-hook #'my-restore-pre-ediff-winconfig)
#+end_src
** Ellama
Set default provider to be mistral (for now eh)
#+begin_src emacs-lisp
(setq ellama-provider
(make-llm-ollama
;; this model should be pulled to use it
;; value should be the same as you print in terminal during pull
:chat-model "llama3"
:embedding-model "nomic-embed-text"
:default-chat-non-standard-params '(("num_ctx" . 8192))))
#+end_src #+end_src
** TODO Phase out Package.el ** TODO Phase out Package.el
Load package.el Load package.el

Loading…
Cancel
Save