From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Thierry Volpiatto Newsgroups: gmane.emacs.bugs Subject: bug#14110: 24.3.50; Add command to open files outside of Emacs (use xdg-open, open etc) Date: Fri, 05 Apr 2013 08:03:59 +0200 Organization: Emacs Helm Message-ID: <87fvz5fr8w.fsf@gmail.com> References: <87zjxi4u15.fsf@gmail.com> <871uarou3r.fsf@gmail.com> <87d2uanz3v.fsf@gmail.com> <878v4ygp3u.fsf@gmail.com> <83li8yf98m.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1365141896 5867 80.91.229.3 (5 Apr 2013 06:04:56 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 5 Apr 2013 06:04:56 +0000 (UTC) To: 14110@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Apr 05 08:05:24 2013 Return-path: Envelope-to: geb-bug-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 1UNzm6-0005td-QK for geb-bug-gnu-emacs@m.gmane.org; Fri, 05 Apr 2013 08:05:23 +0200 Original-Received: from localhost ([::1]:44031 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UNzlh-0006sa-R4 for geb-bug-gnu-emacs@m.gmane.org; Fri, 05 Apr 2013 02:04:57 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:51988) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UNzld-0006sD-VG for bug-gnu-emacs@gnu.org; Fri, 05 Apr 2013 02:04:54 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UNzlb-0004mA-IC for bug-gnu-emacs@gnu.org; Fri, 05 Apr 2013 02:04:53 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:58720) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UNzlZ-0004lw-Be for bug-gnu-emacs@gnu.org; Fri, 05 Apr 2013 02:04:51 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.72) (envelope-from ) id 1UNzog-0000LJ-E9 for bug-gnu-emacs@gnu.org; Fri, 05 Apr 2013 02:08:02 -0400 X-Loop: help-debbugs@gnu.org In-Reply-To: <87zjxi4u15.fsf@gmail.com> Resent-From: Thierry Volpiatto Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 05 Apr 2013 06:08:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 14110 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.13651420711295 (code B ref -1); Fri, 05 Apr 2013 06:08:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 5 Apr 2013 06:07:51 +0000 Original-Received: from localhost ([127.0.0.1]:34595 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UNzoU-0000Kp-AP for submit@debbugs.gnu.org; Fri, 05 Apr 2013 02:07:51 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:40515) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UNzoR-0000Ki-MU for submit@debbugs.gnu.org; Fri, 05 Apr 2013 02:07:48 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UNzlE-0004hm-Ei for submit@debbugs.gnu.org; Fri, 05 Apr 2013 02:04:34 -0400 Original-Received: from lists.gnu.org ([208.118.235.17]:53606) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UNzlE-0004hi-Aq for submit@debbugs.gnu.org; Fri, 05 Apr 2013 02:04:28 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:51764) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UNzl9-0006iy-A7 for bug-gnu-emacs@gnu.org; Fri, 05 Apr 2013 02:04:28 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UNzl1-0004Ok-LD for bug-gnu-emacs@gnu.org; Fri, 05 Apr 2013 02:04:23 -0400 Original-Received: from plane.gmane.org ([80.91.229.3]:60173) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UNzl1-0004OW-FH for bug-gnu-emacs@gnu.org; Fri, 05 Apr 2013 02:04:15 -0400 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1UNzlM-0005Fl-LX for bug-gnu-emacs@gnu.org; Fri, 05 Apr 2013 08:04:36 +0200 Original-Received: from lbe83-2-78-243-104-167.fbx.proxad.net ([78.243.104.167]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 05 Apr 2013 08:04:36 +0200 Original-Received: from thierry.volpiatto by lbe83-2-78-243-104-167.fbx.proxad.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 05 Apr 2013 08:04:36 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 40 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: lbe83-2-78-243-104-167.fbx.proxad.net User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) Cancel-Lock: sha1:E7TGIwbO0uTfhobwlz2vGrZkv6A= X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:73175 Archived-At: Eli Zaretskii writes: >> From: Jambunathan K >> Date: Thu, 04 Apr 2013 23:22:37 +0530 >> Cc: 14110@debbugs.gnu.org >> >> The alist is already maintained by the user's desktop (likely via >> Explore->`Open with' -> `Always use this application for these files'). >> Emacs should at no point in time have any knowledge of this association. > > Emacs can easily know about the associations, at least on Windows. Here what I do in helm: Default action to open a file is always edit the file in emacs with the right mode. Use another command to open file externally (async). This command can use a prefix to choose program to use (with completion). Once you choose this program your choice is stored in an alist with customize. (So no need for user to customize complex alist) Each time you want to change, you can press C-u to make another choice. If you answer yes, this new program will replace the precedent in alist, no will use the new program without storing it. If you don't press C-u the last program used for this kind of file is used. If the command is called with no choice (not C-u) and nothing for this file extension is found in alist helm looks for mailcap entries. It is good to be able to change program at any time, e.g for foo.jpg, you may use sometimes imagemagick, ristretto, or gimp etc.... I also have a command that use default tool with no choice (xdg-open) but I don't like it. -- Thierry Get my Gnupg key: gpg --keyserver pgp.mit.edu --recv-keys 59F29997