[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] scratch/dired-git-info 23b3d1e 18/33: Improve auto hide details
From: |
Clemens Radermacher |
Subject: |
[elpa] scratch/dired-git-info 23b3d1e 18/33: Improve auto hide details |
Date: |
Sun, 17 Feb 2019 13:03:30 -0500 (EST) |
branch: scratch/dired-git-info
commit 23b3d1eeedf73beaf1dcb475c59eaea85e547021
Author: Clemens Radermacher <address@hidden>
Commit: Clemens Radermacher <address@hidden>
Improve auto hide details
---
dired-git-info.el | 10 +++++++---
1 file changed, 7 insertions(+), 3 deletions(-)
diff --git a/dired-git-info.el b/dired-git-info.el
index 2a16dd1..96ab8e1 100644
--- a/dired-git-info.el
+++ b/dired-git-info.el
@@ -33,7 +33,7 @@
'((t (:inherit font-lock-comment-face)))
"Face for commit message overlays.")
-(defvar dgi-auto-hide-details t
+(defvar dgi-auto-hide-details-p t
"If details should get hidden automatically.
Uses `dired-hide-details-mode' to hide details when showing git
@@ -73,6 +73,8 @@ are (see git-log PRETTY FORMATS for all):
(defvar-local dgi--commit-ovs nil
"Overlays which show the commit messages.")
+(defvar dgi--restore-no-details-p nil
+ "If no details view has to be restored.")
(defun dgi--command-to-string (program &rest args)
"Execute PROGRAM with arguments ARGS and return output string."
@@ -122,7 +124,8 @@ info format and defaults to `dgi-commit-message-format'."
(defun dgi--cleanup ()
"Remove commit overlays."
- (when dgi-auto-hide-details
+ (when dgi--restore-no-details-p
+ (setq dgi--restore-no-details-p nil)
(dired-hide-details-mode -1))
(dolist (ov dgi--commit-ovs)
(delete-overlay ov))
@@ -176,8 +179,9 @@ info format and defaults to `dgi-commit-message-format'."
(user-error "Not inside a git repository"))
(if dgi--commit-ovs
(dgi--cleanup)
- (when dgi-auto-hide-details
+ (when dgi-auto-hide-details-p
(unless dired-hide-details-mode
+ (setq dgi--restore-no-details-p t)
(dired-hide-details-mode 1)))
(let* ((files (dgi--save-marked
(dired-unmark-all-marks)
- [elpa] branch scratch/dired-git-info created (now cd60dd4), Clemens Radermacher, 2019/02/17
- [elpa] scratch/dired-git-info fb1b475 02/33: Rename internal symbols accord. to elisp conventions, Clemens Radermacher, 2019/02/17
- [elpa] scratch/dired-git-info 19d9570 04/33: Fix macro name, Clemens Radermacher, 2019/02/17
- [elpa] scratch/dired-git-info 64901c7 11/33: Show error if not in a repo, Clemens Radermacher, 2019/02/17
- [elpa] scratch/dired-git-info 2374729 06/33: Update config instructions, Clemens Radermacher, 2019/02/17
- [elpa] scratch/dired-git-info 03c1711 19/33: Fixes according to checkdoc, Clemens Radermacher, 2019/02/17
- [elpa] scratch/dired-git-info 2d57f89 12/33: Check for non existing files, Clemens Radermacher, 2019/02/17
- [elpa] scratch/dired-git-info e4090fa 01/33: Initial commit, Clemens Radermacher, 2019/02/17
- [elpa] scratch/dired-git-info 23b3d1e 18/33: Improve auto hide details,
Clemens Radermacher <=
- [elpa] scratch/dired-git-info f7b5920 26/33: Improve dgi--get-commit-messages, Clemens Radermacher, 2019/02/17
- [elpa] scratch/dired-git-info 2e986ce 25/33: Allow command to run for dired derived modes, as well, Clemens Radermacher, 2019/02/17
- [elpa] scratch/dired-git-info 11a6cce 05/33: Update install instructions, Clemens Radermacher, 2019/02/17
- [elpa] scratch/dired-git-info 7803b82 16/33: Only mention some common options for message format docstring, Clemens Radermacher, 2019/02/17
- [elpa] scratch/dired-git-info f2117c8 28/33: Add .gitignore, Clemens Radermacher, 2019/02/17
- [elpa] scratch/dired-git-info 1c4ff64 23/33: Remove redundant :group declarations, Clemens Radermacher, 2019/02/17
- [elpa] scratch/dired-git-info cd60dd4 33/33: Check visible part of file names for right formatting, Clemens Radermacher, 2019/02/17
- [elpa] scratch/dired-git-info 3280075 22/33: Update descriptions, Clemens Radermacher, 2019/02/17
- [elpa] scratch/dired-git-info 069695c 10/33: Update screenshot, Clemens Radermacher, 2019/02/17
- [elpa] scratch/dired-git-info 51135d8 07/33: Use actual displayed width of filename to determine spacing, Clemens Radermacher, 2019/02/17