From f02d6811c8e8059cf1eb652c8a0cf2030c5092b8 Mon Sep 17 00:00:00 2001 From: bth Date: Wed, 3 Jun 2026 20:27:43 -0700 Subject: [PATCH] minmo : reorder statuses --- packages/minmo.el | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/packages/minmo.el b/packages/minmo.el index d90e9d9..74353f6 100644 --- a/packages/minmo.el +++ b/packages/minmo.el @@ -36,13 +36,13 @@ ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; unified symbol set for git and disk status on tty and pts ;; -;; disk : git +;; git disk ;; ---------------------------------------- ;; unmodified : ◻ : shadow : shadow -;; modified : ◱ : error : warning -;; readonly/ignored : ◳ : success : success -;; orphan/staged : ◰ : warning : link -;; nofile/untracked : ◲ : link : error +;; modified : ◱ : warning : error +;; ignored/readonly : ◳ : success : success +;; staged/orphan : ◰ : link : warning +;; untracked/buffer : ◲ : error : link ;; quadrant semantics: ;; @@ -55,9 +55,9 @@ '( (unmodified . (((unicode . "◻") (ascii . ".")) . ((disk . nil) (git . nil)))) (modified . (((unicode . "◱") (ascii . "*")) . ((disk . error) (git . warning)))) - (readonly/ignored . (((unicode . "◳") (ascii . "_")) . ((disk . success) (git . success)))) - (orphan/staged . (((unicode . "◰") (ascii . "+")) . ((disk . warning) (git . link)))) - (nofile/untracked . (((unicode . "◲") (ascii . "!")) . ((disk . link) (git . error)))) + (ignored/readonly . (((unicode . "◳") (ascii . "_")) . ((disk . success) (git . success)))) + (staged/orphan . (((unicode . "◰") (ascii . "+")) . ((disk . warning) (git . link)))) + (untracked/buffer . (((unicode . "◲") (ascii . "!")) . ((disk . link) (git . error)))) ) "Unified symbol set for git and disk status with unicode and ascii variants and their respective faces.") @@ -152,11 +152,11 @@ Optional FORCE means ignore the minmo--git-directory-table." (concat minmo-git-status-prefix (cond ((string= status " ") (minmo--status 'unmodified 'git)) - ((string= status "!!") (minmo--status 'readonly/ignored 'git)) - ((string= status "??") (minmo--status 'nofile/untracked 'git)) + ((string= status "!!") (minmo--status 'ignored/readonly 'git)) + ((string= status "??") (minmo--status 'untracked/buffer 'git)) ;; report modified whether partially staged or not: ((eq char-work ?M) (minmo--status 'modified 'git)) - ((memq char-index '(?M ?A)) (minmo--status 'orphan/staged 'git)) + ((memq char-index '(?M ?A)) (minmo--status 'staged/orphan 'git)) (t (minmo--status 'unmodified 'git)))))) (defun minmo--update-git-cache (&optional force) @@ -273,15 +273,15 @@ Optional FORCE means ignore the minmo--git-directory-table." (cond ;; readonly: (buffer-read-only - (minmo--status 'readonly/ignored 'disk)) + (minmo--status 'ignored/readonly 'disk)) ;; no file but modified: ((and (not buffer-file-name) (buffer-modified-p)) - (minmo--status 'nofile/untracked 'disk)) + (minmo--status 'untracked/buffer 'disk)) ;; has a path but was never visited or no longer exists. ;; NOTE: visited-file-modtime involves no disk read: ((and buffer-file-name (or (eq -1 (visited-file-modtime)) (not minmo--file-exists-cache))) - (minmo--status 'orphan/staged 'disk)) + (minmo--status 'staged/orphan 'disk)) ;; normally modified: ((and buffer-file-name (buffer-modified-p)) (minmo--status 'modified 'disk))