From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: "James K. Lowden" Newsgroups: gmane.emacs.help Subject: Re: Calling external programs in emacs Date: Fri, 13 Jan 2017 16:25:12 -0500 Organization: http://www.NewsDemon.com Message-ID: <20170113162512.38851e4e7964ca1aa440d674@speakeasy.net> References: NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Trace: blaine.gmane.org 1484343052 20148 195.159.176.226 (13 Jan 2017 21:30:52 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Fri, 13 Jan 2017 21:30:52 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Jan 13 22:30:48 2017 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cS9QV-00030Y-Ip for geh-help-gnu-emacs@m.gmane.org; Fri, 13 Jan 2017 22:30:23 +0100 Original-Received: from localhost ([::1]:45364 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cS9Qa-0004zx-Aq for geh-help-gnu-emacs@m.gmane.org; Fri, 13 Jan 2017 16:30:28 -0500 Original-Path: usenet.stanford.edu!news.glorb.com!peer01.iad!feed-me.highwinds-media.com!news.highwinds-media.com!post01.iad.highwinds-media.com!fx21.iad.POSTED!not-for-mail Original-Newsgroups: gnu.emacs.help X-Newsreader: Sylpheed 3.4.3 (GTK+ 2.24.28; x86_64--netbsd) Original-Lines: 25 Original-X-Complaints-To: abuse@newsdemon.com Original-NNTP-Posting-Date: Fri, 13 Jan 2017 21:25:13 UTC X-Received-Bytes: 1246 X-Received-Body-CRC: 1642264534 Original-Xref: usenet.stanford.edu gnu.emacs.help:219052 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.org gmane.emacs.help:112112 Archived-At: On Fri, 13 Jan 2017 18:53:42 +0000 (UTC) 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? The emacs function you want is called shell-function. It's usually mapped to M-! (meta-bang). You can verify that with either C-h f shell-function or C-h k M-! To run asynchronously, see async-shell-function, usually M-&. HTH. --jkl