emacs: Fix modeline VC symbols, update lorien.el opened files

This commit is contained in:
2023-12-27 08:20:40 +01:00
parent 6f58b0bddc
commit 3da006ed73
2 changed files with 16 additions and 16 deletions

View File

@@ -756,19 +756,19 @@ in whole buffer. With neither, delete comments on current line."
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; vc-mode modeline ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; vc-mode modeline
;; inspired from: ;; inspired from:
;; https://emacs.stackexchange.com/questions/10955 ;; https://emacs.stackexchange.com/questions/10955
(advice-add #'vc-git-mode-line-string :filter-return #'my-replace-git-status) (advice-add #'vc-git-mode-line-string :filter-return #'my/replace-git-status)
(defun my-replace-git-status (tstr) (defun my/replace-git-status (tstr)
"Replace git `variable:vc-mode' string, for a modified icon followed by TSTR without \"git\"." "Replace git `variable:vc-mode' string with a modified followed by TSTR."
(let* ((tstr (replace-regexp-in-string "Git" "" tstr)) (let* ((tstr (replace-regexp-in-string "Git" "" tstr))
(first-char (substring tstr 0 1)) (first-char (substring tstr 0 1))
(rest-chars (substring tstr 1))) (rest-chars (substring tstr 1)))
(cond (cond
((string= ":" first-char) ; Modified ((string= ":" first-char) ; Modified
(replace-regexp-in-string "^:" "" tstr)) (replace-regexp-in-string "^:" "" tstr))
((string= "-" first-char) ; No change ((string= "-" first-char) ; No change
(replace-regexp-in-string "^-" "" tstr)) (replace-regexp-in-string "^-" "" tstr))
((string= "@" first-char) ; Added ((string= "@" first-char) ; Added
(replace-regexp-in-string "^@" "️✑" tstr)) (replace-regexp-in-string "^@" "" tstr))
(t tstr)))) (t tstr))))
(setf mode-line-modes (setf mode-line-modes
@@ -1170,13 +1170,13 @@ in whole buffer. With neither, delete comments on current line."
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; makefile mode ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; makefile mode
(defun my/makefile-mode-hook () (defun my/makefile-mode-hook ()
"X br text mode hook." "X br makefile mode hook."
(message "entering Makefile-mode") ;; (message "entering Makefile-mode")
(setq indent-tabs-mode t (setq indent-tabs-mode t
tab-width 4 tab-width 8
comment-column 60)) comment-column 60))
(add-hook 'text-mode-hook 'my/text-mode-hook) (add-hook 'makefile-mode-hook 'my/makefile-mode-hook)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; org mode ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; org mode
;; mediawiki export ;; mediawiki export

View File

@@ -35,17 +35,17 @@
(defconst my/loaded-files-at-startup (defconst my/loaded-files-at-startup
(list (list
"~/dev/tools/c/brlib/Makefile"
"~/dev/brchess/Makefile" "~/dev/brchess/Makefile"
"~/dev/tools/c/Makefile" ;;"~/org/boot-disk.org"
"~/org/boot-disk.org" ;;"~/org/beaglebone-buster-setup.org"
"~/org/beaglebone-buster-setup.org"
;;"~/dev/www/cf.bodi/sql/coc.sql" ;;"~/dev/www/cf.bodi/sql/coc.sql"
;;"~/dev/www/cf.bodi/sql/coc-sql.org" ;;"~/dev/www/cf.bodi/sql/coc-sql.org"
user-init-file user-init-file
"~/org/emacs-cheatsheet.org" "~/org/emacs-cheatsheet.org")
;;"~/dev/g910/g910-gkey-macro-support/lib/data_mappers/char_uinput_mapper.py" ;;"~/dev/g910/g910-gkey-macro-support/lib/data_mappers/char_uinput_mapper.py"
"~/dev/advent-of-code/2022/Makefile" ;;"~/dev/advent-of-code/2022/Makefile"
"~/dev/www/com.raoult/devs/php/chess/list-pgn-games.php") ;;"~/dev/www/com.raoult/devs/php/chess/list-pgn-games.php")
;; "~/dev/eudyptula/ID") ;; "~/dev/eudyptula/ID")
"personal files always loaded at startup (no visible window).") "personal files always loaded at startup (no visible window).")