From nobody Sat Sep 21 22:01:44 2024 X-Original-To: freebsd-questions@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4XB3BV51Psz5X56W for ; Sat, 21 Sep 2024 22:01:54 +0000 (UTC) (envelope-from rwp@proulx.com) Received: from havoc.proulx.com (havoc.proulx.com [198.99.81.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4XB3BT28Gsz4r6Q for ; Sat, 21 Sep 2024 22:01:53 +0000 (UTC) (envelope-from rwp@proulx.com) Authentication-Results: mx1.freebsd.org; dkim=pass header.d=proulx.com header.s=dkim2048 header.b=gpMXB031; dmarc=pass (policy=none) header.from=proulx.com; spf=pass (mx1.freebsd.org: domain of rwp@proulx.com designates 198.99.81.74 as permitted sender) smtp.mailfrom=rwp@proulx.com Received: from joseki.proulx.com (localhost [127.0.0.1]) by havoc.proulx.com (Postfix) with ESMTPS id AD8202B4 for ; Sat, 21 Sep 2024 16:01:45 -0600 (MDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=proulx.com; s=dkim2048; t=1726956105; bh=qAHR3uzcR9jG+M0Ime2YrrHtfCvSgfYekjoE7tFdP0M=; h=Date:From:To:Subject:References:In-Reply-To:From; b=gpMXB031ONbvfaN46wEUC0X7HNuKJAGW0cqZYK8nJDT+sinaCjW8jrxN7wxHXYHu+ 9D7RIhPNy5fvHrE/H+XKoYBH27lpdJtiBfXjvH49mvh7X/BZzDwrNk1C16DLWMXbda DK5cIDyK8CUeZsuLbYi5BtcjgS/+r7CEZkGHsJr5QBQjWVvc3heNtd1tUnaSyL1WY7 ZvLvKEjXNwi6mw11NWd19oNUcyz+MmYQEy5qOm5CTdjV7dM541D46zuSyIKXNO7uAu qhe/Qdme/7K+puMJDz/PDUla5rc7SSrA+NDovhG/rUCzgST7UHByAdvDEINwYFXgin AKkG5k8iTis7A== Received: from madness.proulx.com (madness.proulx.com [192.168.230.122]) by joseki.proulx.com (Postfix) with ESMTP id DBED27A00E for ; Sat, 21 Sep 2024 16:01:44 -0600 (MDT) Received: by madness.proulx.com (Postfix, from userid 1000) id CDAD6880F6; Sat, 21 Sep 2024 16:01:44 -0600 (MDT) Date: Sat, 21 Sep 2024 16:01:44 -0600 From: Bob Proulx To: freebsd-questions@freebsd.org Subject: Re: Suggestions for mail client Message-ID: <20240921154512502717312@bob.proulx.com> Mail-Followup-To: freebsd-questions@freebsd.org References: <5wr52qrkvc7lp5cx4gd5vaadl6aq7wv5oslhi5w27beccznsxk@emcxnqvrtdp4> List-Id: User questions List-Archive: https://lists.freebsd.org/archives/freebsd-questions List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: freebsd-questions@freebsd.org Sender: owner-freebsd-questions@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Spamd-Result: default: False [-3.70 / 15.00]; NEURAL_HAM_LONG(-1.00)[-1.000]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; NEURAL_HAM_SHORT(-1.00)[-1.000]; DMARC_POLICY_ALLOW(-0.50)[proulx.com,none]; FORGED_SENDER(0.30)[bob@proulx.com,rwp@proulx.com]; R_SPF_ALLOW(-0.20)[+mx]; R_DKIM_ALLOW(-0.20)[proulx.com:s=dkim2048]; MIME_GOOD(-0.10)[text/plain]; ARC_NA(0.00)[]; ASN(0.00)[asn:397142, ipnet:198.99.80.0/22, country:US]; MISSING_XM_UA(0.00)[]; RCPT_COUNT_ONE(0.00)[1]; MIME_TRACE(0.00)[0:+]; MID_RHS_MATCH_FROMTLD(0.00)[]; RCVD_COUNT_THREE(0.00)[3]; RCVD_TLS_LAST(0.00)[]; FROM_NEQ_ENVFROM(0.00)[bob@proulx.com,rwp@proulx.com]; FROM_HAS_DN(0.00)[]; MLMMJ_DEST(0.00)[freebsd-questions@freebsd.org]; TO_DN_NONE(0.00)[]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; TO_MATCH_ENVRCPT_ALL(0.00)[]; DKIM_TRACE(0.00)[proulx.com:+] X-Rspamd-Queue-Id: 4XB3BT28Gsz4r6Q X-Spamd-Bar: --- Karl Vogel wrote: > Darius Rosotic wrote: > > In this file I have this code to say that I want "HTML" attachments > > opened with Firefox: > > text/html; /usr/local/bin/firefox ... > > In my mailcap file, I use this for inline viewing of HTML: > text/html; /usr/local/bin/lynx -dump %s; nametemplate=%s.htm; copiousoutput > > I can also see images in a separate window: > image/*; /usr/local/bin/feh %s I only object to the full hard coded paths there making that a non-portable mailcap file. In my ~/.mailcap file I have all of the text mode html dumpers commented with my currently preferred one uncommented. As time goes by and depending upon the html one will do a better rendering job than another one will on different types of html. I am preferring "links" at the moment but as you can tell I select among the selection as my whims dictate. # text/html; firefox %s; description=HTML Text; test=test -n "$DISPLAY"; nametemplate=%s.html # text/html; elinks -dump -dump-color-mode 3 %s; copiousoutput; description=HTML Text; nametemplate=%s.html # text/html; elinks -dump %s; copiousoutput; description=HTML Text; nametemplate=%s.html text/html; links -dump %s; copiousoutput; description=HTML Text; nametemplate=%s.html # text/html; lynx -force_html %s; needsterminal; description=HTML Text; nametemplate=%s.html # text/html; lynx -dump -force_html %s; copiousoutput; description=HTML Text; nametemplate=%s.html # text/html; w3m -no-mouse -T text/html %s; needsterminal; description=HTML Text; nametemplate=%s.html If this does not produce something reasonable for me then I 'v'iew the mime parts, j and k down to the text/html part, 's'ave it to a file usually for me ~/tmp/mail.html (selecting overwriting of the previous) and then in my running Firefox I click my toolbar bookmark to open the file:///home/rwp/tmp/mail.html bookmark which renders the email message in the full html web browser. I like this strategy because most of the time if I must view the text/html part then one of links, elinks, lynx, w3m will do a good display of it. I can read it and move along. But for those pesky HTML emails that don't render that way or that require my input I can transfer the file to the web browser and handle it there. Additionally I also have image and pdf entries too. application/pdf; /usr/local/bin/xpdf %s; test=test -n "$DISPLAY"; description=Portable Document Format; nametemplate=%s.pdf application/x-pdf; /usr/local/bin/xpdf %s; test=test -n "$DISPLAY"; description=Portable Document Format; nametemplate=%s.pdf application/pdf; pdftotext -layout %s -; copiousoutput; description=Portable Document Format; nametemplate=%s.pdf image/gif; feh -FZ '%s'; test=test -n "$DISPLAY" ; description=GIF Image; nametemplate=%s.gif image/jpeg; feh -FZ '%s'; test=test -n "$DISPLAY" ; description=JPEG Image; nametemplate=%s.jpeg image/png; feh -FZ '%s'; test=test -n "$DISPLAY" ; description=PNG Image; nametemplate=%s.png Plus some other useful ones. text/plain; less %s; needsterminal text/x-diff; cat; copiousoutput application/msword; catdoc %s; copiousoutput; description="MS Word Text"; application/vnd.ms-excel; libreoffice %s; edit=libreopenoffice '%s'; test=test -n "$DISPLAY"; nametemplate=%s.xls; description="Microsoft Excel Document" Sometimes I get an email with atypical types and create an entry on the fly and then use it. I test for $DISPLAY so that when I log into my system remotely using ssh rather than being on my desktop console that the best available entry is automatically selected. I get text only options when $DISPLAY is not set. I get graphical choices. Bob