El-get can install and update elisp from git, svn, http, and EmacsWiki. (It also wraps ELPA and apt-get where packages exist.)
If el-get doesn't have a recipe for your favorite Emacs extension, please consider adding the recipe and pushing to GitHub. (It doesn't take long - most recipes are only a few lines long.) Don't forget to issue a pull request for the rest of us.
It takes about five minutes to take a library that isn't packaged and publish it on Marmalade, and then anyone can depend upon it.
el-get made lots of sense back in the day when package.el only supported tromey.com, but now that there's a community repository I don't see the point.
OK. My old complaints against package.el were as follows:
1. Packages need to be updated manually by maintainers. I can't use package.el to install the master branch of my favorite project on GitHub, or an old snippet on EmacsWiki.
2. Marmalade (the community repository) has licensing requirements for package inclusion.
> 1. Packages need to be updated manually by maintainers.
Yes, but considering uploading new versions can be done with M-x marmalade-upload-buffer, generally Marmalade encourages short release cycles. So there's not much reason to ever work from master unless you're hacking on it yourself, in which case you already have it checked out.
> 2. Marmalade (the community repository) has licensing requirements for package inclusion.
This is not specific to Marmalade since Emacs itself has licensing requirements. Every elisp library is a derivative work of Emacs itself, therefore it must be distributed under the same license.
EDIT: Perhaps you're thinking of elpa.gnu.org? That repository requires copyright assignment for libraries to be included, but Marmalade does not.
I think you're slightly confused about el-get's purpose: it isn't to replace package.el. el-get supplements package.el and provides options for people who want to run the latest and greatest versions of libraries, or who can't be bothered to monitor the odd elisp snippet and update Marmalade every time it changes.
Personally, I find el-get recipes so easy to install and create that I never use package.el at all, but that isn't the goal of el-get developers.
Here is an example recipe for el-get. I haven't tried creating uploading anything to Marmalade yet, so I can't compare the ease of use.
One last note: You may find that el-get lowers the barrier for contributing to libraries. If you find the odd bug in a mode you use, the source code is always checked out in ~/.emacs.d/el-get and it would be practically criminal to not fix it. With package.el, you have to reinstall the library first.
You're right, of course, but only because the Emacs community chose an inferior solution to begin with. Let the better package manager win. Don't tell people not to use el-get because it is so convenient that they wont use package.el anymore.
I can't switch away from Notepad++ to any editor that lacks instantaneous, no-hassle (no extra key presses), buttery smooth current buffer word auto-complete.
Hi-lock lets you specify regexes to highlight anywhere in a file; it's like domain-specific font-lock.
It's astoundingly useful in code review. For instance, given a giant blob of J2EE web handler code, I can eyeball one handler, recognize the annotation mapping the method to URL syntax, and then punch in a hi-lock regex to light up similar annotations everywhere in the file, then glance through the whole file looking for color patterns. I can read any of those functions and recognize the code that checks "am I an admin", hi-lock it, and then quickly spot any function mapped to a URL that doesn't check admin credentials.
That's just one tiny use case. I used hi-lock so much I ported it into our web-based code review tool. I converted one person to Emacs just to get that feature (my office would be thrilled if someone could point out the vim package that does the same thing).
CUA column editing (CTR-SPC arrow-arrow-&c type-type-&c) is probably my #2.
Late edit:
Holy hell how do you forget magit! Magit is a near-complete UI for git; it figures out what git repo you're working from, and then gives you up-to-date status on the contents of your checkout, spots untracked files, allows you to visually stage your commits, gives you single-key revert and a browsable repo history.
Magit is one of the rare Emacs extensions that not only improves Emacs but also the external service it integrates with. I am actually a better git user (or, git is just better) when I've got magit running.
Occur also works nicely for this use case, as you can visit each place in order with C-x `. Actually, something like eproject-grep is even nicer, because you can visit every occurrence in the project that way.
I didn't know about occur, which is awesome and thanks. The benefit of hi-lock is that I can "read" code without actually having to "read" it.
Instead, I can either set myself up to look for patterns of colors (function --- red line --- shit no blue line!), or set myself to serendipitously discover things as I actually do read code.
I have never, ever, ever, ever figured out an Emacs "grep" that I liked enough to stop using find/xargs/grep from eshell.
I haven't, but I don't have a problem with grep, so much as I find there's exactly enough friction with Emacs grep integration to prevent me from ever taking advantage of it.
Presumably the friction involves the fact that you have to tell Emacs the command to run before entering the search you want to do, making sure that you type exactly the find | [e]grep command you want. Then, grep, egrep, perl, and emacs all use different regular expression syntax, so you're never really sure what to type, and you are bound to have to try a few times. (Quiz: how do you search for a literal paren?)
Ack solves this by using Perl regular expressions and a built-in include/exclude list, which is annoying because you'll have to tell Emacs to tell Ack which one to use.
eproject-grep abstracts away having to type any commands or enter an include/exclude list (since the whole point of eproject is to maintain that information), but you'll still have to guess whether it's going to use grep or egrep and type the regular expression right.
multi-occur will use Emacs regular expressions, but only on open buffers.
So I guess the solution is to use eproject to open the correct buffers, and then use multi-occur on them. I will implement that and see if I like it. Perhaps you might too.
I've been trying to figure out a good way to do this for a while in vim, and can't say I've found much. The best i can figure is something to this effect:
highlight LowVis ctermbg=233 guibg=233 ctermfg=240
syn region LowVis start="\s*log_" end=";" contains=LowVis oneline
Out of curiosity, do you use usually emacs for J2EE code?
I am an emacs user, but have been doing some J2EE stuff for the last few months, and have been getting really annoyed by the IDE's lately, and I was wondering if it was a wise choice to go with emacs for Java too.
I don't build J2EE apps; I just break them. We built our own code reviewing tool internally, which is what I use now, but I spent a few months reviewing things in Emacs deliberately once I learned about hi-lock mode.
I still do all my real dev in Emacs and have more than once put hi-lock to good use there.
Indeed. Java is only different from the rest of the world if you use Eclipse and think its defaults are sane. For everyone else, you write some sort of build script that builds your project, and that's as easy to run from Emacs as it is from anywhere else.
I've "only" been using it since 1998, but I always skim threads like this -- even lots of short articles -- because there's nearly always something new to discover! Sometimes it's hard not to gush, but it's just such an amazing and organic piece of software.
Org-mode is what finally converted me to being an emacs user.
I'd been searching for a lightweight, console/cli-mode outliner/task-manager when it occurred to me "surely emacs has something for this". It did, of course.
For several weeks I used emacs only for org-mode. Slowly but surely emacs started to take over my more and more of my editing tasks. Now I find myself not even bothering to launch X, but simply emacs from the Linux console (run level 3?). It's amazing how responsive a computer is when you're not using any gui at all.
I've since discovered that org-mode is pretty common gateway into emacs.
I personally don't think that default is silly. I've noticed that some (usually less important) questions use y or n already; the yes/no is reserved for important ones. I don't mind having to type a bit more before recursively deleting a directory, for example.
`ansi-term` is probably is for me. Integrating your terminal closer with your editor is really amazing. Using `multi-term` to make it easier to handle multiple terminals, and you've got a really nice integrated environment.
on a side note, whenever i asked such open ended question on stackoverflow, it would quickly get closed by some other user claiming that "there is no right answer" and the question must be closed. But there are so many great open ended questions on there that score so high among users. i guess it's a matter of luck that some anal retentive person doesn't get to it first?
It's not exactly luck. Until today this question hasn't been active since 2009, when opened-ended questions were permitted. Now that it's been bumped it'll be closed shortly.
I like idomenu, which lists variable/function definitions in your file. When you combine it with ido-menu, it's magic. Bind it to C-c s, and you get a list of symbols you can navigate extremely fast.
The downside is that if the symbol locations change in a file, you'd have to refresh it. :(
The single most useful Emacs feature is the design of Emacs as a platform for hosting ELisp. Without ELisp, and the OS and text editing services provided by the Emacs run-time, none of these extensions would be possible.
Too hard to pick one, it depends on the task.
Maybe I'd go with M-x Occur.
Other candidates are regex i-search, registers, yasnippet, kill/copy/(insert)string-rectangle, etc etc.
for me it has to be comint mode and every mode that wraps comint. I run M-x shell all the time, being able to use all my favourite editing commands to go back through shell history is just killer.
It's interesting that it's hard to explain, because the fingers will play the chord by themselves and I need to stop and think to know what I am actually typing.
C-x r k to cut a rectangle, and C-x r t to add one filled with, for example, the comment symbol:
Holy crap, thank you very much! Looks like cua-mode rectangle select might actually be the equal of Visual Studio's very straightforward rectangle selections...
plays the macro until it rings the bell (e.g. runs out of buffer space or tries to forward-search for a name that doesn't exist. This is great when you don't know how many times it needs to be run.
111 comments
[ 2.5 ms ] story [ 206 ms ] threadhttps://github.com/dimitri/el-get
El-get can install and update elisp from git, svn, http, and EmacsWiki. (It also wraps ELPA and apt-get where packages exist.)
If el-get doesn't have a recipe for your favorite Emacs extension, please consider adding the recipe and pushing to GitHub. (It doesn't take long - most recipes are only a few lines long.) Don't forget to issue a pull request for the rest of us.
el-get made lots of sense back in the day when package.el only supported tromey.com, but now that there's a community repository I don't see the point.
1. Packages need to be updated manually by maintainers. I can't use package.el to install the master branch of my favorite project on GitHub, or an old snippet on EmacsWiki.
2. Marmalade (the community repository) has licensing requirements for package inclusion.
Are those two assumptions incorrect?
Yes, but considering uploading new versions can be done with M-x marmalade-upload-buffer, generally Marmalade encourages short release cycles. So there's not much reason to ever work from master unless you're hacking on it yourself, in which case you already have it checked out.
> 2. Marmalade (the community repository) has licensing requirements for package inclusion.
This is not specific to Marmalade since Emacs itself has licensing requirements. Every elisp library is a derivative work of Emacs itself, therefore it must be distributed under the same license.
EDIT: Perhaps you're thinking of elpa.gnu.org? That repository requires copyright assignment for libraries to be included, but Marmalade does not.
I think you're slightly confused about el-get's purpose: it isn't to replace package.el. el-get supplements package.el and provides options for people who want to run the latest and greatest versions of libraries, or who can't be bothered to monitor the odd elisp snippet and update Marmalade every time it changes.
Personally, I find el-get recipes so easy to install and create that I never use package.el at all, but that isn't the goal of el-get developers.
Here is an example recipe for el-get. I haven't tried creating uploading anything to Marmalade yet, so I can't compare the ease of use.
https://github.com/dimitri/el-get/blob/master/recipes/evil.r...
One last note: You may find that el-get lowers the barrier for contributing to libraries. If you find the odd bug in a mode you use, the source code is always checked out in ~/.emacs.d/el-get and it would be practically criminal to not fix it. With package.el, you have to reinstall the library first.
That's my main objection. If you write an el-get recipe, it benefits el-get users. If you use package.el, all users (of Emacs 24+) benefit.
You're right, of course, but only because the Emacs community chose an inferior solution to begin with. Let the better package manager win. Don't tell people not to use el-get because it is so convenient that they wont use package.el anymore.
Hi-lock lets you specify regexes to highlight anywhere in a file; it's like domain-specific font-lock.
It's astoundingly useful in code review. For instance, given a giant blob of J2EE web handler code, I can eyeball one handler, recognize the annotation mapping the method to URL syntax, and then punch in a hi-lock regex to light up similar annotations everywhere in the file, then glance through the whole file looking for color patterns. I can read any of those functions and recognize the code that checks "am I an admin", hi-lock it, and then quickly spot any function mapped to a URL that doesn't check admin credentials.
That's just one tiny use case. I used hi-lock so much I ported it into our web-based code review tool. I converted one person to Emacs just to get that feature (my office would be thrilled if someone could point out the vim package that does the same thing).
CUA column editing (CTR-SPC arrow-arrow-&c type-type-&c) is probably my #2.
Late edit:
Holy hell how do you forget magit! Magit is a near-complete UI for git; it figures out what git repo you're working from, and then gives you up-to-date status on the contents of your checkout, spots untracked files, allows you to visually stage your commits, gives you single-key revert and a browsable repo history.
Magit is one of the rare Emacs extensions that not only improves Emacs but also the external service it integrates with. I am actually a better git user (or, git is just better) when I've got magit running.
Instead, I can either set myself up to look for patterns of colors (function --- red line --- shit no blue line!), or set myself to serendipitously discover things as I actually do read code.
I have never, ever, ever, ever figured out an Emacs "grep" that I liked enough to stop using find/xargs/grep from eshell.
There are some ack-modes for emacs, too, eg. https://github.com/nschum/full-ack
Ack solves this by using Perl regular expressions and a built-in include/exclude list, which is annoying because you'll have to tell Emacs to tell Ack which one to use.
eproject-grep abstracts away having to type any commands or enter an include/exclude list (since the whole point of eproject is to maintain that information), but you'll still have to guess whether it's going to use grep or egrep and type the regular expression right.
multi-occur will use Emacs regular expressions, but only on open buffers.
So I guess the solution is to use eproject to open the correct buffers, and then use multi-occur on them. I will implement that and see if I like it. Perhaps you might too.
http://www.vim.org/scripts/script.php?script_id=2666
<Leader>r (regex) to add matches to the set of highlighted groups.
I am an emacs user, but have been doing some J2EE stuff for the last few months, and have been getting really annoyed by the IDE's lately, and I was wondering if it was a wise choice to go with emacs for Java too.
I still do all my real dev in Emacs and have more than once put hi-lock to good use there.
I'd rather eat a bug than use Eclipse.
My favorite Emacs feature that I've learned about in the past year is Org-Mode. I use it now for just about everything.
I'd been searching for a lightweight, console/cli-mode outliner/task-manager when it occurred to me "surely emacs has something for this". It did, of course.
For several weeks I used emacs only for org-mode. Slowly but surely emacs started to take over my more and more of my editing tasks. Now I find myself not even bothering to launch X, but simply emacs from the Linux console (run level 3?). It's amazing how responsive a computer is when you're not using any gui at all.
I've since discovered that org-mode is pretty common gateway into emacs.
Not sure why you were downvoted.
Regional undo/redo is a close second.
That's probably the killer feature for me.
I'm actually surprised that someone hasn't gone through all the older questions looking for stuff to close, given how rigid their mods tend to be.
Transpose the current line with the previous line.
The downside is that if the symbol locations change in a file, you'd have to refresh it. :(
http://stackoverflow.com/questions/1218390/what-is-your-most...
Trite but true!
Also, emacsclient.
(http://www.emacswiki.org/emacs/UndoTree) Scroll down for screenshot.
And follow-mode on a monitor turned sideways is pretty funny. Doubles your vertical space (good for eyeballing logs and data dumps).
C-x r k to cut a rectangle, and C-x r t to add one filled with, for example, the comment symbol:
(C-space)this
to comment
C-x r t #
#this
#to comment
Actually, that would be M-9 M-9 C-x e or C-u 99 C-x e.