[Top][All Lists]

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

Re: feature/package-vc has been merged

From: Rudolf Adamkovič
Subject: Re: feature/package-vc has been merged
Date: Sun, 13 Nov 2022 23:11:02 +0100

Philip Kaludercic <philipk@posteo.net> writes:

>> That said, When I updated my config to install from VC, I noticed
>> that `elpa' in `.emacs.d' now contained two versions of the packages,
>> one from `package' and one from `package-vc'.
> This seems like an issue of what perspective one takes.  I don't see
> package-vc as an "upgrade" over package, but as an alternative backend
> for fetching source code.  Not even I plan to use it for everything,
> rather I'd install a source package when I am hacking on some package,
> and when I have sent out the patches and am done with it, I'd remove
> the source package and be left with the previous installation.

I like the backend idea, but the two systems, non-VC and VC, define
separate lists of selected packages.  But then, what happens when the
user selects the same package in both lists?  Will that lead to any
problems?  If so, then we should not allow the user to do that, or deal
with it in some way.

>> As a side note, you mentioned that `package-install' works for both
>> "normal" and VC packages?  I guess `package-autoremove' does that too?
>> I looked at the documentation for both and they mention just
>> `package-selected-packages'.
> I don't think I said "package-install works for both normal and VC
> packages"?  package-install fetches a tarball, package-vc-install
> fetches a repository?

I apologize for confusion.

Perhaps you said that for `package-update'?  (I remain a bit confused
about which commands apply to both VC and non-VC packages.)

>> And speaking of `-autoremove', should we also add `-vc-autoremove'?
> I don't think so, because -autoremove is for removing non-selected
> packages, while all source packages are selected (you'll find that
> package-vc uses regular tarball packages if dependencies have to be
> installed).

Really?  I thought VC `-install' works like the non-VC kind, meaning it
does not select anything, just installs a package so that the user can
quickly try it.  But you say "all source packages are selected".

>> For the only problem I have, I could not install `geiser'.  I got
>> "user-error: Package has no VC data", and I kept wondering what the user
>> should do in this situation.  I had no idea where to look.
> That sounds wrong, there seems to be a specification in
> elpa-packages.eld:
>   ("geiser" :url "https://gitlab.com/emacs-geiser/geiser.git"; :lisp-dir
>   "elisp" :readme "readme.org" :doc "doc/geiser.texi")
> Maybe this is related to MELPA?  They don't have package specification
> lists yet, and if their package is prioritised (due to their versioning
> scheme), maybe this could confused package-vc?

I tried the following two experiments, starting from:

(with-eval-after-load 'package
    '("melpa" . "https://melpa.org/packages/";))
    '("melpa-stable" . "https://stable.melpa.org/packages/";)))

Experiment 1:  Add MELPA to the end of the list.

(with-eval-after-load 'package
    '("melpa" . "https://melpa.org/packages/";)
    t)  ; <------ `t' means the end of the list
    '("melpa-stable" . "https://stable.melpa.org/packages/";)
    t)) ; <------ `t' means the end of the list

This *did not* help.

Experiment 2: Comment out MELPA.

;; (with-eval-after-load 'package
;;   (add-to-list
;;     'package-archives
;;     '("melpa" . "https://melpa.org/packages/";))
;;   (add-to-list
;;     'package-archives
;;     '("melpa-stable" . "https://stable.melpa.org/packages/";)))

This *did* help.

If the user has MELPA at the end of the list, it should just work.  So,
that needs fixing.  But the question becomes, what should happen if the
user has MELPA at the beginning of the list.  VC could fail, but it
could also proceed, silently or with a message.

>> I will try more packages in the coming days or weeks!
> Very appreciative.  But this is a good sign that after bug#59109 has
> been resolved, the changes can be applied back onto master.
>> P.S. The documentation for the `package-vc-selected-packages' variable
>> contains a typo "... you cal also use ...".
> Will fix, thanks!


Also, the documentation for the `package-vc-install' function needs some
blank lines between paragraphs.  :)

"Strange as it may sound, the power of mathematics rests on its evasion
of all unnecessary thought and on its wonderful saving of mental
-- Ernst Mach, 1838-1916

Rudolf Adamkovič <salutis@me.com> [he/him]
Studenohorská 25
84103 Bratislava

reply via email to

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