From mboxrd@z Thu Jan 1 00:00:00 1970 From: Daniele Pizzolli Subject: [BUG] Shebang will cause shell and sh to fail over tramp Date: Mon, 23 Feb 2015 18:30:55 +0100 Message-ID: <86fv9wilgw.fsf@me.localhost.invalid> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:36887) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YPwqV-0001D3-NT for emacs-orgmode@gnu.org; Mon, 23 Feb 2015 12:31:04 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YPwqS-0006C1-E5 for emacs-orgmode@gnu.org; Mon, 23 Feb 2015 12:31:03 -0500 Received: from relay5-d.mail.gandi.net ([2001:4b98:c:538::197]:35729) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YPwqS-0006Bp-82 for emacs-orgmode@gnu.org; Mon, 23 Feb 2015 12:31:00 -0500 Received: from mfilter29-d.gandi.net (mfilter29-d.gandi.net [217.70.178.160]) by relay5-d.mail.gandi.net (Postfix) with ESMTP id 242A741C080 for ; Mon, 23 Feb 2015 18:30:59 +0100 (CET) Received: from relay5-d.mail.gandi.net ([217.70.183.197]) by mfilter29-d.gandi.net (mfilter29-d.gandi.net [10.0.15.180]) (amavisd-new, port 10024) with ESMTP id LfwMCbxR60-G for ; Mon, 23 Feb 2015 18:30:57 +0100 (CET) Received: from localhost.invalid (unknown [193.205.210.32]) (Authenticated sender: me@toel.it) by relay5-d.mail.gandi.net (Postfix) with ESMTPSA id 6C42641C07C for ; Mon, 23 Feb 2015 18:30:57 +0100 (CET) List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org Hello, See the minimal example, the offending part is ":shebang "#!/bin/sh". #+PROPERTY: header-args:shell :dir /vagrant@127.0.0.1:/vagrant #+PROPERTY: header-args:shell+ :exports both :results output verbatim replace #+PROPERTY: header-args:shell+ :shebang "#!/bin/sh" #+PROPERTY: header-args:sh :dir /vagrant@127.0.0.1:/vagrant #+PROPERTY: header-args:sh+ :exports both :results output verbatim replace #+PROPERTY: header-args:sh+ :shebang "#!/bin/sh" * setup #+BEGIN_SRC sh cat $HOME/.ssh/id_rsa.pub >> $HOME/.ssh/authorized_keys # TODO accept the key automatically or use StrictHostKeyChecking no #+END_SRC #+BEGIN_SRC emacs-lisp (org-babel-do-load-languages 'org-babel-load-languages '((emacs-lisp . t) (python . t) (shell . t) (sh . t))) #+END_SRC * sh will fail #+BEGIN_SRC sh ls | wc -l #+END_SRC #+RESULTS: Will show in *Org-Babel Error Output*: /bin/bash: /scp:vagrant@127.0.0.1:/tmp/sh-script-1631VYi: No such file or directory #+RESULTS: * shell will fail #+BEGIN_SRC shell ls | wc -l #+END_SRC Will show in *Messages* org-babel-execute:shell: Wrong number of arguments: #[(session body &optional params stdin) [... binary code cut ...] * org version #+BEGIN_SRC emacs-lisp (org-version nil t) #+END_SRC #+RESULTS: : Org-mode version 8.3beta (release_8.3beta-860-ge4da74 @ /home/vagrant/.emacs.d/el-get/org-mode/lisp/) Best, Daniele