Gnus development mailing list
 help / color / mirror / Atom feed
* Automatically displaying content of [some] attachments
@ 2020-08-15 10:12 Adam Sjøgren
  2020-08-15 10:45 ` Adam Sjøgren
  0 siblings, 1 reply; 9+ messages in thread
From: Adam Sjøgren @ 2020-08-15 10:12 UTC (permalink / raw)
  To: ding

I often receive emails with gzip'ed/zip'ed attachments, like this:

  [1. application/zip; google.com!asjo.org!1597363200!1597449599.zip]...

  [2. application/tlsrpt+gzip; google.com!koldfront.dk!1597363200!1597449599!001.json.gz]...

If I press RET on them, they are expanded (decompressed and content
shown in the buffer), which is nice.

What do I need to configure to have that done automatically, so I don't
have to navigate to the attachment and press RET?

I have been looking in mm-decode.el, but so far I haven't hit the right
combination.


  Best regards,

    Adam

-- 
 "Thanks to enzymes, humans are solar-powered."             Adam Sjøgren
                                                       asjo@koldfront.dk



^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Automatically displaying content of [some] attachments
  2020-08-15 10:12 Automatically displaying content of [some] attachments Adam Sjøgren
@ 2020-08-15 10:45 ` Adam Sjøgren
  2020-08-15 10:51   ` Adam Sjøgren
  2020-08-15 18:41   ` Wayne Harris
  0 siblings, 2 replies; 9+ messages in thread
From: Adam Sjøgren @ 2020-08-15 10:45 UTC (permalink / raw)
  To: ding

Adam writes:

> What do I need to configure to have that done automatically, so I don't
> have to navigate to the attachment and press RET?

The motivating factor of asking a question is incredible. This is what
I found was needed:

    ; Show inline:
    (add-to-list 'mm-attachment-override-types "application/zip")
    (add-to-list 'mm-automatic-display "application/zip")

    (add-to-list 'mm-attachment-override-types "application/tlsrpt\\+gzip")
    (add-to-list 'mm-automatic-display "application/tlsrpt\\+gzip")
    (add-to-list 'mm-inline-media-tests '("application/tlsrpt\\+gzip" mm-inline-text identity))
    (add-to-list 'mm-inlined-types "application/tlsrpt\\+gzip")


  Best regards,

    Adam

-- 
 "Now cupid don't draw back your bow                        Adam Sjøgren
  Sam Cooke didn't know what I know"                   asjo@koldfront.dk



^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Automatically displaying content of [some] attachments
  2020-08-15 10:45 ` Adam Sjøgren
@ 2020-08-15 10:51   ` Adam Sjøgren
  2020-08-15 18:41   ` Wayne Harris
  1 sibling, 0 replies; 9+ messages in thread
From: Adam Sjøgren @ 2020-08-15 10:51 UTC (permalink / raw)
  To: ding

To keep the "buttons" being displayed, also add:

    (add-to-list 'gnus-buttonized-mime-types "application/zip")
    (add-to-list 'gnus-buttonized-mime-types "application/tlsrpt\\+gzip")


  :-),

   Adam

-- 
 "Nobody: I prefer to be called Nobody."                    Adam Sjøgren
                                                       asjo@koldfront.dk



^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Automatically displaying content of [some] attachments
  2020-08-15 10:45 ` Adam Sjøgren
  2020-08-15 10:51   ` Adam Sjøgren
@ 2020-08-15 18:41   ` Wayne Harris
  2020-08-15 20:40     ` Adam Sjøgren
  1 sibling, 1 reply; 9+ messages in thread
From: Wayne Harris @ 2020-08-15 18:41 UTC (permalink / raw)
  To: ding

Adam Sjøgren <asjo@koldfront.dk> writes:

> Adam writes:
>
>> What do I need to configure to have that done automatically, so I don't
>> have to navigate to the attachment and press RET?
>
> The motivating factor of asking a question is incredible.

Yes, that's very interesting.  I hypothesize that the words should not
be ``motivating factor'', but rather a ``consequence'' of asking a
question.  That is, I'd have written ``the consequence of asking a
question is /almost/ incredible''.

I don't even think it really must be asked to the public.  By just
putting precisely the question down to yourself seems to _essentially_
do the same job.  Of course, without the public's scrutiny, you're
relevantly limited and denied the joy and profit of exchange.

The consequence is that it organizes your thoughts in an academic way.
I mean, it well-organizes your thoughts.  You want the answer and you
want it quick, so you present the problem in a very clear, trivial way,
as it should always be presented.  First you prove there is a problem,
thereby implicitly challenging everyone to solve it, even with a
theoretical solution, so you craft the problem to allow a meaningful but
perhaps not useful solution.  That in itself is already a design of the
solution, so while everyone reads your work, you try your hand at the
most trivial solution possible.  Perhaps then you improve it and this
way, by and by, you might understand all the engineering required to get
a real-world solution to the problem.

That is all a consequence of presenting a problem in a well-organized
way.  This is why so many interesting scientists have praised the
importance of asking a good question.  Asking a good question demands
understanding; intellectual understanding seems to be a form of
well-organization.  Asking a good question requires sincerity and even
courage to admit your inability to answer it; such properties in
themselves check the entire educational system all over the world.



^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Automatically displaying content of [some] attachments
  2020-08-15 18:41   ` Wayne Harris
@ 2020-08-15 20:40     ` Adam Sjøgren
  2020-08-19  1:50       ` Wayne Harris
  2020-08-25  9:30       ` Eric S Fraga
  0 siblings, 2 replies; 9+ messages in thread
From: Adam Sjøgren @ 2020-08-15 20:40 UTC (permalink / raw)
  To: ding

Wayne writes:

> I don't even think it really must be asked to the public.  By just
> putting precisely the question down to yourself seems to _essentially_
> do the same job.  Of course, without the public's scrutiny, you're
> relevantly limited and denied the joy and profit of exchange.

For some reason I don't look into solving niggles with Gnus until after
I have actual sent off the question.

Before I send it, I feel like, hmm, I should ask about this, because
it's too tedious for me to figure out, and if somebody has the answer
already, I'd love to have it.

Then I send the question, and it triggers an "aww, let me just take a
quick look, how hard can it be, it's Emacs, for crying out loud"-reaction.

In other circumstances it's enough for me to put the question into
words, sometimes even to nobody; the famous "rubber ducking".

But for Gnus, and also for jabber.el, come to think of it, I almost
always send the question before solving it. In the case of jabber.el
sometimes spending days on it.

I am not sure why.

I do feel a little like a crazy person posting monologues, sometimes.

> Asking a good question requires sincerity and even courage to admit
> your inability to answer it;

I think that is an interesting point.

That's one of the things I look for in student helpers at work, do they
tell me when there is stuff they don't know (I avoided the word "admit"
here, because it implies not knowing is embarrasing, which it shouldn't
be in that situation), and do they ask questions that clear things up
for them.


  Best regards,

    Adam

-- 
 "You can't write a chord ugly enough to say what you       Adam Sjøgren
  want sometimes, so you have to rely on a giraffe     asjo@koldfront.dk
  filled with whipped cream."



^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Automatically displaying content of [some] attachments
  2020-08-15 20:40     ` Adam Sjøgren
@ 2020-08-19  1:50       ` Wayne Harris
  2020-08-19 20:02         ` Adam Sjøgren
  2020-08-20  2:21         ` Rafi Khan
  2020-08-25  9:30       ` Eric S Fraga
  1 sibling, 2 replies; 9+ messages in thread
From: Wayne Harris @ 2020-08-19  1:50 UTC (permalink / raw)
  To: ding

Adam Sjøgren <asjo@koldfront.dk> writes:

> Wayne writes:
>
>> I don't even think it really must be asked to the public.  By just
>> putting precisely the question down to yourself seems to _essentially_
>> do the same job.  Of course, without the public's scrutiny, you're
>> relevantly limited and denied the joy and profit of exchange.
>
> For some reason I don't look into solving niggles with Gnus until after
> I have actual sent off the question.
>
> Before I send it, I feel like, hmm, I should ask about this, because
> it's too tedious for me to figure out, and if somebody has the answer
> already, I'd love to have it.
>
> Then I send the question, and it triggers an "aww, let me just take a
> quick look, how hard can it be, it's Emacs, for crying out loud"-reaction.
>
> In other circumstances it's enough for me to put the question into
> words, sometimes even to nobody; the famous "rubber ducking".
>
> But for Gnus, and also for jabber.el, come to think of it, I almost
> always send the question before solving it. In the case of jabber.el
> sometimes spending days on it.
>
> I am not sure why.
>
> I do feel a little like a crazy person posting monologues, sometimes.

One hypothesis to explain your behavior is a bit of intellectual
narcisism and perhaps a bit of competition.  After you send the message,
you might begin to wonder --- is the question well put?  Is there any
obvious solution?  ``Omg, I forgot to check this other thing.  Let me do
that and make sure it doesn't solve the problem, otherwise I *failed* to
verify basic things.''  Does that happen?

For example, does it please you if the question turns out to be hard?  I
suppose asking whether it turns to be interesting would be surely
something everyone would like, I guess.  But I think that also qualifies
as a bit of intellectualism.

At the same time, I think it's a great joy to just exchange and talk.
You know, people get a ball and start throwing it back and forth.
That's life, fun, joy!

It would actually suck if people sort of demand that your questions must
always be so well put.  That makes you do a lot of verifications and so
it becomes tedious.  I prefer to do things in the following way.  I
asked a silly question and someone easily spotted.  I ask: how did you
do that so quickly?! :-)

>> Asking a good question requires sincerity and even courage to admit
>> your inability to answer it;
>
> I think that is an interesting point.
>
> That's one of the things I look for in student helpers at work, do they
> tell me when there is stuff they don't know (I avoided the word "admit"
> here, because it implies not knowing is embarrasing, which it shouldn't
> be in that situation), and do they ask questions that clear things up
> for them.

Yes, good catch.  I didn't want to imply that it is embarrassing.



^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Automatically displaying content of [some] attachments
  2020-08-19  1:50       ` Wayne Harris
@ 2020-08-19 20:02         ` Adam Sjøgren
  2020-08-20  2:21         ` Rafi Khan
  1 sibling, 0 replies; 9+ messages in thread
From: Adam Sjøgren @ 2020-08-19 20:02 UTC (permalink / raw)
  To: ding

Wayne writes:

> One hypothesis to explain your behavior is a bit of intellectual
> narcisism and perhaps a bit of competition.

Sounds likely. It's always an ego boost to answer questions, even if
they are your own.

> For example, does it please you if the question turns out to be hard?

Nope, I want easy solutions, that's why I use Emacs.


It seems we have veered off topic, though.


  Best regards,

    Adam

-- 
 "People are crazy and times are strange                    Adam Sjøgren
  I'm locked in tight, I'm out of range                asjo@koldfront.dk
  I used to care but - things have changed"



^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Automatically displaying content of [some] attachments
  2020-08-19  1:50       ` Wayne Harris
  2020-08-19 20:02         ` Adam Sjøgren
@ 2020-08-20  2:21         ` Rafi Khan
  1 sibling, 0 replies; 9+ messages in thread
From: Rafi Khan @ 2020-08-20  2:21 UTC (permalink / raw)
  To: Wayne Harris; +Cc: ding

Hi,

Wayne Harris <wharris1@protonmail.com> writes:

> Adam Sjøgren <asjo@koldfront.dk> writes:
> At the same time, I think it's a great joy to just exchange and talk.
> You know, people get a ball and start throwing it back and forth.
> That's life, fun, joy!
>
> It would actually suck if people sort of demand that your questions must
> always be so well put.  That makes you do a lot of verifications and so
> it becomes tedious.  I prefer to do things in the following way.  I
> asked a silly question and someone easily spotted.  I ask: how did you
> do that so quickly?! :-)

I also really appreciate the community aspect of questions/discourse!
Great to seem I'm not alone haha.

Rafi


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Automatically displaying content of [some] attachments
  2020-08-15 20:40     ` Adam Sjøgren
  2020-08-19  1:50       ` Wayne Harris
@ 2020-08-25  9:30       ` Eric S Fraga
  1 sibling, 0 replies; 9+ messages in thread
From: Eric S Fraga @ 2020-08-25  9:30 UTC (permalink / raw)
  To: ding

On Saturday, 15 Aug 2020 at 22:40, Adam Sjøgren wrote:
> Then I send the question, and it triggers an "aww, let me just take a
> quick look, how hard can it be, it's Emacs, for crying out loud"-reaction.

This is a summary of my experience practically every time I've posted a
question on either gnus or emacs groups...  You would think I would have
learned by now but it still happens to me all the time.

On the other hand, I can rationalise that having posted the question and
the answer will help others in the future. ;-)

-- 
Eric S Fraga via Emacs 28.0.50 & org 9.3.7 on Debian bullseye/sid



^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2020-08-25  9:32 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-08-15 10:12 Automatically displaying content of [some] attachments Adam Sjøgren
2020-08-15 10:45 ` Adam Sjøgren
2020-08-15 10:51   ` Adam Sjøgren
2020-08-15 18:41   ` Wayne Harris
2020-08-15 20:40     ` Adam Sjøgren
2020-08-19  1:50       ` Wayne Harris
2020-08-19 20:02         ` Adam Sjøgren
2020-08-20  2:21         ` Rafi Khan
2020-08-25  9:30       ` Eric S Fraga

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).