Subject: bug#63536: Feature Request

From: Payas Relekar <[email-masked]>
Date: Wed, 17 May 2023 21:10:15 +0530

Eli Zaretskii <[email-masked]> writes:

>> From: Payas Relekar <[email-masked]>
>> Cc: Andrew Goh <[email-masked]>,  [email-masked]
>> Date: Wed, 17 May 2023 19:34:06 +0530
>>
>> The idea itself is valid, as long as the update check happens only at
>> explicit user action. The command should only compare current version of
>> Emacs with the latest update and inform user about the difference. Then
>> the onus is on user to proceed with the update. Command output can point
>> them to relevant section of the manual, informing of ways to install
>> (and also update) Emacs.
>
> How will we know where to look?  That's the main technical issue with
> this, I think.
>
> Another possible issue is whether just to tell the user "A newer
> version XY.Z is available, you can download it at <URL>", or also
> offer a possibility of actually downloading the newer version?

The former is preferred. Emacs users more often than not use third party
mechanisms (e.g. package managers) to get it installed. Any action for
actually downloading would muddy the waters. Here's the flow that I
imagine:

1. User runs `M-x emacs-check-update`
2. Emacs checks GNU repo and provides somthing like:
   `Update for Emacs 29.1 is now available. Current version is 28.2.

   If you installed Emacs via a package manager like your GNU/linux
   distribution, homebrew, Guix etc, please follow their respective
   instructions.

   If you installed Emacs by compiling from source, follow _link to
   latest Emacs compilation instructions_.

   If you'd like to check for updates for Emacs-Lisp packages, please
   check 'package-upgrade'`
3. User chooses to follow or ignore the instructions.

The wording would play big part, but as long as we make it clear to
follow the path of original installation is preferred, I think most
users can figure it out, just like the rest of the manual.

At any point, Emacs providing built-in mechanism for update, while nice
to have, will be gigantic pain to implement and even bigger pain to
maintain. Something like rustup is well-desired, but Emacs has very
broad scope and dependency tree unlike rust toolchain, so I'd rather
avoid it.
--