Skip to content

Commit 9c7a927

Browse files
authored
Merge pull request #61 from DivineDominion/patch-1
add instructions to diminish all modes
2 parents f6590a4 + a48d58d commit 9c7a927

File tree

1 file changed

+54
-0
lines changed

1 file changed

+54
-0
lines changed

README.org

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,60 @@ configuration file:
5858
You can also decide to only activate beginend for some of its
5959
supported major modes (e.g., through ~beginend-dired-mode~).
6060

61+
*** init.el example configuration
62+
63+
Vanilla Emacs ~init.el~:
64+
65+
#+BEGIN_SRC emacs-lisp
66+
(require 'beginend)
67+
(beginend-global-mode)
68+
#+END_SRC
69+
70+
Configuration with the popular [[https://github.com/jwiegley/use-package][use-package]] macro:
71+
72+
#+BEGIN_SRC emacs-lisp
73+
(use-package beginend
74+
:ensure t
75+
:demand t
76+
:config
77+
(beginend-global-mode))
78+
#+END_SRC
79+
80+
** Cleaning up the modeline
81+
82+
By default, beginend adds the ~be~ lighter to the modeline.
83+
84+
You can use [[https://github.com/myrjola/diminish.el][diminish.el]] or [[https://savannah.nongnu.org/projects/delight][delight.el]] to turn this off for every minor
85+
mode beginend defines by looping over the ~beginend-modes~ variable.
86+
Note that you will /also/ need to "turn off the lights" for
87+
~beginend-global-mode~, which is not part of this list.
88+
89+
If you usually diminish all minor modes, I recommend using [[https://melpa.org/#/minions][minions.el]].
90+
91+
In the following snippets, you can replace ~delight~ with ~diminish~ for
92+
similar results.
93+
94+
Adapting the vanilla Emacs ~init.el~:
95+
96+
#+BEGIN_SRC emacs-lisp
97+
(require 'beginend)
98+
(dolist (mode (cons 'beginend-global-mode (mapcar #'cdr beginend-modes)))
99+
(diminish mode))
100+
(beginend-global-mode)
101+
#+END_SRC
102+
103+
Adapting the [[https://github.com/jwiegley/use-package][use-package]] macro configuration:
104+
105+
#+BEGIN_SRC emacs-lisp
106+
(use-package beginend
107+
:ensure t
108+
:demand t
109+
:config
110+
(dolist (mode (cons 'beginend-global-mode (mapcar #'cdr beginend-modes)))
111+
(diminish mode))
112+
(beginend-global-mode))
113+
#+END_SRC
114+
61115
** Using
62116

63117
At this point, newly opened supported buffers will get improved

0 commit comments

Comments
 (0)