dimitri/el-get

el-get want's to delete itself and complains that it can't

Opened this issue · 6 comments

dfrkp commented

Hi!

I'm installing and using el-get through req-package (a use-package wrapper). Everything works but I get an annoying error on every startup:

Error (el-get): while initializing el-get: Package ‘el-get-20180126.1603’ is used by ‘req-package’ as dependency, not deleting

Here's the relevant piece from my init.el:

(require 'req-package)
(req-package--log-set-level 'trace)
(req-package el-get
  :force t
  :config
  (add-to-list 'el-get-recipe-path "~/.emacs.d/el-get/el-get/recipes")
  (add-to-list 'load-path "~/.emacs.d/el-get/el-get")
  (el-get 'sync))

I realize that the error might be caused trough req-package, but when I tried to understand the source of the the error message it leads me into el-get. So maybe I'm just lacking the proper understanding or it is some behavior in el-get that is at play.

Thank you!

Hmm, el-get's installation via MELPA was intended to be a convenience, because it installs the "real" copy using its own code, and then tries to remove the MELPA installed one (#1982, #2006). It seems that req-package recently added a declaration to depend on the MELPA installed one though: emacsorphanage/req-package#53. I'm not sure how best to resolve it.

Ok, so basically, no package in MELPA should ever declare a dependency on the el-get MELPA package, right? This fact should probably be documented somewhere if it's not already, and should maybe be added to https://github.com/purcell/package-lint.

As an alternative, would it be possible for the MELPA el-get to leave itself installed but remove itself from load-path and then reload el-get, thus pulling in the "real" el-get? That would allow other MELPA packages to depend on it, I think.

As an alternative, would it be possible for the MELPA el-get to leave itself installed but remove itself from load-path and then reload el-get, thus pulling in the "real" el-get?

It's possible, but reloading elisp is generally unreliable.

Ok, so it's preferable to remove the package entirely so that on subsequent Emacs startups, the correct copy of el-get is loaded on the first try. So does that mean I'm correct that no other MELPA package should declare a dependency on el-get?

So does that mean I'm correct that no other MELPA package should declare a dependency on el-get?

Yeah, I think so.