I was always fighting in Emacs between grep (what is the syntax?), igrep-find (why did it suddenly stopped to prompt for directories?), tags-search (ooops some of my files are not tagged) and rgrep (oh it did exist?). I installed ack-and-a-half for Emacs and its great. Ack-and-half tries to find automatically the root directory of your project but you can set ack-and-a-half-prompt-for-directory to true with (setq ack-and-a-half-prompt-for-directory t) for it to ask which directory to search in.
The Ack version on the website provides support for Clojure files. For ClojureScript files, you need to add the following lines to your ~/.ackrc file:
Duplicating a line is extremely useful when editing text and specially when programming. There is no native command in Emacs to achieve that but it's easy to add one.
It's easy to get addicted to the use of this new command but a problem remains when programming in Lisp with paredit.el: duplicating sometimes lead to invalid s-expressions being inserted.
I decided to give it a try and made an implementation that duplicate the s-expressions after the point (cursor).
For instance in Clojure if you are editing this code:
(ns myns
(:use [clojure.string :only [escape]]))
You can duplicate the first vector by placing the cursor on the square bracket, invoking the command with one keystroke and then easily obtain this code:
Here is the code to duplicate the line; to my knowledge there is no such command in paredit.el:
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters