My Emacs auto-correct is one of the oldest posts on this blog, and I still see
it pop up here and there on occasion. Last week, Norman Ramsey asked about an
improvement to that command and I figured it’s worth an update post.
[...]
What do you do if you want to override a key only in a certain context? Take
this Quotation Marks post as an example. We want to change the " key in
general, but retain the regular behaviour if we’re inside a code-block. In this
case the solution was to just call the old behaviour manually, but what if
you’re writing a more general command and you don’t know what this “old
behaviour” is?
[...]
I’ve written before about what prettify-symbols-mode can do for your buffers,
ranging from pure eye-candy to signficant readability improvements. Simply put,
this minor-mode “disguises” some strings in your buffer to look like something
else. For instance, in emacs-lisp-mode it makes lambda be displayed as λ,
and (for the next release) it’ll apply to a wide range of symbols in
(la)tex-mode too.
[...]
Today’s tip is one I learned from Magnar. A lot of Emacsers don’t know this, but
most commands that move point large distances (like isearch or
end-of-buffer) push the old position to the mark-ring. The advantage is that
you can easily jump back through this history of positions by hitting C-u
C-SPC.
[...]
Although there’s a surprising number of packages offering alternative minibuffer
selection systems, the default minibuffer completion in Emacs is nothing to be
scoffed at. Hitting Tab in the minibuffer gives you a slightly beefed up
version of the bash completion, and after all these years that is still my
preferred method for completing file-names (though I do have some custom-written
alternatives).
[...]
I’m an occasional user of some of the Emacs chat clients. Erc and jabber are
both powerful packages, and it’s great to be able to use Slack, Gitter, and
Google Chat from the cosy comfort of my Emacs frame. If I have one complain,
though, it’s that neither of them has a functionality for keeping track of what
part of the conversation I’ve already read.
[...]
A few weeks ago I noticed a new package on Melpa called github-notifier by
Chunyang, which displays a count of your Github notifications on the mode-line.
Instead of just installing the package like a normal person, I had an urge to
try and see how hard it would be to write from scratch. Paradox already has a
function for interacting with the Github API, so it’s just a matter of putting
it to work.
[...]
I can’t write a whole new post this week due to being buried under some
once-in-a-lifetime stuff. Still, the Monday post is one I refuse to miss, so I
leave you today with an update on last weeks post.
[...]
As I was catching up on a few Parens of the Dead episodes this weekend, I was
amused at how Magnar set up his Emacs to run tests whenever the file is saved.
At first I thought it wasn’t for me (I’m one of those who obsessively saves
every few seconds), but I’ve been trying it out lately and it’s starting to grow
on me.
[...]
The concept of a lazy-map might sounds odd at first. How do you know if a map
contains an entry without resolving the whole map? But it’s not the entries that
are lazy, it’s the values they hold. See this example from the Readme:
[...]
prettify-symbols-mode is a very nice minor-mode that is a little too modest
for its own good. You can turn it on right now if you’re using a recent Emacs,
but it’ll do nothing more than turn lambda into λ in emacs-lisp-mode.
Still, it’s powerful and versatile and deserves that you give it a try. To
extend its feature-set you can install packages or customize it yourself, and
that’s what we’re here to do today, specifically in clojure-mode.
[...]
When I first started learning Clojure, I was charmed by how well integrated
CIDER was with Emacs. In many ways, it felt just like writing Emacs-lisp.
Nowadays, that feeling has gone slightly past the goal mark, and there are
actually features I miss when I’m writing elisp. Clj-refactor is one of them.
[...]
The dot-dot-dot ellipsis that org-mode uses to indicate hidden content is
usually just fine. It’s only when you’re staring at a document where every line
is a folded headline, that you start to feel like they’re a little too much “in
your face”. I have a few org files with thousands of lines and hundreds of
headlines, and changing that ... to something shorter greatly reduces visual
clutter.
[...]
What started out as a cute idea I was playing around with, eventually turned to
be one of my favorite packages. Beacon won’t help you type faster, code
better, or cure cancer like some of the other packages. Its effect is mostly
cosmetic, but with practical benefits. Put simply, if you turn on this minor
mode, whenever the window scrolls up or down a light will blink on your cursor.
That’s it.
[...]
It’s difficult for me to spend much time interacting with a major-mode and not
find something to tweak. Even when that mode is my oldest companion in the world
of Emacs, something will surely pop up. So it’s only fitting that in the final
week of my thesis submission deadline I start tinkering with latex-mode again.
[...]
An improvement to Emacs auto-correct
11 Jan 2016 CommentMy Emacs auto-correct is one of the oldest posts on this blog, and I still see it pop up here and there on occasion. Last week, Norman Ramsey asked about an improvement to that command and I figured it’s worth an update post. [...]
Define context-aware keys in Emacs
05 Jan 2016 CommentWhat do you do if you want to override a key only in a certain context? Take this Quotation Marks post as an example. We want to change the " key in general, but retain the regular behaviour if we’re inside a code-block. In this case the solution was to just call the old behaviour manually, but what if you’re writing a more general command and you don’t know what this “old behaviour” is? [...]
New in Emacs 25.1: Have prettify-symbols-mode reveal the symbol at point
28 Dec 2015 CommentI’ve written before about what
prettify-symbols-mode
can do for your buffers, ranging from pure eye-candy to signficant readability improvements. Simply put, this minor-mode “disguises” some strings in your buffer to look like something else. For instance, inemacs-lisp-mode
it makeslambda
be displayed asλ
, and (for the next release) it’ll apply to a wide range of symbols in(la)tex-mode
too. [...]Faster pop-to-mark command
21 Dec 2015 CommentToday’s tip is one I learned from Magnar. A lot of Emacsers don’t know this, but most commands that move point large distances (like
isearch
orend-of-buffer
) push the old position to themark-ring
. The advantage is that you can easily jump back through this history of positions by hitting C-u C-SPC. [...]Improving Emacs file-name completion
14 Dec 2015 CommentAlthough there’s a surprising number of packages offering alternative minibuffer selection systems, the default minibuffer completion in Emacs is nothing to be scoffed at. Hitting Tab in the minibuffer gives you a slightly beefed up version of the bash completion, and after all these years that is still my preferred method for completing file-names (though I do have some custom-written alternatives). [...]
Marking Emacs chat buffers as read (erc, jabber, etc)
07 Dec 2015 CommentI’m an occasional user of some of the Emacs chat clients. Erc and jabber are both powerful packages, and it’s great to be able to use Slack, Gitter, and Google Chat from the cosy comfort of my Emacs frame. If I have one complain, though, it’s that neither of them has a functionality for keeping track of what part of the conversation I’ve already read. [...]
Using Paradox for Github notifications
30 Nov 2015 CommentA few weeks ago I noticed a new package on Melpa called github-notifier by Chunyang, which displays a count of your Github notifications on the mode-line. Instead of just installing the package like a normal person, I had an urge to try and see how hard it would be to write from scratch. Paradox already has a function for interacting with the Github API, so it’s just a matter of putting it to work. [...]
Update on tdd-mode with CIDER
23 Nov 2015 CommentI can’t write a whole new post this week due to being buried under some once-in-a-lifetime stuff. Still, the Monday post is one I refuse to miss, so I leave you today with an update on last weeks post. [...]
Test-Driven-Development in CIDER and Emacs
15 Nov 2015 CommentAs I was catching up on a few Parens of the Dead episodes this weekend, I was amused at how Magnar set up his Emacs to run tests whenever the file is saved. At first I thought it wasn’t for me (I’m one of those who obsessively saves every few seconds), but I’ve been trying it out lately and it’s starting to grow on me. [...]
New Clojure lib: lazy-map
15 Nov 2015 CommentThe concept of a lazy-map might sounds odd at first. How do you know if a map contains an entry without resolving the whole map? But it’s not the entries that are lazy, it’s the values they hold. See this example from the Readme: [...]
Using prettify-symbols in Clojure and Elisp without breaking indentation
09 Nov 2015 Commentprettify-symbols-mode
is a very nice minor-mode that is a little too modest for its own good. You can turn it on right now if you’re using a recent Emacs, but it’ll do nothing more than turnlambda
intoλ
inemacs-lisp-mode
. Still, it’s powerful and versatile and deserves that you give it a try. To extend its feature-set you can install packages or customize it yourself, and that’s what we’re here to do today, specifically inclojure-mode
. [...]clj-refactor — Unleash your Clojure wizard.
02 Nov 2015 CommentWhen I first started learning Clojure, I was charmed by how well integrated CIDER was with Emacs. In many ways, it felt just like writing Emacs-lisp. Nowadays, that feeling has gone slightly past the goal mark, and there are actually features I miss when I’m writing elisp. Clj-refactor is one of them. [...]
Changing the org-mode ellipsis
02 Nov 2015 CommentThe dot-dot-dot ellipsis that org-mode uses to indicate hidden content is usually just fine. It’s only when you’re staring at a document where every line is a folded headline, that you start to feel like they’re a little too much “in your face”. I have a few org files with thousands of lines and hundreds of headlines, and changing that
...
to something shorter greatly reduces visual clutter. [...]Beacon — Never lose your cursor again
27 Oct 2015 CommentWhat started out as a cute idea I was playing around with, eventually turned to be one of my favorite packages. Beacon won’t help you type faster, code better, or cure cancer like some of the other packages. Its effect is mostly cosmetic, but with practical benefits. Put simply, if you turn on this minor mode, whenever the window scrolls up or down a light will blink on your cursor. That’s it. [...]
Improving LaTeX equations with font-lock
19 Oct 2015 CommentIt’s difficult for me to spend much time interacting with a major-mode and not find something to tweak. Even when that mode is my oldest companion in the world of Emacs, something will surely pop up. So it’s only fitting that in the final week of my thesis submission deadline I start tinkering with
latex-mode
again. [...]Content © 2019, All rights reserved. Icons under CC3.0.