mirror of
https://github.com/dimitri/el-get.git
synced 2024-09-30 05:29:52 +08:00
32ab64f47e
ELPA Package directories are named <package>-<version>. Previously `el-get-elpa-package-directory' looked for package-dirs using `all-completions' meaning anything starting with <package> would match. This is problematic if a package is a prefix of another package, eg the `s' and `solarized-theme' packages. Instead of doing that, look for a directory that is precisely <package>-<version> where <version> is something acceptable to `version-to-list'. Fixes #1189.
17 lines
633 B
EmacsLisp
17 lines
633 B
EmacsLisp
;;; When installing a package whose name is a prefix of an already
|
|
;;; installed package, `el-get-elpa-package-directory' gets confused.
|
|
|
|
(setq el-get-sources
|
|
'((:name load-dir ; I tried to pick the smallest package
|
|
:type elpa
|
|
:description "Load all Emacs Lisp files in a given directory"
|
|
:repo ("gnu" . "http://elpa.gnu.org/packages/"))))
|
|
|
|
(el-get 'sync 'load-dir)
|
|
|
|
(assert (not (equal (el-get-elpa-package-directory 'load)
|
|
(el-get-elpa-package-directory 'load-dir)))
|
|
nil
|
|
"a package name `load' shouldn't use the same directory
|
|
as `load-dir'.")
|