Please create an account to participate in the Slashdot moderation system

 



Forgot your password?
typodupeerror
×
GNU is Not Unix Programming Software IT Technology

(Stupid) Useful Emacs Tricks? 412

Count Fenring writes "Since the Vi version of this question was both interesting and popular, let's hear from the other end of the spectrum. What are your favorite tricks, macros, extensions, and techniques for any of the various Emacs? Myself, I like 'M-x dunnet' ;-)"
This discussion has been archived. No new comments can be posted.

(Stupid) Useful Emacs Tricks?

Comments Filter:
  • Re:Lots of them (Score:2, Insightful)

    by jbaltz ( 219494 ) on Friday November 07, 2008 @10:18AM (#25674959) Homepage Journal

    M-x psychoanalyze-pinhead

  • by McNihil ( 612243 ) on Friday November 07, 2008 @10:23AM (#25675031)

    CTRL-X 1|2|3 to divide the editing area according to wish. I simply can't live without this functionality.

    Now if anyone makes a Firefox plugin making it possible to do the same in a web browser that would be friggin awesome.

  • Re:Notepad tricks (Score:3, Insightful)

    by gEvil (beta) ( 945888 ) on Friday November 07, 2008 @10:51AM (#25675365)
    Well, if you're using Windows XP, the best trick is Win-U-U.
  • by Just Some Guy ( 3352 ) <kirk+slashdot@strauser.com> on Friday November 07, 2008 @10:51AM (#25675371) Homepage Journal

    This is the first content I've seen in years that appeals to Slashdot's original demographics: hardcore geeks who are passionate about the tools they use. I've picked up a few tips in this series of articles and have enjoyed hearing other people learn about "old" stuff for the first time.

    If "(Stupid) Useful $GEEK Tricks" isn't your cup of tea, then please feel free to look elsewhere [digg.com].

  • Re:Huh? (Score:3, Insightful)

    by ByOhTek ( 1181381 ) on Friday November 07, 2008 @11:15AM (#25675657) Journal

    deletions, and ONLY deletions from a file. If there is any adding/changing, I'd sooner sue cat+sed.

  • by Falkkin ( 97268 ) on Friday November 07, 2008 @11:40AM (#25676037) Homepage

    Yeah, given that the *nix thread had over 2000 comments, I'd say there's a significant demand for more of these sorts of posts.

    My only regret is that I wish they'd spaced out the articles a bit, so that I had some time to digest the tricks in one article before reading the next one -- I find that if I add too many tricks to my toolbox at once I tend to forget about some of them. I guess I should just re-read the articles in another month or so. (Also an indication that these are quality articles -- there's not many discussion threads on Slashdot that I'd even consider going back and re-reading later.)

  • Re:I replaced it (Score:4, Insightful)

    by MosesJones ( 55544 ) on Friday November 07, 2008 @11:53AM (#25676247) Homepage

    Congratulations, beating out hot favourites Karl Rove and Dick Cheney you have just won single most arrogant statement of the year

    "I wrote something better"

    When you get several million users then call, until then you've got a pet project doing something that loads of people before you have done, and lots of people after you have done.

    and more people will still be using VI and Emacs

  • Re:Huh? (Score:3, Insightful)

    by volxdragon ( 1297215 ) on Friday November 07, 2008 @12:25PM (#25676619)

    See, there's your problem....Emacs isn't a text editor, it's a development environment with a Turing-complete language in it.

  • Re:Huh? (Score:2, Insightful)

    by yukk ( 638002 ) on Friday November 07, 2008 @02:13PM (#25677879)

    Emacs has a text editor now?

    See, this is why I hate mod points. They're never around when you need them.

  • Re:I replaced it (Score:3, Insightful)

    by dunkelfalke ( 91624 ) on Friday November 07, 2008 @03:38PM (#25679535)

    there are far more notepad users than vi and emacs users together.
    that does not mean, that notepad is a great text editor, though.

  • Re:Some favorites (Score:4, Insightful)

    by Dolda2000 ( 759023 ) <fredrik.dolda2000@com> on Friday November 07, 2008 @03:51PM (#25679805) Homepage

    (global-set-key "\C-z" 'undo)

    You mention undo only as such, but I'd like to add that the undo functionality really is one of Emacs' killer functions. See, when you undo a string of commands in Emacs, it doesn't just discard that part of the undo history as most (all?) other editors do, but it folds it backwards onto the undo stack, which is unbelievably useful.

    I often use it as a sort of short-term, local version control. I can type something, try it, undo it and type something else, try that, and then undo back to the first version if I weren't satisfied with the second. It also enables me to use undo as a sort of short-term memory extension in that I can hack around a bit, and then interrupt myself for a visit to the toilet or similar. Then, when I get back, I can check exactly what I was doing before I left by just undoing a bit, and then undo the undoings.

    I don't think I'd ever be able to use an editor that doesn't have Emacs' killer undo.

It appears that PL/I (and its dialects) is, or will be, the most widely used higher level language for systems programming. -- J. Sammet

Working...