From: daniel@bigwalter.net (Daniel Jensen)
To: help-gnu-emacs@gnu.org
Subject: Re: Name of the active buffer
Date: Fri, 08 Jun 2007 13:33:23 +0200 [thread overview]
Message-ID: <87vedyhe9o.fsf@orme.bigwalter.net> (raw)
In-Reply-To: mailman.1772.1181299449.32220.help-gnu-emacs@gnu.org
hfleming <hfleming38@gmail.com> writes:
> Suppose I want to run, from emacs, the program "prog" with the active buffer,
> "buffer", say, as argument.
> Of course I can do "Meta-! prog buffer". Some editors, however, have a
> default name for the active buffer. In vi, for instance, one can do ":! prog
> %" . In ultraedit, the buffer is called "%f". How can we do that in emacs?
I assume you want to pass the buffer /file/ name as an argument to the
program, not the name.
Normally this is what you want for the compile command. It's a good idea
to use that even if the program is not strictly a compiler.
There is no built-in feature for taking the file name and using it with
M-x compile. One way to do it is to have a local variable in the file:
compile-command: program and arguments...
See <http://www.emacswiki.org/cgi-bin/wiki/CompileCommand> for possible
other ways.
next prev parent reply other threads:[~2007-06-08 11:33 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <mailman.1772.1181299449.32220.help-gnu-emacs@gnu.org>
2007-06-08 11:09 ` Name of the active buffer Robert D. Crawford
2007-06-08 11:33 ` Daniel Jensen [this message]
2007-06-07 18:42 hfleming
2007-06-13 6:22 ` Kevin Rodgers
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87vedyhe9o.fsf@orme.bigwalter.net \
--to=daniel@bigwalter.net \
--cc=help-gnu-emacs@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.