From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp11.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id 0Df3FAOHi2LeYwEAbAwnHQ (envelope-from ) for ; Mon, 23 May 2022 15:07:15 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp11.migadu.com with LMTPS id 4E7QFAOHi2IuFAAA9RJhRA (envelope-from ) for ; Mon, 23 May 2022 15:07:15 +0200 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id E19A830B7B for ; Mon, 23 May 2022 15:07:14 +0200 (CEST) Received: from localhost ([::1]:45356 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nt7mE-0005jJ-1J for larch@yhetil.org; Mon, 23 May 2022 09:07:14 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:52040) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nt7fC-00019X-2H for emacs-orgmode@gnu.org; Mon, 23 May 2022 08:59:58 -0400 Received: from mail-ot1-x329.google.com ([2607:f8b0:4864:20::329]:42667) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nt7fA-0002Je-AV for emacs-orgmode@gnu.org; Mon, 23 May 2022 08:59:57 -0400 Received: by mail-ot1-x329.google.com with SMTP id t14-20020a9d66ce000000b0060af9ed4b87so4897488otm.9 for ; Mon, 23 May 2022 05:59:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=message-id:date:mime-version:user-agent:subject:content-language :from:to:cc:references:in-reply-to; bh=jwqpPMroaneaVNljBWJgjWxiH9NVgs0/Bpd76Kkn9Vs=; b=b5KghF8old3mvvkVCY6Ve3eEaAso6QlYs7NSfwczF0i+HlYOxze4Atx9CePESqVNiN feizdiRWQWEPLw9uWe09MTrqpO/fETIJzWMry18DE8tWQ5jtOKrajznBv0DXTOYeYk+/ FLeOlPtunDPi0uzZDGfwH4/y3+SIEw6CWogQUdSlIcAp0Fm8gWB2qj0Y33VfunWuRGir CEYYbR+5QH18lgB2QBVcl5EWMs9TvwXhqAUv6MVRA1jniKKzcIcpxe+WF08rYwV4lryL p4wjZg5rxSmQ1XB+LcxxrN56zwT5qCxURt6xq7Q3sgywC4TPHd61F0+4GGuWa7LAGfZ2 gIzw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:message-id:date:mime-version:user-agent:subject :content-language:from:to:cc:references:in-reply-to; bh=jwqpPMroaneaVNljBWJgjWxiH9NVgs0/Bpd76Kkn9Vs=; b=53BvqKsskUrkNwH0m8mTTh0/fJ9aj3ongdrXCZ6PcRkoCSjtZv3NFJ6IW25AlLeHcb o2ASq8Xgh9cy/rdnPrSRWw5RHdm4Y7JPl5a7vskuwDGsbvXBXkugwjk/yfXvmazPvD+G +8xCcnRunyMPbxXbOlZ/4rFOHPBxorlS+tvgsQFxGTzJve0kQZHP+QEOCjI19DUMte5W d2Mudo5YZ7+iaTF+iqwIVxvnuOhGLtPF0XtRDa/i15iucjI85dtkeVvvkQSFikaiPbxR TW2AeSktP8hl796KvL3K6q4XnjMYYBpI6dTjDkn/tB+RRzFCbrUTpimEDx6EaSJr3A7D mJPQ== X-Gm-Message-State: AOAM530pWAK7gPxnhEzQvP6FA9oUfUac+BO8g6Y5x+U7UsNWCXEeREdy DXnRyGymLXmt1vYegzdYKVU= X-Google-Smtp-Source: ABdhPJzjBmk6I+q2zwrErUtc8wuxY14auL58PdOmrBxE1TeQ2eco54k8Bhm4Le58GJfAlq8FXieATw== X-Received: by 2002:a9d:76d5:0:b0:60b:1882:78bd with SMTP id p21-20020a9d76d5000000b0060b188278bdmr1289361otl.71.1653310795194; Mon, 23 May 2022 05:59:55 -0700 (PDT) Received: from [10.65.33.48] ([96.44.191.132]) by smtp.gmail.com with ESMTPSA id s8-20020aca5e08000000b00328e70cae5csm3991129oib.43.2022.05.23.05.59.54 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 23 May 2022 05:59:54 -0700 (PDT) Content-Type: multipart/alternative; boundary="------------jjP5TBwlYqz7DRkebXLJ6W0B" Message-ID: Date: Mon, 23 May 2022 08:59:53 -0400 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.9.1 Subject: Re: Bug in 9.5.3 org--file-default-apps Content-Language: en-US From: Craig STCR To: Ihor Radchenko , Max Nikulin Cc: emacs-orgmode@gnu.org References: <963d5f94-3fdf-a01b-bc91-edc99222cb34@gmail.com> <87czgeaxir.fsf@localhost> <6615610d-93ae-171f-b554-3f4cc79354cc@gmail.com> <87a6bhc1w6.fsf@localhost> <86692975-4d5f-6933-3227-c6b208f76862@gmail.com> <877d6lbsg5.fsf@localhost> <7c75b724-1ea2-5e3e-cbe6-e1895fd35bd3@gmail.com> <877d6j2htv.fsf@localhost> <87ilq14p6p.fsf@localhost> <87v8u0396t.fsf@localhost> <87ilpz3bi0.fsf@localhost> <0d8e9eb3-8b4f-127b-2293-2dfd182cd2cf@gmail.com> In-Reply-To: <0d8e9eb3-8b4f-127b-2293-2dfd182cd2cf@gmail.com> Received-SPF: pass client-ip=2607:f8b0:4864:20::329; envelope-from=craig.stcr1@gmail.com; helo=mail-ot1-x329.google.com X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, NICE_REPLY_A=-0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Migadu-Flow: FLOW_IN X-Migadu-To: larch@yhetil.org X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1653311235; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=jwqpPMroaneaVNljBWJgjWxiH9NVgs0/Bpd76Kkn9Vs=; b=DMYtwlWTJGqH2yG9k0zWeZNZxvAVtkuSoB/NDrRX6Fg1hb6CVLq2gmbw092ccrLwBLoDPt xqptXpYqZ6SOoOj5QTyWCn2m5FDBN5/49PMq6adaPpmijNu1TpykHzA9vZgO/3Kv7sgJ1Y COlV52gr1n51wm4kAuET7c1nwH2gn0/5YpVu7uiKDi92uapyxbD+CE9YhskrL97l09ZbG9 ter3fmktWRJDUv7DiQ/TQccF078/HhUENMKXIx+Q/EbHfLrGis3UsXMhzq9EqnR6J4JLnX 3E3smBCIfSDmGWkxUyVyQ40AvntrF8TvENX5hSwyQTRs8bzg2humMW4RRVUiwA== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1653311235; a=rsa-sha256; cv=none; b=pMAbMp1fSUIDDlGcMr20f3MMmheUe1BiRojrfSKSJLtTeo1s7Hh/EuSKxo/2IzVpYBj+Ke 9XINKeYi0JBDuuen2XBXIoYMEpnRUHxGnrgNnBPN93ePoFvj91Z3P98rQ0xwRYR+NfX+c7 Vn22A2LDjJ66gSi7EI+bHuK+vBePxm9PR2R7MviCP7PIC/R2P4y+Kv4uw8p3r+ujY5eBlW j2ekHvoZK9dHNS/og61Vwq/9bZ+Fl9nHOzX7UcnVWTZMd3wr3uG2N7kYr44bQL2qe7Zh9b +0iDbYXcAcwVUepRlIUPNYhgyEcMj2vhrdQfN3decUBbz5TdzuH5eftcczSj/w== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=b5KghF8o; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: -9.05 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=b5KghF8o; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: E19A830B7B X-Spam-Score: -9.05 X-Migadu-Scanner: scn0.migadu.com X-TUID: +yb3UmcFrJEb This is a multi-part message in MIME format. --------------jjP5TBwlYqz7DRkebXLJ6W0B Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit I guess maybe I should have given a little better description of what I tried that did NOT work?  But it's a little off-topic for this mailing list.  Nevertheless, here it is... I created a ~/.mailcap file and put this in it, which I cut and pasted from /etc/mailcap: application/x-shellscript; emacs27 %s; test=test -n "$DISPLAY" But obviously that's not going to change anything, since it's already in the system mailcap file, /etc/mailcap.  DOH!  And sure enough, running '>$ run-mailcap myscript' invokes 'less'.  But what I wasn't expecting is that running '>$ update-mime -- local' gives me: "Error: '/home/user/.mailcap' is not in required format -- not updated".   Not sure why I'm getting that when I cut-and-pasted from /etc/mailcap. No worries.  I'll look in more depth later. On 5/23/22 8:40 AM, Craig STCR wrote: > Thanks all for your help! > > On 5/20/22 9:44 PM, Ihor Radchenko wrote: >> Dear Craig, ... or provide plain/text handler in ~/.mailcap. >> > OK, I did a first-try on this and was unsuccessful, but I'm sure it's > user error.  I need to refresh my knowledge on how to customize > user-local mime database, and that will write-out a new ~/.mailcap, > etc, I think?  I've done it before, but it was awhile ago, and I > wasn't paying attention to ~/.mailcap when I did it.  I know for Gnome > I can create a .desktop file.  But I know there's a way to customize > user-local mime database without Gnome desktop. I'll take a closer > look when I have a little more time. > > > On 5/20/22 9:44 PM, Ihor Radchenko wrote: >> However, I am not sure what to do on Windows/Mac. > Maybe try a quick-and-dirty, cross-platform solution that checks > non-binary files for a first-line shebang?  Could use existing Emacs > hooks that determine major-mode when opening files. > > Again, thanks all for your help! > > Best, > -Craig > --------------jjP5TBwlYqz7DRkebXLJ6W0B Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 8bit I guess maybe I should have given a little better description of what I tried that did NOT work?  But it's a little off-topic for this mailing list.  Nevertheless, here it is...

I created a ~/.mailcap file and put this in it, which I cut and pasted from /etc/mailcap:

application/x-shellscript; emacs27 %s; test=test -n "$DISPLAY"
But obviously that's not going to change anything, since it's already in the system mailcap file, /etc/mailcap.  DOH!  And sure enough, running '>$ run-mailcap myscript' invokes 'less'.  But what I wasn't expecting is that running '>$ update-mime -- local' gives me: "Error: '/home/user/.mailcap' is not in required format -- not updated".   Not sure why I'm getting that when I cut-and-pasted from /etc/mailcap.

No worries.  I'll look in more depth later.


On 5/23/22 8:40 AM, Craig STCR wrote:
Thanks all for your help!

On 5/20/22 9:44 PM, Ihor Radchenko wrote:
Dear Craig, ... or provide plain/text handler in ~/.mailcap.

OK, I did a first-try on this and was unsuccessful, but I'm sure it's user error.  I need to refresh my knowledge on how to customize user-local mime database, and that will write-out a new ~/.mailcap, etc, I think?  I've done it before, but it was awhile ago, and I wasn't paying attention to ~/.mailcap when I did it.  I know for Gnome I can create a .desktop file.  But I know there's a way to customize user-local mime database without Gnome desktop.  I'll take a closer look when I have a little more time.


On 5/20/22 9:44 PM, Ihor Radchenko wrote:
However, I am not sure what to do on Windows/Mac.
Maybe try a quick-and-dirty, cross-platform solution that checks non-binary files for a first-line shebang?  Could use existing Emacs hooks that determine major-mode when opening files.

Again, thanks all for your help!

Best,
-Craig


--------------jjP5TBwlYqz7DRkebXLJ6W0B--