emacs

Is it possible to evaluate entire buffer in Emacs?

Hello. In order to evaluate elist in Emacs i need to position cursor on the last parenthesis and emit C-x e. But is it possible to evaluate a text in entire buffer as a single elisp program without a need to position cursor etc? ...

Can't activate 'remember' in org-mode

I can't get 'remember' to work in org-mode of emacs. I'm on snow leopard. I added (global-set-key (kbd "C-M-r") 'org-remember) to my .emacs file but when I try to use that shortcut it says: Wrong type argument: commandp, remember So I added (org-remember-insinuate) and when I start emacs it says: symbol's function definition is vo...

egg git interface for emacs, commit message empty

I'm using egg (emacs got git) as git interface in emacs. Whenever I try to achieve a commit --amend, I receive a "GIT-COMMIT-AMEND> Aborting commit due to empty commit message". This is what i do: C-u C-x v c Then the commit buffer appears, with the message of my previous commit. Then upon C-c C-c I get the message stated above: emp...

How do I search for two separate text strings in an emacs buffer SIMULTANEOUSLY?

For example, I open a file called "abc.txt". Now I want to search for all occurrences of "he is" and "first" simultaneously. I want to be able to do a search forward i.e. Ctrl-s and I'll reach the next instance of either of the two search strings. ...

Can I automatically follow a header file in Emacs?

If I come across something like #include "somewhere/myheader.h" can I automatically jump to that header somehow? (Similar to how gtags works?) ...

What is the most efficient way to run programs in Emacs after M-x compile 'ing.

I have started using M-x compile to compile programs in say, C. What is the most efficient way to run the executable e.g. a.out. At the moment I'm using M-! ./a.out. Basically, what is the best code-compile-run procedure to follow? Almost all the tutorials mention how compilation is done, but I haven't seen one which addressed this iss...

How to always turn off hi-line-mode, i.e., globally

Hi - I use Cocoa Emacs 23.1.91 and I want to always have hl-line-mode turned off as I don't like using it. I can turn it off per buffer via M-x hl-line-mode, but that is tedious. Any help is appreciated! Thanks ...

How to stop emacs from replacing underbar with <- in ess-mode

ess-mode is "Emacs speaks statistics." This mode is useful for editing programs for R or Splus (two separate statistics packages). In my buffer, when ever I type '_' the character is replaced with "<-" which is very frustrating. Is there a emacs lisp statement to turn off this behavior? Thanks, SetJmp emacs: 22.1.1 ess-mode release ...

How do I stop Emacs automatically inserting hyphens at the beginning of new lines in fundamental fill mode

Hi there, I'm jotting down some notes in Emacs in Fundamental Fill mode. I'm starting each one of my notes with a "-" on a new line. The problem is, whenever one of the notes I'm writing is too long to fit on a single line, it gets pushed down to the next line (which I want to happen) but Emacs goes ahead and automatically inserts ano...

Identifying PHP unused variables (in Emacs)?

Is it somehow possible to identify unused variables in a PHP file in Emacs? With other languages, this is possible by using tools such as flymake. I've already enabled Flymake to show syntax errors for my PHP files on the fly, but still it's frustrating that PHP logic errors are sometimes due to situations like: <?php $foo = whatever()...

emacs: why does what-cursor-position return less than the expected value?

Suppose I have a source file that is 18218 bytes. I open the file in emacs, then do: M-x end-of-buffer M-x what-cursor-position Why does the cursor position return 17612 bytes? I think it's because of CRLF translation, or collapsing CRLF into one character. How can I get emacs to report the accurate, untranslated character posit...

Create more than one eshell instance in emacs

Think: tiling my emacs window with eshells, a la xmonad. Is this possible? I can M-x eshell to open the first eshell instance but future invocations just focus the first instance. ...

Emacs braces indentation

I can't for the life of me find any answer to this through conventional Internet means, so I'm hoping for some help. Emacs for me right now tends to do indentation on braces as follows: if( ... ) { } Which I find incredibly irritating; I've never even seen this behaviour anywhere else. At any rate, the behaviour I'm expecting i...

How do I get Emacs to evaluate a file when a frame is raised?

Basically I have my Emacs set up so it has a GUI specific elisp, but when starting it in daemon mode this doesn't evaluate. The code is something like: ;; gui.el (when window-system (progn ;; do stuff here )) I'd like this file (or at least the code within it—perhaps a funtion) to be re-evaluated when I run emacsclient -c on...

Is it possible to auto-regenerate and load tags table in emacs rather than having to keep running visit-tags-table ?

I am trying to find a way to auto-regenerate tags for my application and visit those tags in emacs to try to improve my workflow. Is it possible to get emacs to detect changes in TAG file and re-visit it ? ...

How to format all files under a dir in emacs?

In emacs, I format a file as: 1) C-x h (or M-x mark-whole-buffer) 2) C-M-\ (or M-x indent-region) I need help show me how to format all files under a dir? ...

Integrating emacs org-mode with email?

Has anyone does this successfully? I searched a lot but didn't find anything which worked. Before spending time myself, I just want to ask if someone has done this and would be willing to share it. :) For example, I would like to email the agenda to myself daily, reminders when a task is nearing deadline, etc. ...

How can I get org-mode in stickies?

I'm an emacs user on OSX (with Aquamacs) and I also like to use Stickies.app. What I would really like is a way to use org-mode functionality inside of stickies, but I would settle for a sticky-like window. What I want: Org-mode keybindings and functionality Separate window/frame with minimum chrome The ability to make the window "Flo...

Has anyone gotten VB highlighting to work in Emacs23?

I have found and installed the visual basic mode for emacs. It seems to be loading on emacs startup and the VB mode loads when I open a *.bas file. The code is not highlighted at all, however. I'm using Emacs23, tried it with 21 and saw no difference. Background for the curious: I am rewriting a set of codes from VB to Python. The synt...

Emacs: any good guide about creating syntax highlighting for custom language?

Hello. Does anyone knows a good guide on how to create a syntax highlighting for custom language in emacs? ...