From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Sayth Renshaw Newsgroups: gmane.emacs.help Subject: select a section of text and run it into another process? Date: Tue, 31 Mar 2015 04:15:52 -0700 (PDT) Message-ID: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1427800893 17246 80.91.229.3 (31 Mar 2015 11:21:33 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 31 Mar 2015 11:21:33 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Mar 31 13:21:25 2015 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1YcuES-0004Qc-JR for geh-help-gnu-emacs@m.gmane.org; Tue, 31 Mar 2015 13:21:20 +0200 Original-Received: from localhost ([::1]:38108 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YcuER-0001l4-DZ for geh-help-gnu-emacs@m.gmane.org; Tue, 31 Mar 2015 07:21:19 -0400 X-Received: by 10.66.234.10 with SMTP id ua10mr43408051pac.45.1427800552877; Tue, 31 Mar 2015 04:15:52 -0700 (PDT) X-Received: by 10.50.118.42 with SMTP id kj10mr38100igb.9.1427800552842; Tue, 31 Mar 2015 04:15:52 -0700 (PDT) Original-Path: usenet.stanford.edu!h15no2326229igd.0!news-out.google.com!q14ni4117ign.0!nntp.google.com!h15no2326226igd.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Original-Newsgroups: gnu.emacs.help Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=110.146.153.253; posting-account=5Cd8QAoAAAC6AxpkrISTgUBJ9ktgwNBm Original-NNTP-Posting-Host: 110.146.153.253 User-Agent: G2/1.0 Injection-Date: Tue, 31 Mar 2015 11:15:52 +0000 Original-Xref: usenet.stanford.edu gnu.emacs.help:211182 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 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-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:103464 Archived-At: My emacs is going well, but something I would like to be able to do is run = a section of code in a file and send it to an eshell process of python/ipyt= hon to evaluated. How do I do this, I am not sure how to select the text without using the mo= use, there are a lot of people guessing on this SO question (http://stackov= erflow.com/questions/657672/how-to-select-or-highlight-a-block-in-emacs) bu= t can anyone provide a solid answer?=20 In the emacs manual it shows this article for sending to process http://www= .gnu.org/software/emacs/manual/html_node/elisp/Input-to-Processes.html which means I assume I could make a keybinding adaption if this (process-send-string "shell<1>" "ls\n") (process-send-string "eshell" "some version of selected text") Any ideas or is there a plugin that already does this? I would like to be a= ble to do this with multiple file types but python is where I am starting. Thanks Sayth