all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: John Mastro <john.b.mastro@gmail.com>
To: "help-gnu-emacs@gnu.org" <help-gnu-emacs@gnu.org>
Subject: Re: Calling external programs in emacs
Date: Wed, 18 Jan 2017 10:21:22 -0800	[thread overview]
Message-ID: <CAOj2CQQK8t3gBOZdw75=iBx1pEHNbi+5wzZ4y+UJ7tEeK5fqWg@mail.gmail.com> (raw)
In-Reply-To: <84ae994b-0052-4416-9b68-e9692a26f7e8@googlegroups.com>

Rusi <rustompmody@gmail.com> wrote:
> On Saturday, January 14, 2017 at 12:23:46 AM UTC+5:30, Sam Nirvana wrote:
> > I'm new to emacs, so forgive my inexperience.
> >
> > As you know, with Vim I can compile, say, a TeX file from within the
> > editor with the following command:
> >
> >       :!pdftex %
> >
> > Is there a way to do the same thing with emacs?
>
> Others have already told you about M-! (also to be found on Menu→Tools→Shell Command)
>
> The % trick however does not work OTB in emacs
> Here is some elisp that can help that
> https://lists.gnu.org/archive/html/help-gnu-emacs/2008-08/msg00482.html

Someone may have already mentioned this, but Emacs's built-in way to
achieve something similar is to type `M-! M-n'. The M-n will cause the
relative file name of the current buffer to be inserted, leaving point
before it.

        John



      reply	other threads:[~2017-01-18 18:21 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-13 18:53 Calling external programs in emacs Sam Nirvana
2017-01-13 20:46 ` tomas
2017-01-13 21:25 ` James K. Lowden
2017-01-13 21:51   ` Joost Kremers
2017-01-13 22:34 ` Dan Espen
2017-01-14 11:44   ` Jens Lechtenboerger
2017-01-18  3:40 ` Rusi
2017-01-18 18:21   ` John Mastro [this message]

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='CAOj2CQQK8t3gBOZdw75=iBx1pEHNbi+5wzZ4y+UJ7tEeK5fqWg@mail.gmail.com' \
    --to=john.b.mastro@gmail.com \
    --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.