[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [feature/internal-msys] thoughts of a more function windows package

From: Phillip Lord
Subject: Re: [feature/internal-msys] thoughts of a more function windows package
Date: Thu, 21 Jan 2021 16:44:02 +0000
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1.90 (gnu/linux)

Eli Zaretskii <eliz@gnu.org> writes:

>> From: Phillip Lord <phillip.lord@russet.org.uk>
>> Date: Wed, 20 Jan 2021 19:29:58 +0000
>> The plan would be during the installation run the newly installed
>> Emacs. This would download, unpack and configure msys2, as well as
>> install a variety of related packages (git, find, gzip, hunspell,
>> aspell, what ever). For those using the zip package of Emacs, they would
>> achieve the same thing by running a command.
> Could you please elaborate on how will this work for users?  E.g., how
> about describing the steps a user who installs Emacs should do to
> install these additions?  I don't think I have a clear picture of what
> you intend to do, and the files you committed are just the starting
> point, so they don't answer this question.

Considering just the .exe installer, at the end of the installation
process, we would run Emacs with menu bar, scroll bar and everything
switch off and run the command "w32-msys-internal-install-dialog".

Emacs would say "do you want do install a handy collection of
tools". User says "y", then Emacs downloads the latest msys2-date.xz,
then unpacks it with xz. Emacs will run msys2.exe to initialize
(hopefully without poping up windows if this will work). Then Emacs will
run pacman to update and install. The user will see Emacs saying

Would you like to install msys, and a handy set of tools (Y/n)
Installing msys...done
Updating msys...done
Installing git...done

When it's finished, the user starts Emacs and does vc-dir and it works,
instead of seeing "git not found" errors. For those using the zip file,
the user would have to launch "M-x w32-msys-install" manually.

At a later date, I might add some cuter things. So, for example we might


or equivalent. We might create "internal-msys" package on ELPA which
contains a standard set of packages and Emacs fixes to make it work, so
it would be freely updatable. At which point the w32-msys-install
command would install the ELPA package before doing anything else.

There are also issues that when Emacs is removed msys (and any
configuration) would get blitzed, so I'd have to think about how to
persist msys configuration between two installs of Emacs. Currently the
file organisation looks like this:

c:/Program Files/Emacs/emacs-28.1/bin
c:/Program Files/Emacs/emacs-28.1/share
c:/Program Files/Emacs/emacs-28.1/msys



c:/Program Files/Emacs/emacs-28.1/bin
c:/Program Files/Emacs/emacs-28.1/share
c:/Program Files/Emacs/msys

would mean that installing Emacs-28.2 would work naturally.

There are also some issues about user persmissions; I only ever run
Windows as administrator, so there will be some thought given as to how
this would work. Neither Emacs or msys require this AFAICT.

> Btw, I don't think I understand why you insist on using 'concat' to
> generate files names from 2 components: that's what expand-file-name
> is for, and it does that better.

Because in my own code, I tend to use f.el and I have got used to having
a clean, consistent and comprehensive API, so I tend to forget the
underlying Emacs primitives.

> One other not about the code you committed is that modifying PATH from
> within Emacs is not generally a good idea, it has some subtleties.

Any alternative that achieves the same thing?


reply via email to

[Prev in Thread] Current Thread [Next in Thread]