emacs

How to run django shell from Emacs?

I'd like to be able to run ./manage.py shell in an Emacs buffer, with all the nice stuff that you get from ipython, like magic commands and autocompletion. Ideally I would also like to be able evaluate code from a buffer to the django shell. Is this possible? ...

Debugging Scheme in Emacs

I am shifting from DrScheme to Emacs to edit my PLT Scheme files. Can you teach me how to use steppers or debuggers in Emacs? Thanks. ...

commands from .bashrc not available in emacs

I have some aliases and functions defined in ~/.bashrc. I start emacs from a terminal window using emacs -nw When I execute M-x shell-command, the aliases and functions from ~/.bashrc are not available, but give a "command not found". I've googled quite a bit but all the posts I come across say, if I understand them correctly, that...

How to tag text in emacs

I'm developing a text annotation system in emacs, where the format of the annotation is something like this. If this is the text: Lorem ipsem por favor I need to annotate it like this: {latin}Lorem imsem{/latin} {spanish}por favor{/spanish} So what I want to do is select a region and then run a function or a macro that will prompt...

How to configure firefox to run emacsclientw on certain links?

I've got a Perl script that groks a bunch of log files looking for "interesting" lines, for some definition of interesting. It generates an HTML file which consists of a table whose columns are a timestamp, a filename/linenum reference and the "interesting" bit. What I'd love to do is have the filename/linenum be an actual link that wi...

Emacs setting key binding

Hi! I am trying to create a command which will allow to move other window up/down depending on keybinding I assigned to it: So what I added to my .emacs: (defun scroll-down-one-line () (scroll-other-window 1)) (glob...

emacs 23 hangs on python mode when typing string block """

My emacs hangs (Ubuntu 9 + emacs 23 + pyflakes) when I type """ quotes for string blocks. anybody experience the same problem? I think, it may not be the emacs problem but some python mode or pyflakes which I use it for error checking. Anybody hot around the issue? It really frustrating experience. ...

Emacs: function that writes down an elisp code that adds a keybinding specified by the user.

How can I make an interactive function that interactively read a key from the user (like when you press C-h k) and then writes some line like this: (global-set-key (kbd "C-x C-s") 'hello) where the "C-x C-s" part is replaced appropriately with the read key. Some beginning users have problem making keybindings and in fact I get confus...

Elisp List Contains a Value

How do you check, in elisp, if a list returns a value? so the following would return t: (contains 3 '(1 2 3)) but (contains 5 '(1 2 3)) would return nil. ...

Show trailing whitespace on emacs only on non-empty lines

Right now I'm using: (setq show-trailing-whitespace t) In my .emacs to show trailing whitespace for my CC mode. I can't seem to figure out how to have it not show the whitespace font for whitespace only lines. Empty lines separating indenting code are sometimes indented at the code level and sometimes not indented at all, and I don't...

Emacs auto-save on switch buffer

Call me lame, but I'm tired of my subconscious C-x C-s nervous twitch. I am switching buffers often enough and I think I would like to save a certain buffer as soon as I switch to another. I have not had the time yet to learn Emacs-Lisp basics. Any hints on how to do this, or better solutions? (On a related note, I found an autosav...

Emacs ESS: Eval region vs. source()

I love the Emacs ESS combination. I love sending lines, functions, regions, and buffers of code to the command line for evaluation without using the mouse. However, I've noticed that the Eval Function command in Emacs is much slower than simply running source("fns.R"), where fns.R is the file that contains the function I want to eval...

emacs: visual-line-mode and fill-paragraph...

Hi, I am now using Emacs 23 with visual-line-mode turned of for text editing but keep hitting M-q out of habit (thus adding hard-wrapping line endings...). I wonder if there is a way to add a conditional to disable fill-paragraph (or remove the binding to M-q) for modes in which visual-line-mode is turned on, but to re-enable it for thos...

emacs defadvice on python-mode function

Hi! In python-mode, there is a function called py-execute-region which sends a highlighted region of code to the Python buffer for evaluation. After evaluation, the cursor is in the Python buffer, but I would prefer that it remain in the script buffer so I can continue producing more code. I wrote a simple advising function: (defadvice ...

Deep dark secrets of Emacs?

Possible Duplicate: The single most useful Emacs feature So, there is this question for Vim users that keeps popping up in my feed reader, but I'm an Emacs person. So, what are some of the cool little hacks and tricks you've come up with using Emacs? And like the Vim thread, I'm talking about the things that only a very few ...

Emacs FTP not working for certain sites in Ubuntu

This is really confusing me, because however much I search I don't seem to be able to come across this problem on Google. I'm trying to edit files on a web server using Emacs Ange-FTP on Ubuntu. I type in /[email protected]:/, Emacs then prompts for a password, which I give, and then it says: Listing /[email protected]:/... forever. ...

Find-file with a hint?

Is there a way to give the 'find-file' function a hint? I'm working with files in the same directory on a remote server, and I'm getting tired of typing in the machine name, and directory structure all the time. It would sure be great if I could write a function that would bring up the find-file prompt with the machine name and directo...

Why do I start iswitchb-mode this way?

According to the emacs info page, here's how you enable iswitchb-mode: To enable Iswitchb mode, type M-x iswitchb-mode, or customize the variable iswitchb-mode to t So I put the following in my .emacs: (setq iswitchb-mode t) However, this doesn't seem to work. After searching the emacs wiki, I found that I need to use this: ...

I get lots of warning and errors when installing Clojure in Emacs

I used the EPL package manager and installed the clojure -mode.el v1.5 I get these errors while installing the major mode In clojure-mode: clojure-mode.el:174:34:Warning: reference to free variable `paredit-mode' clojure-mode.el:174:51:Warning: reference to free variable `paredit-version' In clojure-font-lock-extend-region-def: cloj...

Emacs mode for R?

Is there a mode in emacs that does syntax highlighting for the R programming language? R-mode doesn't seem to work... ...