Update elpaca boostrap code.
This commit is contained in:
parent
147949285e
commit
8133266734
@ -20,12 +20,12 @@
|
|||||||
))
|
))
|
||||||
|
|
||||||
;; Instalar elpaca.el (reemplpazando package.el)
|
;; Instalar elpaca.el (reemplpazando package.el)
|
||||||
(defvar elpaca-installer-version 0.7)
|
(defvar elpaca-installer-version 0.8)
|
||||||
(defvar elpaca-directory (expand-file-name "elpaca/" user-emacs-directory))
|
(defvar elpaca-directory (expand-file-name "elpaca/" user-emacs-directory))
|
||||||
(defvar elpaca-builds-directory (expand-file-name "builds/" elpaca-directory))
|
(defvar elpaca-builds-directory (expand-file-name "builds/" elpaca-directory))
|
||||||
(defvar elpaca-repos-directory (expand-file-name "repos/" elpaca-directory))
|
(defvar elpaca-repos-directory (expand-file-name "repos/" elpaca-directory))
|
||||||
(defvar elpaca-order '(elpaca :repo "https://github.com/progfolio/elpaca.git"
|
(defvar elpaca-order '(elpaca :repo "https://github.com/progfolio/elpaca.git"
|
||||||
:ref nil
|
:ref nil :depth 1
|
||||||
:files (:defaults "elpaca-test.el" (:exclude "extensions"))
|
:files (:defaults "elpaca-test.el" (:exclude "extensions"))
|
||||||
:build (:not elpaca--activate-package)))
|
:build (:not elpaca--activate-package)))
|
||||||
(let* ((repo (expand-file-name "elpaca/" elpaca-repos-directory))
|
(let* ((repo (expand-file-name "elpaca/" elpaca-repos-directory))
|
||||||
@ -37,16 +37,18 @@
|
|||||||
(make-directory repo t)
|
(make-directory repo t)
|
||||||
(when (< emacs-major-version 28) (require 'subr-x))
|
(when (< emacs-major-version 28) (require 'subr-x))
|
||||||
(condition-case-unless-debug err
|
(condition-case-unless-debug err
|
||||||
(if-let ((buffer (pop-to-buffer-same-window "*elpaca-bootstrap*"))
|
(if-let* ((buffer (pop-to-buffer-same-window "*elpaca-bootstrap*"))
|
||||||
((zerop (call-process "git" nil buffer t "clone"
|
((zerop (apply #'call-process `("git" nil ,buffer t "clone"
|
||||||
(plist-get order :repo) repo)))
|
,@(when-let* ((depth (plist-get order :depth)))
|
||||||
((zerop (call-process "git" nil buffer t "checkout"
|
(list (format "--depth=%d" depth) "--no-single-branch"))
|
||||||
(or (plist-get order :ref) "--"))))
|
,(plist-get order :repo) ,repo))))
|
||||||
(emacs (concat invocation-directory invocation-name))
|
((zerop (call-process "git" nil buffer t "checkout"
|
||||||
((zerop (call-process emacs nil buffer nil "-Q" "-L" "." "--batch"
|
(or (plist-get order :ref) "--"))))
|
||||||
"--eval" "(byte-recompile-directory \".\" 0 'force)")))
|
(emacs (concat invocation-directory invocation-name))
|
||||||
((require 'elpaca))
|
((zerop (call-process emacs nil buffer nil "-Q" "-L" "." "--batch"
|
||||||
((elpaca-generate-autoloads "elpaca" repo)))
|
"--eval" "(byte-recompile-directory \".\" 0 'force)")))
|
||||||
|
((require 'elpaca))
|
||||||
|
((elpaca-generate-autoloads "elpaca" repo)))
|
||||||
(progn (message "%s" (buffer-string)) (kill-buffer buffer))
|
(progn (message "%s" (buffer-string)) (kill-buffer buffer))
|
||||||
(error "%s" (with-current-buffer buffer (buffer-string))))
|
(error "%s" (with-current-buffer buffer (buffer-string))))
|
||||||
((error) (warn "%s" err) (delete-directory repo 'recursive))))
|
((error) (warn "%s" err) (delete-directory repo 'recursive))))
|
||||||
|
Loading…
Reference in New Issue
Block a user