Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failed bootstrap when using proxychains-ng (Ubuntu 20.04). #786

Closed
hongyi-zhao opened this issue Jun 9, 2021 · 50 comments
Closed

Failed bootstrap when using proxychains-ng (Ubuntu 20.04). #786

hongyi-zhao opened this issue Jun 9, 2021 · 50 comments

Comments

@hongyi-zhao
Copy link

hongyi-zhao commented Jun 9, 2021

On Ubuntu 20.04, I'm using the git master version of Emacs compiled by me. Now, I try to use straight.el and use-package at the same time. According to the instruction here, I place the following bootstrap code in my ~/.emacs.d/init.el:

(setq package-enable-at-startup nil)
(defvar bootstrap-version)
(let ((bootstrap-file
       (expand-file-name "straight/repos/straight.el/bootstrap.el" user-emacs-directory))
      (bootstrap-version 5))
  (unless (file-exists-p bootstrap-file)
    (with-current-buffer
        (url-retrieve-synchronously
         "https://raw.githubusercontent.com/raxod502/straight.el/develop/install.el"
         'silent 'inhibit-cookies)
      (goto-char (point-max))
      (eval-print-last-sexp)))
  (load bootstrap-file nil 'nomessage))

When I try to start Emacs, I meet the following errors:

Debugger entered--Lisp error: (error "straight.el bootstrap failed: \nDebugger entered--L...")
  signal(error ("straight.el bootstrap failed: \nDebugger entered--L..."))
  error("straight.el bootstrap failed: %s" "\nDebugger entered--Lisp error: (error \"Failed to r...")
  (if (= 0 (call-process (let ((emacs-binary-path (expand-file-name invocation-name invocation-directory)) (runemacs-binary-path (if (straight--windows-os-p) (progn ...)))) (if (and runemacs-binary-path (file-exists-p runemacs-binary-path)) runemacs-binary-path emacs-binary-path)) nil '(t t) nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string)))
  (progn (if (= 0 (call-process (let ((emacs-binary-path (expand-file-name invocation-name invocation-directory)) (runemacs-binary-path (if ... ...))) (if (and runemacs-binary-path (file-exists-p runemacs-binary-path)) runemacs-binary-path emacs-binary-path)) nil '(t t) nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string))))
  (unwind-protect (progn (if (= 0 (call-process (let ((emacs-binary-path ...) (runemacs-binary-path ...)) (if (and runemacs-binary-path ...) runemacs-binary-path emacs-binary-path)) nil '(t t) nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string)))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))
  (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (if (= 0 (call-process (let (... ...) (if ... runemacs-binary-path emacs-binary-path)) nil '(t t) nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string)))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))
  (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (if (= 0 (call-process (let ... ...) nil '... nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string)))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))))
  (let ((temp-file (make-temp-file "straight.el~"))) (write-region nil nil temp-file nil 'silent) (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (if (= 0 (call-process ... nil ... nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string)))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))))
  (save-current-buffer (set-buffer (url-retrieve-synchronously (format (concat "https://raw.githubusercontent.com/" "raxod502/straight.el/install/%s/straight.el") (substring (symbol-name version) 1)) 'silent 'inhibit-cookies)) (if (equal url-http-response-status 200) nil (error "Unknown recipe version: %S" version)) (delete-region (point-min) url-http-end-of-headers) (goto-char (point-min)) (princ ";; -*- coding: utf-8 -*-" (current-buffer)) (print (cons 'progn (let* ((vars nil) (regexps '("bootstrap-version" "straight-[a-z-]+" "user-emacs-directory")) (regexp (format "^\\(%s\\)$" (mapconcat ... regexps "\\|")))) (mapatoms #'(lambda (sym) (if ... ...))) (mapcar #'(lambda (var) (list ... var ...)) vars))) (current-buffer)) (goto-char (point-max)) (print '(progn (straight-use-package-no-build `(straight :type git :host github :repo ,... :branch ,...)) (unless (and (boundp 'bootstrap-version) (integerp bootstrap-version) (>= bootstrap-version 3)) (let* ((recipe ...) (local-repo ...) (link-target ...) (link-name ...)) (ignore-errors (delete-file link-name)) (if (bound-and-true-p straight-use-symlinks) (if ... ... ...) (with-temp-file link-name ...))))) (current-buffer)) (let ((temp-file (make-temp-file "straight.el~"))) (write-region nil nil temp-file nil 'silent) (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (if (= 0 ...) nil (error "straight.el bootstrap failed: %s" ...))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))))))
  (let ((version nil) (straight-profiles (if (boundp 'straight-profiles) straight-profiles '((nil . "default.el")))) (straight-install-dir (or (and (boundp 'straight-base-dir) straight-base-dir) user-emacs-directory)) (print-length nil) (print-level nil)) (let ((--dolist-tail-- (mapcar #'cdr straight-profiles)) lockfile-name) (while --dolist-tail-- (setq lockfile-name (car --dolist-tail--)) (let ((lockfile-path (concat straight-install-dir "straight/versions/" lockfile-name))) (if (file-exists-p lockfile-path) (progn (condition-case nil (let ... ...) (end-of-file ...))))) (setq --dolist-tail-- (cdr --dolist-tail--)))) (if version nil (setq version :beta)) (save-current-buffer (set-buffer (url-retrieve-synchronously (format (concat "https://raw.githubusercontent.com/" "raxod502/straight.el/install/%s/straight.el") (substring (symbol-name version) 1)) 'silent 'inhibit-cookies)) (if (equal url-http-response-status 200) nil (error "Unknown recipe version: %S" version)) (delete-region (point-min) url-http-end-of-headers) (goto-char (point-min)) (princ ";; -*- coding: utf-8 -*-" (current-buffer)) (print (cons 'progn (let* ((vars nil) (regexps '...) (regexp (format "^\\(%s\\)$" ...))) (mapatoms #'(lambda ... ...)) (mapcar #'(lambda ... ...) vars))) (current-buffer)) (goto-char (point-max)) (print '(progn (straight-use-package-no-build `(straight :type git :host github :repo ... :branch ...)) (unless (and (boundp ...) (integerp bootstrap-version) (>= bootstrap-version 3)) (let* (... ... ... ...) (ignore-errors ...) (if ... ... ...)))) (current-buffer)) (let ((temp-file (make-temp-file "straight.el~"))) (write-region nil nil temp-file nil 'silent) (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (if ... nil ...)) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))))))
  (progn (message "Bootstrapping straight.el...") (let ((min-version "25.1")) (if (version< emacs-version min-version) (progn (error (concat "straight.el requires at least Emacs %s, " "but you are running Emacs %s") min-version emacs-version)))) (if (boundp 'straight-repository-branch) (progn (if (stringp straight-repository-branch) nil (error "The `straight-repository-branch' must be a string ..." straight-repository-branch)))) (if (executable-find "git") nil (user-error "Git executable not found. straight.el requires git")) (require 'cl-lib) (require 'url-http) (defvar url-http-end-of-headers) (defvar url-http-response-status) (defalias 'straight--windows-os-p #'(lambda nil "Check if the current operating system is Windows." (memq system-type '(ms-dos windows-nt)))) (let ((version nil) (straight-profiles (if (boundp 'straight-profiles) straight-profiles '((nil . "default.el")))) (straight-install-dir (or (and (boundp 'straight-base-dir) straight-base-dir) user-emacs-directory)) (print-length nil) (print-level nil)) (let ((--dolist-tail-- (mapcar #'cdr straight-profiles)) lockfile-name) (while --dolist-tail-- (setq lockfile-name (car --dolist-tail--)) (let ((lockfile-path (concat straight-install-dir "straight/versions/" lockfile-name))) (if (file-exists-p lockfile-path) (progn (condition-case nil ... ...)))) (setq --dolist-tail-- (cdr --dolist-tail--)))) (if version nil (setq version :beta)) (save-current-buffer (set-buffer (url-retrieve-synchronously (format (concat "https://raw.githubusercontent.com/" "raxod502/straight.el/install/%s/straight.el") (substring (symbol-name version) 1)) 'silent 'inhibit-cookies)) (if (equal url-http-response-status 200) nil (error "Unknown recipe version: %S" version)) (delete-region (point-min) url-http-end-of-headers) (goto-char (point-min)) (princ ";; -*- coding: utf-8 -*-" (current-buffer)) (print (cons 'progn (let* ((vars nil) (regexps ...) (regexp ...)) (mapatoms #'...) (mapcar #'... vars))) (current-buffer)) (goto-char (point-max)) (print '(progn (straight-use-package-no-build `...) (unless (and ... ... ...) (let* ... ... ...))) (current-buffer)) (let ((temp-file (make-temp-file "straight.el~"))) (write-region nil nil temp-file nil 'silent) (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn ...) (and ... ...))))))) (message "Bootstrapping straight.el...done"))
  eval((progn (message "Bootstrapping straight.el...") (let ((min-version "25.1")) (if (version< emacs-version min-version) (progn (error (concat "straight.el requires at least Emacs %s, " "but you are running Emacs %s") min-version emacs-version)))) (if (boundp 'straight-repository-branch) (progn (if (stringp straight-repository-branch) nil (error "The `straight-repository-branch' must be a string ..." straight-repository-branch)))) (if (executable-find "git") nil (user-error "Git executable not found. straight.el requires git")) (require 'cl-lib) (require 'url-http) (defvar url-http-end-of-headers) (defvar url-http-response-status) (defalias 'straight--windows-os-p #'(lambda nil "Check if the current operating system is Windows." (memq system-type '(ms-dos windows-nt)))) (let ((version nil) (straight-profiles (if (boundp 'straight-profiles) straight-profiles '(...))) (straight-install-dir (or (and (boundp ...) straight-base-dir) user-emacs-directory)) (print-length nil) (print-level nil)) (let ((--dolist-tail-- (mapcar #'cdr straight-profiles)) lockfile-name) (while --dolist-tail-- (setq lockfile-name (car --dolist-tail--)) (let ((lockfile-path ...)) (if (file-exists-p lockfile-path) (progn ...))) (setq --dolist-tail-- (cdr --dolist-tail--)))) (if version nil (setq version :beta)) (save-current-buffer (set-buffer (url-retrieve-synchronously (format (concat "https://raw.githubusercontent.com/" "raxod502/straight.el/install/%s/straight.el") (substring ... 1)) 'silent 'inhibit-cookies)) (if (equal url-http-response-status 200) nil (error "Unknown recipe version: %S" version)) (delete-region (point-min) url-http-end-of-headers) (goto-char (point-min)) (princ ";; -*- coding: utf-8 -*-" (current-buffer)) (print (cons 'progn (let* (... ... ...) (mapatoms ...) (mapcar ... vars))) (current-buffer)) (goto-char (point-max)) (print '(progn (straight-use-package-no-build ...) (unless ... ...)) (current-buffer)) (let ((temp-file (make-temp-file "straight.el~"))) (write-region nil nil temp-file nil 'silent) (let ((temp-buffer ...)) (save-current-buffer (set-buffer temp-buffer) (unwind-protect ... ...)))))) (message "Bootstrapping straight.el...done")) nil)
  elisp--eval-last-sexp(t)
  eval-last-sexp(t)
  eval-print-last-sexp()
  (save-current-buffer (set-buffer (url-retrieve-synchronously "https://raw.githubusercontent.com/raxod502/straigh..." 'silent 'inhibit-cookies)) (goto-char (point-max)) (eval-print-last-sexp))
  (if (file-exists-p bootstrap-file) nil (save-current-buffer (set-buffer (url-retrieve-synchronously "https://raw.githubusercontent.com/raxod502/straigh..." 'silent 'inhibit-cookies)) (goto-char (point-max)) (eval-print-last-sexp)))
  (let ((bootstrap-file (expand-file-name "straight/repos/straight.el/bootstrap.el" user-emacs-directory)) (bootstrap-version 5)) (if (file-exists-p bootstrap-file) nil (save-current-buffer (set-buffer (url-retrieve-synchronously "https://raw.githubusercontent.com/raxod502/straigh..." 'silent 'inhibit-cookies)) (goto-char (point-max)) (eval-print-last-sexp))) (load bootstrap-file nil 'nomessage))
  eval-buffer(#<buffer  *load*> nil "/home/werner/.emacs.d/init.el" nil t)  ; Reading at buffer position 10604
  load-with-code-conversion("/home/werner/.emacs.d/init.el" "/home/werner/.emacs.d/init.el" t t)
  load("/home/werner/.emacs.d/init" noerror nomessage)
  startup--load-user-init-file(#f(compiled-function () #<bytecode 0xcb385b504c57876>) #f(compiled-function () #<bytecode -0x1f3c686ddc0dc635>) t)
  command-line()
  normal-top-level()

Any hints for solving this problem?

Regards,
HY

@progfolio
Copy link
Contributor

Please include the output of M-x emacs-version and the full error message.
(the backtrace is helpful, but the message is truncated)

@hongyi-zhao
Copy link
Author

Please include the output of M-x emacs-version

GNU Emacs 28.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.20, cairo version 1.16.0) of 2021-05-16

and the full error message.

How to obtain it?

@progfolio
Copy link
Contributor

How to obtain it?

It should be in the *Messages* buffer, it would also be helpful to see the contents of the *straight-process* buffer if it exists.

@hongyi-zhao
Copy link
Author

It should be in the Messages buffer,

See below:

Public/repo/github.com/jwiegley/use-package.git/bind-key.el: Warning: Use keywords rather than deprecated positional arguments to `define-minor-mode'
Bootstrapping straight.el...
Entering debugger...
Beginning of buffer [12 times]

it would also be helpful to see the contents of the straight-process buffer if it exists.

No this buffer at all.

@progfolio
Copy link
Contributor

If you have your init file uploaded somewhere I can take a look at it for you.

@progfolio
Copy link
Contributor

You can also try evaluating the following in your *scratch* buffer:

(straight-bug-report)

It will install straight in a clean, temporary environment. When it's done, the *straight-bug-report-process* buffer should pop up and you can copy the results here.

@hongyi-zhao
Copy link
Author

hongyi-zhao commented Jun 10, 2021

You can also try evaluating the following in your scratch buffer:
(straight-bug-report)

Sorry for my poor understanding on Emacs. I try to input the above command in scratch buffer, and then C-j on it, but nothing happened for my case, as shown below:

image

It will install straight in a clean, temporary environment.

Do you mean that this will re-load the settings in init.el from scratch?

@progfolio
Copy link
Contributor

With point after that expression run M-x eval-last-sexp.

@hongyi-zhao
Copy link
Author

image

@progfolio
Copy link
Contributor

Can you link to your init.el and early-init.el files? If you don't have them on github you can upload them temporarily to something like pastebin.

@hongyi-zhao
Copy link
Author

hongyi-zhao commented Jun 10, 2021

See here for my init.el. As for the early-init.el file described here, currently I haven't used it for any settings.

@progfolio
Copy link
Contributor

progfolio commented Jun 10, 2021

It looks like you're trying to use package.el alongside straight.el, which is not recommended.

See: https://github.com/raxod502/straight.el#getting-started
And: https://github.com/raxod502/straight.el#integration-with-packageel

Note you'll want to follow the instructions about early-init.el, too, since you're on Emacs 28.

What I would do is start with a minimal init file with just the straight bootstrap code and see if that works.
Then you can start adding things back in.

@hongyi-zhao
Copy link
Author

hongyi-zhao commented Jun 10, 2021

It looks like you're trying to use package.el alongside straight.el, which is not recommended.

The starting point of this issue is that I noticed the following snippet code:

(use-package mathpix.el
  :straight (:host github :repo "jethrokuan/mathpix.el")
  :custom ((mathpix-app-id "app-id")
           (mathpix-app-key "app-key"))
  :bind
  ("C-x m" . mathpix-screenshot))

I'm currently mainly work with use-package which loads packages from (M)ELPA with package.el under the hood, if I understand its working mechanism correctly, as described here.

As you can see, the above initialization code calls straight to install package from GitHub repo directly. If I don't use package.el alongside straight.el, how can I achieve the same purpose as done by the above code.

@progfolio
Copy link
Contributor

progfolio commented Jun 10, 2021

use-package's :ensure keyword and use-package-always-ensure utilize package.el to do package installation. So it's recommended to avoid those when using straight as your package manager.

Straight replaces package.el.
Straight adds the :straight keyword to use-package to install packages via use-package. So what you have above is correct.

Generally you'd want to structure your init file something like this:

;;Bootstrap straight
(defvar bootstrap-version)
(let ((bootstrap-file
       (expand-file-name "straight/repos/straight.el/bootstrap.el" user-emacs-directory))
      (bootstrap-version 5))
  (unless (file-exists-p bootstrap-file)
    (with-current-buffer
        (url-retrieve-synchronously
         "https://raw.githubusercontent.com/raxod502/straight.el/develop/install.el"
         'silent 'inhibit-cookies)
      (goto-char (point-max))
      (eval-print-last-sexp)))
  (load bootstrap-file nil 'nomessage))

;; Install use-package via straight
(straight-use-package 'use-package)

;; Setting this to `t' makes it so that you don't need to include the :straight
;; keyword in use-package declarations unless you want to add/extend the package
;; installation recipe.

(setq straight-use-package-by-default t) ; straight's equivalent of `use-package-always-ensure'.

;; For package listed in recipe repositories (such as MELPA), you can just do:

;; (use-package foo)

;; This expands to:

;; (progn
;;  (straight-use-package 'foo)
;;  (require 'foo nil nil))

;; For packages that aren't listed in a recipe repository, but are available at a forge (e.g. github):

(use-package mathpix.el :straight (:host github :repo "jethrokaun/mathpix.el"))

;; Which expands to:

;; (progn
;;   (straight-use-package
;;    '(mathpix\.el :host github :repo "jethrokaun/mathpix.el"))
;;   (require 'mathpix\.el nil nil))

Does that help?

@hongyi-zhao
Copy link
Author

use-package's :ensure keyword and use-package-always-ensure utilize package.el to do package installation. So it's recommended to avoid those when using straight as your package manager.

If so, what should I change/revise them to, in order to obtain the same effect?

@progfolio
Copy link
Contributor

progfolio commented Jun 11, 2021

If so, what should I change/revise them to, in order to obtain the same effect?

See above:

(setq straight-use-package-by-default t) ; straight's equivalent of `use-package-always-ensure'.

Then you only need to add the :straight keyword in cases where the recipe is not in a recipe repository.
e.g. mathpix.el, which jethro provided the recipe for on the package's github page.

Here are some examples:

Using package.el:
;; without the always ensure option

(setq use-package-always-ensure nil)
(use-package foo :ensure t)

Converted to use straight.el:

(setq straight-use-package-by-default nil) 
(use-package foo :straight t)

But for convenience sake, you probably want to install by default.

Using package.el:

(setq use-package-always-ensure t)
(use-package foo)

Converted to use straight.el:

(setq straight-use-package-by-default t)
(use-package foo)

Does that make sense?

@hongyi-zhao
Copy link
Author

hongyi-zhao commented Jun 11, 2021

Wonderful explanations. I will try it according to your comments and give the necessary feedback. Another thing I don't understand is the notes described here:

To use the MELPA repository, you'll need an Emacs with package.el and TLS support, ie. Emacs 24.1 or greater.
[...]
Enable installation of packages from MELPA by adding an entry to package-archives after (require 'package) and before the call to package-initialize in your init.el or .emacs file:

(require 'package)
[...]

So, it seems that the the MELPA repository depends on package.el, how to deal with this with straight?

@progfolio
Copy link
Contributor

progfolio commented Jun 11, 2021

You don't need to do any of that to use straight. Those are instructions geared toward using the built-in package manager, package.el. Straight has its own support for MELPA.

Use the bootstrap code to install straight:

(defvar bootstrap-version)
(let ((bootstrap-file
       (expand-file-name "straight/repos/straight.el/bootstrap.el" user-emacs-directory))
      (bootstrap-version 5))
  (unless (file-exists-p bootstrap-file)
    (with-current-buffer
        (url-retrieve-synchronously
         "https://raw.githubusercontent.com/raxod502/straight.el/develop/install.el"
         'silent 'inhibit-cookies)
      (goto-char (point-max))
      (eval-print-last-sexp)))
  (load bootstrap-file nil 'nomessage))

Then start installing the packages you want from MELPA via straight-use-package.
I'll use a package I wrote, doct, as an example:

(straight-use-package 'doct)

That's all you have to do.
If you're curious how straight knew what recipe to use for doct, see:

https://github.com/raxod502/straight.el/tree/develop#where-do-recipes-come-from

@hongyi-zhao
Copy link
Author

Thank you again for your excellent and comprehensive answer. Once I have time, I will try as soon as possible.

@hongyi-zhao
Copy link
Author

hongyi-zhao commented Jun 11, 2021

I tried with the following minimal version of ~/.emacs.d/init.el.straight but still failed to bootstrap straight.el:

(setq package-archives '(("gnu"   . "https://elpa.gnu.org/packages/")
                         ("melpa" . "https://melpa.org/packages/")
                         ("org" . "https://orgmode.org/elpa/")))
(package-initialize)

;;Bootstrap straight
(defvar bootstrap-version)
(let ((bootstrap-file
       (expand-file-name "straight/repos/straight.el/bootstrap.el" user-emacs-directory))
      (bootstrap-version 5))
  (unless (file-exists-p bootstrap-file)
    (with-current-buffer
        (url-retrieve-synchronously
         "https://raw.githubusercontent.com/raxod502/straight.el/develop/install.el"
         'silent 'inhibit-cookies)
      (goto-char (point-max))
      (eval-print-last-sexp)))
  (load bootstrap-file nil 'nomessage))

;; Install use-package via straight
(straight-use-package 'use-package)

;; Setting this to `t' makes it so that you don't need to include the :straight
;; keyword in use-package declarations unless you want to add/extend the package
;; installation recipe.

(setq straight-use-package-by-default t) ; straight's equivalent of `use-package-always-ensure'.

The testing command and the error info for this specific init-file are shown below:

$ emacs -q --load ~/.emacs.d/init.el.straight

Debugger entered--Lisp error: (error "straight.el bootstrap failed: \nDebugger entered--L...")
  signal(error ("straight.el bootstrap failed: \nDebugger entered--L..."))
  error("straight.el bootstrap failed: %s" "\nDebugger entered--Lisp error: (error \"Failed to r...")
  (if (= 0 (call-process (let ((emacs-binary-path (expand-file-name invocation-name invocation-directory)) (runemacs-binary-path (if (straight--windows-os-p) (progn ...)))) (if (and runemacs-binary-path (file-exists-p runemacs-binary-path)) runemacs-binary-path emacs-binary-path)) nil '(t t) nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string)))
  (progn (if (= 0 (call-process (let ((emacs-binary-path (expand-file-name invocation-name invocation-directory)) (runemacs-binary-path (if ... ...))) (if (and runemacs-binary-path (file-exists-p runemacs-binary-path)) runemacs-binary-path emacs-binary-path)) nil '(t t) nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string))))
  (unwind-protect (progn (if (= 0 (call-process (let ((emacs-binary-path ...) (runemacs-binary-path ...)) (if (and runemacs-binary-path ...) runemacs-binary-path emacs-binary-path)) nil '(t t) nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string)))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))
  (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (if (= 0 (call-process (let (... ...) (if ... runemacs-binary-path emacs-binary-path)) nil '(t t) nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string)))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))
  (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (if (= 0 (call-process (let ... ...) nil '... nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string)))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))))
  (let ((temp-file (make-temp-file "straight.el~"))) (write-region nil nil temp-file nil 'silent) (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (if (= 0 (call-process ... nil ... nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string)))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))))
  (save-current-buffer (set-buffer (url-retrieve-synchronously (format (concat "https://raw.githubusercontent.com/" "raxod502/straight.el/install/%s/straight.el") (substring (symbol-name version) 1)) 'silent 'inhibit-cookies)) (if (equal url-http-response-status 200) nil (error "Unknown recipe version: %S" version)) (delete-region (point-min) url-http-end-of-headers) (goto-char (point-min)) (princ ";; -*- coding: utf-8 -*-" (current-buffer)) (print (cons 'progn (let* ((vars nil) (regexps '("bootstrap-version" "straight-[a-z-]+" "user-emacs-directory")) (regexp (format "^\\(%s\\)$" (mapconcat ... regexps "\\|")))) (mapatoms #'(lambda (sym) (if ... ...))) (mapcar #'(lambda (var) (list ... var ...)) vars))) (current-buffer)) (goto-char (point-max)) (print '(progn (straight-use-package-no-build `(straight :type git :host github :repo ,... :branch ,...)) (unless (and (boundp 'bootstrap-version) (integerp bootstrap-version) (>= bootstrap-version 3)) (let* ((recipe ...) (local-repo ...) (link-target ...) (link-name ...)) (ignore-errors (delete-file link-name)) (if (bound-and-true-p straight-use-symlinks) (if ... ... ...) (with-temp-file link-name ...))))) (current-buffer)) (let ((temp-file (make-temp-file "straight.el~"))) (write-region nil nil temp-file nil 'silent) (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (if (= 0 ...) nil (error "straight.el bootstrap failed: %s" ...))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))))))
  (let ((version nil) (straight-profiles (if (boundp 'straight-profiles) straight-profiles '((nil . "default.el")))) (straight-install-dir (or (and (boundp 'straight-base-dir) straight-base-dir) user-emacs-directory)) (print-length nil) (print-level nil)) (let ((--dolist-tail-- (mapcar #'cdr straight-profiles)) lockfile-name) (while --dolist-tail-- (setq lockfile-name (car --dolist-tail--)) (let ((lockfile-path (concat straight-install-dir "straight/versions/" lockfile-name))) (if (file-exists-p lockfile-path) (progn (condition-case nil (let ... ...) (end-of-file ...))))) (setq --dolist-tail-- (cdr --dolist-tail--)))) (if version nil (setq version :beta)) (save-current-buffer (set-buffer (url-retrieve-synchronously (format (concat "https://raw.githubusercontent.com/" "raxod502/straight.el/install/%s/straight.el") (substring (symbol-name version) 1)) 'silent 'inhibit-cookies)) (if (equal url-http-response-status 200) nil (error "Unknown recipe version: %S" version)) (delete-region (point-min) url-http-end-of-headers) (goto-char (point-min)) (princ ";; -*- coding: utf-8 -*-" (current-buffer)) (print (cons 'progn (let* ((vars nil) (regexps '...) (regexp (format "^\\(%s\\)$" ...))) (mapatoms #'(lambda ... ...)) (mapcar #'(lambda ... ...) vars))) (current-buffer)) (goto-char (point-max)) (print '(progn (straight-use-package-no-build `(straight :type git :host github :repo ... :branch ...)) (unless (and (boundp ...) (integerp bootstrap-version) (>= bootstrap-version 3)) (let* (... ... ... ...) (ignore-errors ...) (if ... ... ...)))) (current-buffer)) (let ((temp-file (make-temp-file "straight.el~"))) (write-region nil nil temp-file nil 'silent) (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (if ... nil ...)) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))))))
  (progn (message "Bootstrapping straight.el...") (let ((min-version "25.1")) (if (version< emacs-version min-version) (progn (error (concat "straight.el requires at least Emacs %s, " "but you are running Emacs %s") min-version emacs-version)))) (if (boundp 'straight-repository-branch) (progn (if (stringp straight-repository-branch) nil (error "The `straight-repository-branch' must be a string ..." straight-repository-branch)))) (if (executable-find "git") nil (user-error "Git executable not found. straight.el requires git")) (require 'cl-lib) (require 'url-http) (defvar url-http-end-of-headers) (defvar url-http-response-status) (defalias 'straight--windows-os-p #'(lambda nil "Check if the current operating system is Windows." (memq system-type '(ms-dos windows-nt)))) (let ((version nil) (straight-profiles (if (boundp 'straight-profiles) straight-profiles '((nil . "default.el")))) (straight-install-dir (or (and (boundp 'straight-base-dir) straight-base-dir) user-emacs-directory)) (print-length nil) (print-level nil)) (let ((--dolist-tail-- (mapcar #'cdr straight-profiles)) lockfile-name) (while --dolist-tail-- (setq lockfile-name (car --dolist-tail--)) (let ((lockfile-path (concat straight-install-dir "straight/versions/" lockfile-name))) (if (file-exists-p lockfile-path) (progn (condition-case nil ... ...)))) (setq --dolist-tail-- (cdr --dolist-tail--)))) (if version nil (setq version :beta)) (save-current-buffer (set-buffer (url-retrieve-synchronously (format (concat "https://raw.githubusercontent.com/" "raxod502/straight.el/install/%s/straight.el") (substring (symbol-name version) 1)) 'silent 'inhibit-cookies)) (if (equal url-http-response-status 200) nil (error "Unknown recipe version: %S" version)) (delete-region (point-min) url-http-end-of-headers) (goto-char (point-min)) (princ ";; -*- coding: utf-8 -*-" (current-buffer)) (print (cons 'progn (let* ((vars nil) (regexps ...) (regexp ...)) (mapatoms #'...) (mapcar #'... vars))) (current-buffer)) (goto-char (point-max)) (print '(progn (straight-use-package-no-build `...) (unless (and ... ... ...) (let* ... ... ...))) (current-buffer)) (let ((temp-file (make-temp-file "straight.el~"))) (write-region nil nil temp-file nil 'silent) (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn ...) (and ... ...))))))) (message "Bootstrapping straight.el...done"))
  eval((progn (message "Bootstrapping straight.el...") (let ((min-version "25.1")) (if (version< emacs-version min-version) (progn (error (concat "straight.el requires at least Emacs %s, " "but you are running Emacs %s") min-version emacs-version)))) (if (boundp 'straight-repository-branch) (progn (if (stringp straight-repository-branch) nil (error "The `straight-repository-branch' must be a string ..." straight-repository-branch)))) (if (executable-find "git") nil (user-error "Git executable not found. straight.el requires git")) (require 'cl-lib) (require 'url-http) (defvar url-http-end-of-headers) (defvar url-http-response-status) (defalias 'straight--windows-os-p #'(lambda nil "Check if the current operating system is Windows." (memq system-type '(ms-dos windows-nt)))) (let ((version nil) (straight-profiles (if (boundp 'straight-profiles) straight-profiles '(...))) (straight-install-dir (or (and (boundp ...) straight-base-dir) user-emacs-directory)) (print-length nil) (print-level nil)) (let ((--dolist-tail-- (mapcar #'cdr straight-profiles)) lockfile-name) (while --dolist-tail-- (setq lockfile-name (car --dolist-tail--)) (let ((lockfile-path ...)) (if (file-exists-p lockfile-path) (progn ...))) (setq --dolist-tail-- (cdr --dolist-tail--)))) (if version nil (setq version :beta)) (save-current-buffer (set-buffer (url-retrieve-synchronously (format (concat "https://raw.githubusercontent.com/" "raxod502/straight.el/install/%s/straight.el") (substring ... 1)) 'silent 'inhibit-cookies)) (if (equal url-http-response-status 200) nil (error "Unknown recipe version: %S" version)) (delete-region (point-min) url-http-end-of-headers) (goto-char (point-min)) (princ ";; -*- coding: utf-8 -*-" (current-buffer)) (print (cons 'progn (let* (... ... ...) (mapatoms ...) (mapcar ... vars))) (current-buffer)) (goto-char (point-max)) (print '(progn (straight-use-package-no-build ...) (unless ... ...)) (current-buffer)) (let ((temp-file (make-temp-file "straight.el~"))) (write-region nil nil temp-file nil 'silent) (let ((temp-buffer ...)) (save-current-buffer (set-buffer temp-buffer) (unwind-protect ... ...)))))) (message "Bootstrapping straight.el...done")) nil)
  elisp--eval-last-sexp(t)
  eval-last-sexp(t)
  eval-print-last-sexp()
  (save-current-buffer (set-buffer (url-retrieve-synchronously "https://raw.githubusercontent.com/raxod502/straigh..." 'silent 'inhibit-cookies)) (goto-char (point-max)) (eval-print-last-sexp))
  (if (file-exists-p bootstrap-file) nil (save-current-buffer (set-buffer (url-retrieve-synchronously "https://raw.githubusercontent.com/raxod502/straigh..." 'silent 'inhibit-cookies)) (goto-char (point-max)) (eval-print-last-sexp)))
  (let ((bootstrap-file (expand-file-name "straight/repos/straight.el/bootstrap.el" user-emacs-directory)) (bootstrap-version 5)) (if (file-exists-p bootstrap-file) nil (save-current-buffer (set-buffer (url-retrieve-synchronously "https://raw.githubusercontent.com/raxod502/straigh..." 'silent 'inhibit-cookies)) (goto-char (point-max)) (eval-print-last-sexp))) (load bootstrap-file nil 'nomessage))
  eval-buffer(#<buffer  *load*> nil "/home/werner/.emacs.d/init.el" nil t)  ; Reading at buffer position 736
  load-with-code-conversion("/home/werner/.emacs.d/init.el" "/home/werner/.emacs.d/init.el" t t)
  load("/home/werner/.emacs.d/init" noerror nomessage)
  startup--load-user-init-file(#f(compiled-function () #<bytecode 0xd7edbf857db0476>) #f(compiled-function () #<bytecode -0x1f3c686ddc0dc635>) t)
  command-line()
  normal-top-level()

@progfolio
Copy link
Contributor

progfolio commented Jun 11, 2021

Remove this:

(setq package-archives '(("gnu"   . "https://elpa.gnu.org/packages/")
                         ("melpa" . "https://melpa.org/packages/")
                         ("org" . "https://orgmode.org/elpa/")))
(package-initialize)

package.el is not compatible with straight

@hongyi-zhao
Copy link
Author

hongyi-zhao commented Jun 11, 2021

Still failed, see following:

$ cat ~/.emacs.d/init.el.straight 
;https://stackoverflow.com/questions/17146844/is-there-a-way-to-specify-custom-init-file-on-emacs-startup/17149070
;$ emacs -q --load ~/.emacs.d/init.el.straight
;;Bootstrap straight
(defvar bootstrap-version)
(let ((bootstrap-file
       (expand-file-name "straight/repos/straight.el/bootstrap.el" user-emacs-directory))
      (bootstrap-version 5))
  (unless (file-exists-p bootstrap-file)
    (with-current-buffer
        (url-retrieve-synchronously
         "https://raw.githubusercontent.com/raxod502/straight.el/develop/install.el"
         'silent 'inhibit-cookies)
      (goto-char (point-max))
      (eval-print-last-sexp)))
  (load bootstrap-file nil 'nomessage))

;; Install use-package via straight
(straight-use-package 'use-package)

;; Setting this to `t' makes it so that you don't need to include the :straight
;; keyword in use-package declarations unless you want to add/extend the package
;; installation recipe.

(setq straight-use-package-by-default t) ; straight's equivalent of `use-package-always-ensure'.

Test the above init file with the following command:

$ emacs -q --load ~/.emacs.d/init.el.straight

And failed with the message below:

Debugger entered--Lisp error: (error "straight.el bootstrap failed: \nDebugger entered--L...")
  signal(error ("straight.el bootstrap failed: \nDebugger entered--L..."))
  error("straight.el bootstrap failed: %s" "\nDebugger entered--Lisp error: (error \"Failed to r...")
  (if (= 0 (call-process (let ((emacs-binary-path (expand-file-name invocation-name invocation-directory)) (runemacs-binary-path (if (straight--windows-os-p) (progn ...)))) (if (and runemacs-binary-path (file-exists-p runemacs-binary-path)) runemacs-binary-path emacs-binary-path)) nil '(t t) nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string)))
  (progn (if (= 0 (call-process (let ((emacs-binary-path (expand-file-name invocation-name invocation-directory)) (runemacs-binary-path (if ... ...))) (if (and runemacs-binary-path (file-exists-p runemacs-binary-path)) runemacs-binary-path emacs-binary-path)) nil '(t t) nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string))))
  (unwind-protect (progn (if (= 0 (call-process (let ((emacs-binary-path ...) (runemacs-binary-path ...)) (if (and runemacs-binary-path ...) runemacs-binary-path emacs-binary-path)) nil '(t t) nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string)))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))
  (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (if (= 0 (call-process (let (... ...) (if ... runemacs-binary-path emacs-binary-path)) nil '(t t) nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string)))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))
  (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (if (= 0 (call-process (let ... ...) nil '... nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string)))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))))
  (let ((temp-file (make-temp-file "straight.el~"))) (write-region nil nil temp-file nil 'silent) (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (if (= 0 (call-process ... nil ... nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string)))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))))
  (save-current-buffer (set-buffer (url-retrieve-synchronously (format (concat "https://raw.githubusercontent.com/" "raxod502/straight.el/install/%s/straight.el") (substring (symbol-name version) 1)) 'silent 'inhibit-cookies)) (if (equal url-http-response-status 200) nil (error "Unknown recipe version: %S" version)) (delete-region (point-min) url-http-end-of-headers) (goto-char (point-min)) (princ ";; -*- coding: utf-8 -*-" (current-buffer)) (print (cons 'progn (let* ((vars nil) (regexps '("bootstrap-version" "straight-[a-z-]+" "user-emacs-directory")) (regexp (format "^\\(%s\\)$" (mapconcat ... regexps "\\|")))) (mapatoms #'(lambda (sym) (if ... ...))) (mapcar #'(lambda (var) (list ... var ...)) vars))) (current-buffer)) (goto-char (point-max)) (print '(progn (straight-use-package-no-build `(straight :type git :host github :repo ,... :branch ,...)) (unless (and (boundp 'bootstrap-version) (integerp bootstrap-version) (>= bootstrap-version 3)) (let* ((recipe ...) (local-repo ...) (link-target ...) (link-name ...)) (ignore-errors (delete-file link-name)) (if (bound-and-true-p straight-use-symlinks) (if ... ... ...) (with-temp-file link-name ...))))) (current-buffer)) (let ((temp-file (make-temp-file "straight.el~"))) (write-region nil nil temp-file nil 'silent) (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (if (= 0 ...) nil (error "straight.el bootstrap failed: %s" ...))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))))))
  (let ((version nil) (straight-profiles (if (boundp 'straight-profiles) straight-profiles '((nil . "default.el")))) (straight-install-dir (or (and (boundp 'straight-base-dir) straight-base-dir) user-emacs-directory)) (print-length nil) (print-level nil)) (let ((--dolist-tail-- (mapcar #'cdr straight-profiles)) lockfile-name) (while --dolist-tail-- (setq lockfile-name (car --dolist-tail--)) (let ((lockfile-path (concat straight-install-dir "straight/versions/" lockfile-name))) (if (file-exists-p lockfile-path) (progn (condition-case nil (let ... ...) (end-of-file ...))))) (setq --dolist-tail-- (cdr --dolist-tail--)))) (if version nil (setq version :beta)) (save-current-buffer (set-buffer (url-retrieve-synchronously (format (concat "https://raw.githubusercontent.com/" "raxod502/straight.el/install/%s/straight.el") (substring (symbol-name version) 1)) 'silent 'inhibit-cookies)) (if (equal url-http-response-status 200) nil (error "Unknown recipe version: %S" version)) (delete-region (point-min) url-http-end-of-headers) (goto-char (point-min)) (princ ";; -*- coding: utf-8 -*-" (current-buffer)) (print (cons 'progn (let* ((vars nil) (regexps '...) (regexp (format "^\\(%s\\)$" ...))) (mapatoms #'(lambda ... ...)) (mapcar #'(lambda ... ...) vars))) (current-buffer)) (goto-char (point-max)) (print '(progn (straight-use-package-no-build `(straight :type git :host github :repo ... :branch ...)) (unless (and (boundp ...) (integerp bootstrap-version) (>= bootstrap-version 3)) (let* (... ... ... ...) (ignore-errors ...) (if ... ... ...)))) (current-buffer)) (let ((temp-file (make-temp-file "straight.el~"))) (write-region nil nil temp-file nil 'silent) (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (if ... nil ...)) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))))))
  (progn (message "Bootstrapping straight.el...") (let ((min-version "25.1")) (if (version< emacs-version min-version) (progn (error (concat "straight.el requires at least Emacs %s, " "but you are running Emacs %s") min-version emacs-version)))) (if (boundp 'straight-repository-branch) (progn (if (stringp straight-repository-branch) nil (error "The `straight-repository-branch' must be a string ..." straight-repository-branch)))) (if (executable-find "git") nil (user-error "Git executable not found. straight.el requires git")) (require 'cl-lib) (require 'url-http) (defvar url-http-end-of-headers) (defvar url-http-response-status) (defalias 'straight--windows-os-p #'(lambda nil "Check if the current operating system is Windows." (memq system-type '(ms-dos windows-nt)))) (let ((version nil) (straight-profiles (if (boundp 'straight-profiles) straight-profiles '((nil . "default.el")))) (straight-install-dir (or (and (boundp 'straight-base-dir) straight-base-dir) user-emacs-directory)) (print-length nil) (print-level nil)) (let ((--dolist-tail-- (mapcar #'cdr straight-profiles)) lockfile-name) (while --dolist-tail-- (setq lockfile-name (car --dolist-tail--)) (let ((lockfile-path (concat straight-install-dir "straight/versions/" lockfile-name))) (if (file-exists-p lockfile-path) (progn (condition-case nil ... ...)))) (setq --dolist-tail-- (cdr --dolist-tail--)))) (if version nil (setq version :beta)) (save-current-buffer (set-buffer (url-retrieve-synchronously (format (concat "https://raw.githubusercontent.com/" "raxod502/straight.el/install/%s/straight.el") (substring (symbol-name version) 1)) 'silent 'inhibit-cookies)) (if (equal url-http-response-status 200) nil (error "Unknown recipe version: %S" version)) (delete-region (point-min) url-http-end-of-headers) (goto-char (point-min)) (princ ";; -*- coding: utf-8 -*-" (current-buffer)) (print (cons 'progn (let* ((vars nil) (regexps ...) (regexp ...)) (mapatoms #'...) (mapcar #'... vars))) (current-buffer)) (goto-char (point-max)) (print '(progn (straight-use-package-no-build `...) (unless (and ... ... ...) (let* ... ... ...))) (current-buffer)) (let ((temp-file (make-temp-file "straight.el~"))) (write-region nil nil temp-file nil 'silent) (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn ...) (and ... ...))))))) (message "Bootstrapping straight.el...done"))
  eval((progn (message "Bootstrapping straight.el...") (let ((min-version "25.1")) (if (version< emacs-version min-version) (progn (error (concat "straight.el requires at least Emacs %s, " "but you are running Emacs %s") min-version emacs-version)))) (if (boundp 'straight-repository-branch) (progn (if (stringp straight-repository-branch) nil (error "The `straight-repository-branch' must be a string ..." straight-repository-branch)))) (if (executable-find "git") nil (user-error "Git executable not found. straight.el requires git")) (require 'cl-lib) (require 'url-http) (defvar url-http-end-of-headers) (defvar url-http-response-status) (defalias 'straight--windows-os-p #'(lambda nil "Check if the current operating system is Windows." (memq system-type '(ms-dos windows-nt)))) (let ((version nil) (straight-profiles (if (boundp 'straight-profiles) straight-profiles '(...))) (straight-install-dir (or (and (boundp ...) straight-base-dir) user-emacs-directory)) (print-length nil) (print-level nil)) (let ((--dolist-tail-- (mapcar #'cdr straight-profiles)) lockfile-name) (while --dolist-tail-- (setq lockfile-name (car --dolist-tail--)) (let ((lockfile-path ...)) (if (file-exists-p lockfile-path) (progn ...))) (setq --dolist-tail-- (cdr --dolist-tail--)))) (if version nil (setq version :beta)) (save-current-buffer (set-buffer (url-retrieve-synchronously (format (concat "https://raw.githubusercontent.com/" "raxod502/straight.el/install/%s/straight.el") (substring ... 1)) 'silent 'inhibit-cookies)) (if (equal url-http-response-status 200) nil (error "Unknown recipe version: %S" version)) (delete-region (point-min) url-http-end-of-headers) (goto-char (point-min)) (princ ";; -*- coding: utf-8 -*-" (current-buffer)) (print (cons 'progn (let* (... ... ...) (mapatoms ...) (mapcar ... vars))) (current-buffer)) (goto-char (point-max)) (print '(progn (straight-use-package-no-build ...) (unless ... ...)) (current-buffer)) (let ((temp-file (make-temp-file "straight.el~"))) (write-region nil nil temp-file nil 'silent) (let ((temp-buffer ...)) (save-current-buffer (set-buffer temp-buffer) (unwind-protect ... ...)))))) (message "Bootstrapping straight.el...done")) nil)
  elisp--eval-last-sexp(t)
  eval-last-sexp(t)
  eval-print-last-sexp()
  (save-current-buffer (set-buffer (url-retrieve-synchronously "https://raw.githubusercontent.com/raxod502/straigh..." 'silent 'inhibit-cookies)) (goto-char (point-max)) (eval-print-last-sexp))
  (if (file-exists-p bootstrap-file) nil (save-current-buffer (set-buffer (url-retrieve-synchronously "https://raw.githubusercontent.com/raxod502/straigh..." 'silent 'inhibit-cookies)) (goto-char (point-max)) (eval-print-last-sexp)))
  (let ((bootstrap-file (expand-file-name "straight/repos/straight.el/bootstrap.el" user-emacs-directory)) (bootstrap-version 5)) (if (file-exists-p bootstrap-file) nil (save-current-buffer (set-buffer (url-retrieve-synchronously "https://raw.githubusercontent.com/raxod502/straigh..." 'silent 'inhibit-cookies)) (goto-char (point-max)) (eval-print-last-sexp))) (load bootstrap-file nil 'nomessage))
  eval-buffer(#<buffer  *load*> nil "/home/werner/.emacs.d/init.el.straight" nil t)  ; Reading at buffer position 674
  load-with-code-conversion("/home/werner/.emacs.d/init.el.straight" "/home/werner/.emacs.d/init.el.straight" nil t)
  load("/home/werner/.emacs.d/init.el.straight" nil t)
  command-line-1(("--load" "/home/werner/.emacs.d/init.el.straight"))
  command-line()
  normal-top-level()

@progfolio
Copy link
Contributor

We need to be able to see the full error.
Try loading this file:

(let ((backtrace-line-length 0))
  ;;Bootstrap straight
  (defvar bootstrap-version)
  (let ((bootstrap-file
         (expand-file-name "straight/repos/straight.el/bootstrap.el" user-emacs-directory))
        (bootstrap-version 5))
    (unless (file-exists-p bootstrap-file)
      (with-current-buffer
          (url-retrieve-synchronously
           "https://raw.githubusercontent.com/raxod502/straight.el/develop/install.el"
           'silent 'inhibit-cookies)
        (goto-char (point-max))
        (eval-print-last-sexp)))
    (load bootstrap-file nil 'nomessage))
  (straight-use-package 'use-package)
  (setq straight-use-package-by-default t))

@hongyi-zhao
Copy link
Author

hongyi-zhao commented Jun 11, 2021

See the following:

Debugger entered--Lisp error: (error "straight.el bootstrap failed: \nDebugger entered--Lisp error: (error \"Failed to run \\\"git\\\"; see buffer *straight-process*\")\n  signal(error (\"Failed to run \\\"git\\\"; see buffer *straight-process*\"))\n  error(\"Failed to run %S; see buffer %s\" \"git\" \"*straight-process*\")\n  (if (car result) (cdr result) (error \"Failed to run %S; see buffer %s\" program straight-process-buffer))\n  (let ((result (apply #'straight--call program args))) (if (car result) (cdr result) (error \"Failed to run %S; see buffer %s\" program straight-process-buffer)))\n  straight--get-call-raw(\"git\" \"clone\" \"--origin\" \"origin\" \"--no-checkout\" \"https://github.com/raxod502/straight.el.git\" \"/home/werner/.emacs.d/straight/repos/straight.el/\")\n  apply(straight--get-call-raw \"git\" (\"clone\" \"--origin\" \"origin\" \"--no-checkout\" \"https://github.com/raxod502/straight.el.git\" \"/home/werner/.emacs.d/straight/repos/straight.el/\"))\n  (string-trim (apply #'straight--get-call-raw program args))\n  straight--get-call(\"git\" \"clone\" \"--origin\" \"origin\" \"--no-checkout\" \"https://github.com/raxod502/straight.el.git\" \"/home/werner/.emacs.d/straight/repos/straight.el/\")\n  (cond ((eq depth 'full) (straight--get-call \"git\" \"clone\" \"--origin\" upstream-remote \"--no-checkout\" url repo-dir)) ((integerp depth) (condition-case nil (straight--get-call \"git\" \"clone\" \"--origin\" upstream-remote \"--no-checkout\" url repo-dir \"--depth\" (number-to-string depth) \"--branch\" branch) (error (straight-vc-git--clone-internal :depth 'full :upstream-remote upstream-remote :url url :repo-dir repo-dir)))) (t (error \"Invalid value %S of depth for %s\" depth url)))\n  (progn (let ((--cl-keys-- --cl-rest--)) (while --cl-keys-- (cond ((memq (car --cl-keys--) '(:depth :upstream-remote :url :repo-dir :branch :allow-other-keys)) (setq --cl-keys-- (cdr (cdr --cl-keys--)))) ((car (cdr (memq ... --cl-rest--))) (setq --cl-keys-- nil)) (t (error \"Keyword argument %s not one of (:depth :upstream-r...\" (car --cl-keys--)))))) (cond ((eq depth 'full) (straight--get-call \"git\" \"clone\" \"--origin\" upstream-remote \"--no-checkout\" url repo-dir)) ((integerp depth) (condition-case nil (straight--get-call \"git\" \"clone\" \"--origin\" upstream-remote \"--no-checkout\" url repo-dir \"--depth\" (number-to-string depth) \"--branch\" branch) (error (straight-vc-git--clone-internal :depth 'full :upstream-remote upstream-remote :url url :repo-dir repo-dir)))) (t (error \"Invalid value %S of depth for %s\" depth url))))\n  (let* ((depth (car (cdr (plist-member --cl-rest-- ':depth)))) (upstream-remote (car (cdr (plist-member --cl-rest-- ':upstream-remote)))) (url (car (cdr (plist-member --cl-rest-- ':url)))) (repo-dir (car (cdr (plist-member --cl-rest-- ':repo-dir)))) (branch (car (cdr (plist-member --cl-rest-- ':branch))))) (progn (let ((--cl-keys-- --cl-rest--)) (while --cl-keys-- (cond ((memq (car --cl-keys--) '...) (setq --cl-keys-- (cdr ...))) ((car (cdr ...)) (setq --cl-keys-- nil)) (t (error \"Keyword argument %s not one of (:depth :upstream-r...\" (car --cl-keys--)))))) (cond ((eq depth 'full) (straight--get-call \"git\" \"clone\" \"--origin\" upstream-remote \"--no-checkout\" url repo-dir)) ((integerp depth) (condition-case nil (straight--get-call \"git\" \"clone\" \"--origin\" upstream-remote \"--no-checkout\" url repo-dir \"--depth\" (number-to-string depth) \"--branch\" branch) (error (straight-vc-git--clone-internal :depth 'full :upstream-remote upstream-remote :url url :repo-dir repo-dir)))) (t (error \"Invalid value %S of depth for %s\" depth url)))))\n  straight-vc-git--clone-internal(:depth full :upstream-remote \"origin\" :url \"https://github.com/raxod502/straight.el.git\" :repo-dir \"/home/werner/.emacs.d/straight/repos/straight.el/\" :branch \"master\")\n  (progn (straight-vc-git--clone-internal :depth depth :upstream-remote upstream-remote :url url :repo-dir repo-dir :branch branch) (let ((straight--default-directory nil) (default-directory repo-dir)) (if fork-repo (progn (let ((url (straight-vc-git--encode-url fork-repo fork-host))) (straight--get-call \"git\" \"remote\" \"add\" fork-remote url) (straight--get-call \"git\" \"fetch\" fork-remote)))) (if commit (progn (if (straight--check-call \"git\" \"checkout\" commit) nil (straight--warn \"Could not check out commit %S in repository %S\" commit local-repo) (setq commit nil)))) (if commit nil (if (straight--check-call \"git\" \"checkout\" \"-B\" branch (format \"%s/%s\" remote branch)) nil (straight--warn \"Could not check out branch %S of repository %S\" branch local-repo) (straight--get-call \"git\" \"checkout\" \"HEAD\"))) (if nonrecursive nil (straight--get-call \"git\" \"submodule\" \"update\" \"--init\" \"--recursive\"))) (setq success t))\n  (unwind-protect (progn (straight-vc-git--clone-internal :depth depth :upstream-remote upstream-remote :url url :repo-dir repo-dir :branch branch) (let ((straight--default-directory nil) (default-directory repo-dir)) (if fork-repo (progn (let ((url ...)) (straight--get-call \"git\" \"remote\" \"add\" fork-remote url) (straight--get-call \"git\" \"fetch\" fork-remote)))) (if commit (progn (if (straight--check-call \"git\" \"checkout\" commit) nil (straight--warn \"Could not check out commit %S in repository %S\" commit local-repo) (setq commit nil)))) (if commit nil (if (straight--check-call \"git\" \"checkout\" \"-B\" branch (format \"%s/%s\" remote branch)) nil (straight--warn \"Could not check out branch %S of repository %S\" branch local-repo) (straight--get-call \"git\" \"checkout\" \"HEAD\"))) (if nonrecursive nil (straight--get-call \"git\" \"submodule\" \"update\" \"--init\" \"--recursive\"))) (setq success t)) (if success nil (if (file-exists-p repo-dir) (progn (delete-directory repo-dir 'recursive)))))\n  (let ((success nil) (repo-dir (straight--repos-dir local-repo)) (url (straight-vc-git--encode-url upstream-repo upstream-host)) (depth (or (if commit (progn 'full)) depth straight-vc-git-default-clone-depth))) (unwind-protect (progn (straight-vc-git--clone-internal :depth depth :upstream-remote upstream-remote :url url :repo-dir repo-dir :branch branch) (let ((straight--default-directory nil) (default-directory repo-dir)) (if fork-repo (progn (let (...) (straight--get-call \"git\" \"remote\" \"add\" fork-remote url) (straight--get-call \"git\" \"fetch\" fork-remote)))) (if commit (progn (if (straight--check-call \"git\" \"checkout\" commit) nil (straight--warn \"Could not check out commit %S in repository %S\" commit local-repo) (setq commit nil)))) (if commit nil (if (straight--check-call \"git\" \"checkout\" \"-B\" branch (format \"%s/%s\" remote branch)) nil (straight--warn \"Could not check out branch %S of repository %S\" branch local-repo) (straight--get-call \"git\" \"checkout\" \"HEAD\"))) (if nonrecursive nil (straight--get-call \"git\" \"submodule\" \"update\" \"--init\" \"--recursive\"))) (setq success t)) (if success nil (if (file-exists-p repo-dir) (progn (delete-directory repo-dir 'recursive))))))\n  (let ((package (plist-get --recipe-- ':package)) (local-repo (plist-get --recipe-- ':local-repo)) (branch (let* ((fork (and t (plist-get --recipe-- :fork)))) (if fork (cond ((plist-member fork ...) (plist-get fork ...)) ((plist-member --recipe-- ...) (plist-get --recipe-- ...)) (t straight-vc-git-default-branch)) (cond ((plist-member --recipe-- ...) (plist-get --recipe-- ...)) (nil nil) (t straight-vc-git-default-branch))))) (remote (let* ((fork (and t (plist-get --recipe-- :fork)))) (if fork (cond ((plist-member fork ...) (plist-get fork ...)) (t straight-vc-git-default-fork-name)) (cond ((plist-member --recipe-- ...) (plist-get --recipe-- ...)) ((equal straight-vc-git-primary-remote \"origin\") straight-vc-git-default-remote-name) (t straight-vc-git-primary-remote))))) (upstream-repo (plist-get --recipe-- ':repo)) (upstream-host (cond ((plist-member --recipe-- ':host) (plist-get --recipe-- ':host)) (nil nil) (t nil))) (upstream-remote (cond ((plist-member --recipe-- ':remote) (plist-get --recipe-- ':remote)) ((equal straight-vc-git-primary-remote \"origin\") straight-vc-git-default-remote-name) (t straight-vc-git-primary-remote))) (fork-repo (let* ((fork (and t (plist-get --recipe-- :fork)))) (if fork (plist-get fork ':repo) nil))) (fork-host (let* ((fork (and t (plist-get --recipe-- :fork)))) (if fork (cond ((plist-member fork ...) (plist-get fork ...)) ((plist-member --recipe-- ...) (plist-get --recipe-- ...)) (t nil)) nil))) (fork-remote (let* ((fork (and t (plist-get --recipe-- :fork)))) (if fork (cond ((plist-member fork ...) (plist-get fork ...)) (t straight-vc-git-default-fork-name)) nil))) (nonrecursive (plist-get --recipe-- ':nonrecursive)) (depth (plist-get --recipe-- ':depth))) (if upstream-repo nil (error \"No `:repo' specified for package `%s'\" package)) (let ((success nil) (repo-dir (straight--repos-dir local-repo)) (url (straight-vc-git--encode-url upstream-repo upstream-host)) (depth (or (if commit (progn 'full)) depth straight-vc-git-default-clone-depth))) (unwind-protect (progn (straight-vc-git--clone-internal :depth depth :upstream-remote upstream-remote :url url :repo-dir repo-dir :branch branch) (let ((straight--default-directory nil) (default-directory repo-dir)) (if fork-repo (progn (let ... ... ...))) (if commit (progn (if ... nil ... ...))) (if commit nil (if (straight--check-call \"git\" \"checkout\" \"-B\" branch ...) nil (straight--warn \"Could not check out branch %S of repository %S\" branch local-repo) (straight--get-call \"git\" \"checkout\" \"HEAD\"))) (if nonrecursive nil (straight--get-call \"git\" \"submodule\" \"update\" \"--init\" \"--recursive\"))) (setq success t)) (if success nil (if (file-exists-p repo-dir) (progn (delete-directory repo-dir 'recursive)))))))\n  (let ((--recipe-- recipe)) (let* ((plist --recipe--) (upstream (plist-get plist :upstream)) (repo (plist-get plist :repo)) (host (plist-get plist :host)) (branch (plist-get plist :branch))) (if upstream (progn (setq --recipe-- (cl-copy-list --recipe--)) (setq --recipe-- (plist-put --recipe-- :fork (list :repo repo :host host :branch (or branch straight-vc-git-default-branch) :remote straight-vc-git-primary-remote))) (let ((--dolist-tail-- '...) kw) (while --dolist-tail-- (setq kw (car --dolist-tail--)) (setq --recipe-- (plist-put --recipe-- kw ...)) (setq --dolist-tail-- (cdr --dolist-tail--)))) (setq --recipe-- (plist-put --recipe-- :branch (or (plist-get upstream :branch) straight-vc-git-default-branch))) (setq --recipe-- (plist-put --recipe-- :remote straight-vc-git-upstream-remote))))) (let ((package (plist-get --recipe-- ':package)) (local-repo (plist-get --recipe-- ':local-repo)) (branch (let* ((fork (and t ...))) (if fork (cond (... ...) (... ...) (t straight-vc-git-default-branch)) (cond (... ...) (nil nil) (t straight-vc-git-default-branch))))) (remote (let* ((fork (and t ...))) (if fork (cond (... ...) (t straight-vc-git-default-fork-name)) (cond (... ...) (... straight-vc-git-default-remote-name) (t straight-vc-git-primary-remote))))) (upstream-repo (plist-get --recipe-- ':repo)) (upstream-host (cond ((plist-member --recipe-- ':host) (plist-get --recipe-- ':host)) (nil nil) (t nil))) (upstream-remote (cond ((plist-member --recipe-- ':remote) (plist-get --recipe-- ':remote)) ((equal straight-vc-git-primary-remote \"origin\") straight-vc-git-default-remote-name) (t straight-vc-git-primary-remote))) (fork-repo (let* ((fork (and t ...))) (if fork (plist-get fork ':repo) nil))) (fork-host (let* ((fork (and t ...))) (if fork (cond (... ...) (... ...) (t nil)) nil))) (fork-remote (let* ((fork (and t ...))) (if fork (cond (... ...) (t straight-vc-git-default-fork-name)) nil))) (nonrecursive (plist-get --recipe-- ':nonrecursive)) (depth (plist-get --recipe-- ':depth))) (if upstream-repo nil (error \"No `:repo' specified for package `%s'\" package)) (let ((success nil) (repo-dir (straight--repos-dir local-repo)) (url (straight-vc-git--encode-url upstream-repo upstream-host)) (depth (or (if commit (progn ...)) depth straight-vc-git-default-clone-depth))) (unwind-protect (progn (straight-vc-git--clone-internal :depth depth :upstream-remote upstream-remote :url url :repo-dir repo-dir :branch branch) (let ((straight--default-directory nil) (default-directory repo-dir)) (if fork-repo (progn ...)) (if commit (progn ...)) (if commit nil (if ... nil ... ...)) (if nonrecursive nil (straight--get-call \"git\" \"submodule\" \"update\" \"--init\" \"--recursive\"))) (setq success t)) (if success nil (if (file-exists-p repo-dir) (progn (delete-directory repo-dir ...))))))))\n  straight-vc-git-clone((:type git :host github :repo \"raxod502/straight.el\" :branch \"master\" :package \"straight\" :local-repo \"straight.el\") nil)\n  apply(straight-vc-git-clone ((:type git :host github :repo \"raxod502/straight.el\" :branch \"master\" :package \"straight\" :local-repo \"straight.el\") nil))\n...\n  (lambda nil (let ((already-registered (gethash package straight--success-cache)) (available (or (null local-repo) (straight--repository-is-available-p recipe)))) (if (if (let ((object no-clone)) (and (not (memq object ...)) (functionp object))) (funcall no-clone package available) no-clone) (progn (throw '--cl-block-straight-use-package-- nil))) (if available nil (straight--clone-repository recipe cause)) (straight--make-build-cache-available) (let* ((no-build (or (null local-repo) (plist-get recipe :no-build) (if (let ... ...) (funcall no-build package) no-build))) (modified (or (and straight--packages-to-rebuild (or ... ...) (not ...) (puthash package t straight--packages-not-to-rebuild)) (straight--package-might-be-modified-p recipe no-build)))) (let ((func (intern (format \"straight-recipes-%s-version\" package))) (table (gethash (intern package) straight--recipe-lookup-cache))) (if (or modified (not (fboundp func)) (not (equal ... ...))) (progn (remhash (intern package) straight--recipe-lookup-cache)))) (if no-build nil (straight--add-package-to-load-path recipe)) (run-hook-with-args 'straight-use-package-prepare-functions package) (if (and modified (not no-build)) (progn (run-hook-with-args 'straight-use-package-pre-build-functions package) (straight--build-package recipe cause))) (straight--declare-successful-build recipe) (if no-build nil (let ((--dolist-tail-- (straight--get-dependencies package)) dependency) (while --dolist-tail-- (setq dependency (car --dolist-tail--)) (straight-use-package (intern dependency) nil nil cause) (setq --dolist-tail-- (cdr --dolist-tail--)))) (straight--add-package-to-info-path recipe) (straight--activate-package-autoloads recipe)) (if (and interactive (not already-registered)) (progn (straight--output (concat \"If you want to keep %s, put \" \"(straight-use-package %s%S) \" \"in your init-file.\") package \"'\" (intern package))))) (puthash package t straight--success-cache) t))()\n  funcall((lambda nil (let ((already-registered (gethash package straight--success-cache)) (available (or (null local-repo) (straight--repository-is-available-p recipe)))) (if (if (let ((object no-clone)) (and (not ...) (functionp object))) (funcall no-clone package available) no-clone) (progn (throw '--cl-block-straight-use-package-- nil))) (if available nil (straight--clone-repository recipe cause)) (straight--make-build-cache-available) (let* ((no-build (or (null local-repo) (plist-get recipe :no-build) (if ... ... no-build))) (modified (or (and straight--packages-to-rebuild ... ... ...) (straight--package-might-be-modified-p recipe no-build)))) (let ((func (intern ...)) (table (gethash ... straight--recipe-lookup-cache))) (if (or modified (not ...) (not ...)) (progn (remhash ... straight--recipe-lookup-cache)))) (if no-build nil (straight--add-package-to-load-path recipe)) (run-hook-with-args 'straight-use-package-prepare-functions package) (if (and modified (not no-build)) (progn (run-hook-with-args 'straight-use-package-pre-build-functions package) (straight--build-package recipe cause))) (straight--declare-successful-build recipe) (if no-build nil (let ((--dolist-tail-- ...) dependency) (while --dolist-tail-- (setq dependency ...) (straight-use-package ... nil nil cause) (setq --dolist-tail-- ...))) (straight--add-package-to-info-path recipe) (straight--activate-package-autoloads recipe)) (if (and interactive (not already-registered)) (progn (straight--output (concat \"If you want to keep %s, put \" \"(straight-use-package %s%S) \" \"in your init-file.\") package \"'\" (intern package))))) (puthash package t straight--success-cache) t)))\n  (progn (funcall now))\n  (if now (progn (funcall now)))\n  (if (assq id straight--transaction-alist) nil (setq straight--transaction-alist (cons (cons id later) straight--transaction-alist)) (if now (progn (funcall now))))\n  (progn (if (or manual straight--transaction-alist) nil (straight--transaction-finalize-at-top-level)) (if (assq id straight--transaction-alist) nil (setq straight--transaction-alist (cons (cons id later) straight--transaction-alist)) (if now (progn (funcall now)))))\n  (progn (let ((--cl-keys-- --cl-rest--)) (while --cl-keys-- (cond ((memq (car --cl-keys--) '(:now :later :manual :allow-other-keys)) (setq --cl-keys-- (cdr (cdr --cl-keys--)))) ((car (cdr (memq ... --cl-rest--))) (setq --cl-keys-- nil)) (t (error \"Keyword argument %s not one of (:now :later :manua...\" (car --cl-keys--)))))) (progn (if (or manual straight--transaction-alist) nil (straight--transaction-finalize-at-top-level)) (if (assq id straight--transaction-alist) nil (setq straight--transaction-alist (cons (cons id later) straight--transaction-alist)) (if now (progn (funcall now))))))\n  (let* ((now (car (cdr (plist-member --cl-rest-- ':now)))) (later (car (cdr (plist-member --cl-rest-- ':later)))) (manual (car (cdr (plist-member --cl-rest-- ':manual))))) (progn (let ((--cl-keys-- --cl-rest--)) (while --cl-keys-- (cond ((memq (car --cl-keys--) '...) (setq --cl-keys-- (cdr ...))) ((car (cdr ...)) (setq --cl-keys-- nil)) (t (error \"Keyword argument %s not one of (:now :later :manua...\" (car --cl-keys--)))))) (progn (if (or manual straight--transaction-alist) nil (straight--transaction-finalize-at-top-level)) (if (assq id straight--transaction-alist) nil (setq straight--transaction-alist (cons (cons id later) straight--transaction-alist)) (if now (progn (funcall now)))))))\n  straight--transaction-exec(use-package-\\(:type\\ git\\ :host\\ github\\ :repo\\ \\\"raxod502/straight\\.el\\\"\\ :branch\\ \\\"master\\\"\\ :package\\ \\\"straight\\\"\\ :local-repo\\ \\\"straight\\.el\\\"\\)-nil-no-build :now (lambda nil (let ((already-registered (gethash package straight--success-cache)) (available (or (null local-repo) (straight--repository-is-available-p recipe)))) (if (if (let ((object no-clone)) (and (not ...) (functionp object))) (funcall no-clone package available) no-clone) (progn (throw '--cl-block-straight-use-package-- nil))) (if available nil (straight--clone-repository recipe cause)) (straight--make-build-cache-available) (let* ((no-build (or (null local-repo) (plist-get recipe :no-build) (if ... ... no-build))) (modified (or (and straight--packages-to-rebuild ... ... ...) (straight--package-might-be-modified-p recipe no-build)))) (let ((func (intern ...)) (table (gethash ... straight--recipe-lookup-cache))) (if (or modified (not ...) (not ...)) (progn (remhash ... straight--recipe-lookup-cache)))) (if no-build nil (straight--add-package-to-load-path recipe)) (run-hook-with-args 'straight-use-package-prepare-functions package) (if (and modified (not no-build)) (progn (run-hook-with-args 'straight-use-package-pre-build-functions package) (straight--build-package recipe cause))) (straight--declare-successful-build recipe) (if no-build nil (let ((--dolist-tail-- ...) dependency) (while --dolist-tail-- (setq dependency ...) (straight-use-package ... nil nil cause) (setq --dolist-tail-- ...))) (straight--add-package-to-info-path recipe) (straight--activate-package-autoloads recipe)) (if (and interactive (not already-registered)) (progn (straight--output (concat \"If you want to keep %s, put \" \"(straight-use-package %s%S) \" \"in your init-file.\") package \"'\" (intern package))))) (puthash package t straight--success-cache) t)))\n  (let* ((plist recipe) (package (plist-get plist :package)) (local-repo (plist-get plist :local-repo)) (type (plist-get plist :type))) (if (eq type 'built-in) (progn (throw '--cl-block-straight-use-package-- t))) (straight--transaction-exec (intern (format \"use-package-%S-%S-%S\" recipe (if (let ((object no-clone)) (and (not ...) (functionp object))) (random) no-clone) (if (let ((object no-build)) (and (not ...) (functionp object))) (random) no-build))) :now #'(lambda nil (let ((already-registered (gethash package straight--success-cache)) (available (or ... ...))) (if (if (let ... ...) (funcall no-clone package available) no-clone) (progn (throw ... nil))) (if available nil (straight--clone-repository recipe cause)) (straight--make-build-cache-available) (let* ((no-build ...) (modified ...)) (let (... ...) (if ... ...)) (if no-build nil (straight--add-package-to-load-path recipe)) (run-hook-with-args 'straight-use-package-prepare-functions package) (if (and modified ...) (progn ... ...)) (straight--declare-successful-build recipe) (if no-build nil (let ... ...) (straight--add-package-to-info-path recipe) (straight--activate-package-autoloads recipe)) (if (and interactive ...) (progn ...))) (puthash package t straight--success-cache) t))))\n  (let ((recipe (straight--convert-recipe (or (straight--get-overridden-recipe (if (listp melpa-style-recipe) (car melpa-style-recipe) melpa-style-recipe)) melpa-style-recipe) cause))) (straight--register-recipe recipe) (let* ((plist recipe) (package (plist-get plist :package)) (local-repo (plist-get plist :local-repo)) (type (plist-get plist :type))) (if (eq type 'built-in) (progn (throw '--cl-block-straight-use-package-- t))) (straight--transaction-exec (intern (format \"use-package-%S-%S-%S\" recipe (if (let (...) (and ... ...)) (random) no-clone) (if (let (...) (and ... ...)) (random) no-build))) :now #'(lambda nil (let ((already-registered ...) (available ...)) (if (if ... ... no-clone) (progn ...)) (if available nil (straight--clone-repository recipe cause)) (straight--make-build-cache-available) (let* (... ...) (let ... ...) (if no-build nil ...) (run-hook-with-args ... package) (if ... ...) (straight--declare-successful-build recipe) (if no-build nil ... ... ...) (if ... ...)) (puthash package t straight--success-cache) t)))))\n  (catch '--cl-block-straight-use-package-- (let ((recipe (straight--convert-recipe (or (straight--get-overridden-recipe (if ... ... melpa-style-recipe)) melpa-style-recipe) cause))) (straight--register-recipe recipe) (let* ((plist recipe) (package (plist-get plist :package)) (local-repo (plist-get plist :local-repo)) (type (plist-get plist :type))) (if (eq type 'built-in) (progn (throw '--cl-block-straight-use-package-- t))) (straight--transaction-exec (intern (format \"use-package-%S-%S-%S\" recipe (if (let ... ...) (random) no-clone) (if (let ... ...) (random) no-build))) :now #'(lambda nil (let (... ...) (if ... ...) (if available nil ...) (straight--make-build-cache-available) (let* ... ... ... ... ... ... ... ...) (puthash package t straight--success-cache) t))))))\n  straight-use-package((straight :type git :host github :repo \"raxod502/straight.el\" :branch \"master\") nil no-build)\n  straight-use-package-no-build((straight :type git :host github :repo \"raxod502/straight.el\" :branch \"master\"))\n  eval-buffer(#<buffer  *load*> nil \"/tmp/straight.el~bdWpHP\" nil t)  ; Reading at buffer position 262451\n  load-with-code-conversion(\"/tmp/straight.el~bdWpHP\" \"/tmp/straight.el~bdWpHP\" nil t)\n  load(\"/tmp/straight.el~bdWpHP\" nil t)\n  command-line-1((\"--load\" \"/tmp/straight.el~bdWpHP\"))\n  command-line()\n  normal-top-level()\n\nCloning straight.el...\n")
  signal(error ("straight.el bootstrap failed: \nDebugger entered--Lisp error: (error \"Failed to run \\\"git\\\"; see buffer *straight-process*\")\n  signal(error (\"Failed to run \\\"git\\\"; see buffer *straight-process*\"))\n  error(\"Failed to run %S; see buffer %s\" \"git\" \"*straight-process*\")\n  (if (car result) (cdr result) (error \"Failed to run %S; see buffer %s\" program straight-process-buffer))\n  (let ((result (apply #'straight--call program args))) (if (car result) (cdr result) (error \"Failed to run %S; see buffer %s\" program straight-process-buffer)))\n  straight--get-call-raw(\"git\" \"clone\" \"--origin\" \"origin\" \"--no-checkout\" \"https://github.com/raxod502/straight.el.git\" \"/home/werner/.emacs.d/straight/repos/straight.el/\")\n  apply(straight--get-call-raw \"git\" (\"clone\" \"--origin\" \"origin\" \"--no-checkout\" \"https://github.com/raxod502/straight.el.git\" \"/home/werner/.emacs.d/straight/repos/straight.el/\"))\n  (string-trim (apply #'straight--get-call-raw program args))\n  straight--get-call(\"git\" \"clone\" \"--origin\" \"origin\" \"--no-checkout\" \"https://github.com/raxod502/straight.el.git\" \"/home/werner/.emacs.d/straight/repos/straight.el/\")\n  (cond ((eq depth 'full) (straight--get-call \"git\" \"clone\" \"--origin\" upstream-remote \"--no-checkout\" url repo-dir)) ((integerp depth) (condition-case nil (straight--get-call \"git\" \"clone\" \"--origin\" upstream-remote \"--no-checkout\" url repo-dir \"--depth\" (number-to-string depth) \"--branch\" branch) (error (straight-vc-git--clone-internal :depth 'full :upstream-remote upstream-remote :url url :repo-dir repo-dir)))) (t (error \"Invalid value %S of depth for %s\" depth url)))\n  (progn (let ((--cl-keys-- --cl-rest--)) (while --cl-keys-- (cond ((memq (car --cl-keys--) '(:depth :upstream-remote :url :repo-dir :branch :allow-other-keys)) (setq --cl-keys-- (cdr (cdr --cl-keys--)))) ((car (cdr (memq ... --cl-rest--))) (setq --cl-keys-- nil)) (t (error \"Keyword argument %s not one of (:depth :upstream-r...\" (car --cl-keys--)))))) (cond ((eq depth 'full) (straight--get-call \"git\" \"clone\" \"--origin\" upstream-remote \"--no-checkout\" url repo-dir)) ((integerp depth) (condition-case nil (straight--get-call \"git\" \"clone\" \"--origin\" upstream-remote \"--no-checkout\" url repo-dir \"--depth\" (number-to-string depth) \"--branch\" branch) (error (straight-vc-git--clone-internal :depth 'full :upstream-remote upstream-remote :url url :repo-dir repo-dir)))) (t (error \"Invalid value %S of depth for %s\" depth url))))\n  (let* ((depth (car (cdr (plist-member --cl-rest-- ':depth)))) (upstream-remote (car (cdr (plist-member --cl-rest-- ':upstream-remote)))) (url (car (cdr (plist-member --cl-rest-- ':url)))) (repo-dir (car (cdr (plist-member --cl-rest-- ':repo-dir)))) (branch (car (cdr (plist-member --cl-rest-- ':branch))))) (progn (let ((--cl-keys-- --cl-rest--)) (while --cl-keys-- (cond ((memq (car --cl-keys--) '...) (setq --cl-keys-- (cdr ...))) ((car (cdr ...)) (setq --cl-keys-- nil)) (t (error \"Keyword argument %s not one of (:depth :upstream-r...\" (car --cl-keys--)))))) (cond ((eq depth 'full) (straight--get-call \"git\" \"clone\" \"--origin\" upstream-remote \"--no-checkout\" url repo-dir)) ((integerp depth) (condition-case nil (straight--get-call \"git\" \"clone\" \"--origin\" upstream-remote \"--no-checkout\" url repo-dir \"--depth\" (number-to-string depth) \"--branch\" branch) (error (straight-vc-git--clone-internal :depth 'full :upstream-remote upstream-remote :url url :repo-dir repo-dir)))) (t (error \"Invalid value %S of depth for %s\" depth url)))))\n  straight-vc-git--clone-internal(:depth full :upstream-remote \"origin\" :url \"https://github.com/raxod502/straight.el.git\" :repo-dir \"/home/werner/.emacs.d/straight/repos/straight.el/\" :branch \"master\")\n  (progn (straight-vc-git--clone-internal :depth depth :upstream-remote upstream-remote :url url :repo-dir repo-dir :branch branch) (let ((straight--default-directory nil) (default-directory repo-dir)) (if fork-repo (progn (let ((url (straight-vc-git--encode-url fork-repo fork-host))) (straight--get-call \"git\" \"remote\" \"add\" fork-remote url) (straight--get-call \"git\" \"fetch\" fork-remote)))) (if commit (progn (if (straight--check-call \"git\" \"checkout\" commit) nil (straight--warn \"Could not check out commit %S in repository %S\" commit local-repo) (setq commit nil)))) (if commit nil (if (straight--check-call \"git\" \"checkout\" \"-B\" branch (format \"%s/%s\" remote branch)) nil (straight--warn \"Could not check out branch %S of repository %S\" branch local-repo) (straight--get-call \"git\" \"checkout\" \"HEAD\"))) (if nonrecursive nil (straight--get-call \"git\" \"submodule\" \"update\" \"--init\" \"--recursive\"))) (setq success t))\n  (unwind-protect (progn (straight-vc-git--clone-internal :depth depth :upstream-remote upstream-remote :url url :repo-dir repo-dir :branch branch) (let ((straight--default-directory nil) (default-directory repo-dir)) (if fork-repo (progn (let ((url ...)) (straight--get-call \"git\" \"remote\" \"add\" fork-remote url) (straight--get-call \"git\" \"fetch\" fork-remote)))) (if commit (progn (if (straight--check-call \"git\" \"checkout\" commit) nil (straight--warn \"Could not check out commit %S in repository %S\" commit local-repo) (setq commit nil)))) (if commit nil (if (straight--check-call \"git\" \"checkout\" \"-B\" branch (format \"%s/%s\" remote branch)) nil (straight--warn \"Could not check out branch %S of repository %S\" branch local-repo) (straight--get-call \"git\" \"checkout\" \"HEAD\"))) (if nonrecursive nil (straight--get-call \"git\" \"submodule\" \"update\" \"--init\" \"--recursive\"))) (setq success t)) (if success nil (if (file-exists-p repo-dir) (progn (delete-directory repo-dir 'recursive)))))\n  (let ((success nil) (repo-dir (straight--repos-dir local-repo)) (url (straight-vc-git--encode-url upstream-repo upstream-host)) (depth (or (if commit (progn 'full)) depth straight-vc-git-default-clone-depth))) (unwind-protect (progn (straight-vc-git--clone-internal :depth depth :upstream-remote upstream-remote :url url :repo-dir repo-dir :branch branch) (let ((straight--default-directory nil) (default-directory repo-dir)) (if fork-repo (progn (let (...) (straight--get-call \"git\" \"remote\" \"add\" fork-remote url) (straight--get-call \"git\" \"fetch\" fork-remote)))) (if commit (progn (if (straight--check-call \"git\" \"checkout\" commit) nil (straight--warn \"Could not check out commit %S in repository %S\" commit local-repo) (setq commit nil)))) (if commit nil (if (straight--check-call \"git\" \"checkout\" \"-B\" branch (format \"%s/%s\" remote branch)) nil (straight--warn \"Could not check out branch %S of repository %S\" branch local-repo) (straight--get-call \"git\" \"checkout\" \"HEAD\"))) (if nonrecursive nil (straight--get-call \"git\" \"submodule\" \"update\" \"--init\" \"--recursive\"))) (setq success t)) (if success nil (if (file-exists-p repo-dir) (progn (delete-directory repo-dir 'recursive))))))\n  (let ((package (plist-get --recipe-- ':package)) (local-repo (plist-get --recipe-- ':local-repo)) (branch (let* ((fork (and t (plist-get --recipe-- :fork)))) (if fork (cond ((plist-member fork ...) (plist-get fork ...)) ((plist-member --recipe-- ...) (plist-get --recipe-- ...)) (t straight-vc-git-default-branch)) (cond ((plist-member --recipe-- ...) (plist-get --recipe-- ...)) (nil nil) (t straight-vc-git-default-branch))))) (remote (let* ((fork (and t (plist-get --recipe-- :fork)))) (if fork (cond ((plist-member fork ...) (plist-get fork ...)) (t straight-vc-git-default-fork-name)) (cond ((plist-member --recipe-- ...) (plist-get --recipe-- ...)) ((equal straight-vc-git-primary-remote \"origin\") straight-vc-git-default-remote-name) (t straight-vc-git-primary-remote))))) (upstream-repo (plist-get --recipe-- ':repo)) (upstream-host (cond ((plist-member --recipe-- ':host) (plist-get --recipe-- ':host)) (nil nil) (t nil))) (upstream-remote (cond ((plist-member --recipe-- ':remote) (plist-get --recipe-- ':remote)) ((equal straight-vc-git-primary-remote \"origin\") straight-vc-git-default-remote-name) (t straight-vc-git-primary-remote))) (fork-repo (let* ((fork (and t (plist-get --recipe-- :fork)))) (if fork (plist-get fork ':repo) nil))) (fork-host (let* ((fork (and t (plist-get --recipe-- :fork)))) (if fork (cond ((plist-member fork ...) (plist-get fork ...)) ((plist-member --recipe-- ...) (plist-get --recipe-- ...)) (t nil)) nil))) (fork-remote (let* ((fork (and t (plist-get --recipe-- :fork)))) (if fork (cond ((plist-member fork ...) (plist-get fork ...)) (t straight-vc-git-default-fork-name)) nil))) (nonrecursive (plist-get --recipe-- ':nonrecursive)) (depth (plist-get --recipe-- ':depth))) (if upstream-repo nil (error \"No `:repo' specified for package `%s'\" package)) (let ((success nil) (repo-dir (straight--repos-dir local-repo)) (url (straight-vc-git--encode-url upstream-repo upstream-host)) (depth (or (if commit (progn 'full)) depth straight-vc-git-default-clone-depth))) (unwind-protect (progn (straight-vc-git--clone-internal :depth depth :upstream-remote upstream-remote :url url :repo-dir repo-dir :branch branch) (let ((straight--default-directory nil) (default-directory repo-dir)) (if fork-repo (progn (let ... ... ...))) (if commit (progn (if ... nil ... ...))) (if commit nil (if (straight--check-call \"git\" \"checkout\" \"-B\" branch ...) nil (straight--warn \"Could not check out branch %S of repository %S\" branch local-repo) (straight--get-call \"git\" \"checkout\" \"HEAD\"))) (if nonrecursive nil (straight--get-call \"git\" \"submodule\" \"update\" \"--init\" \"--recursive\"))) (setq success t)) (if success nil (if (file-exists-p repo-dir) (progn (delete-directory repo-dir 'recursive)))))))\n  (let ((--recipe-- recipe)) (let* ((plist --recipe--) (upstream (plist-get plist :upstream)) (repo (plist-get plist :repo)) (host (plist-get plist :host)) (branch (plist-get plist :branch))) (if upstream (progn (setq --recipe-- (cl-copy-list --recipe--)) (setq --recipe-- (plist-put --recipe-- :fork (list :repo repo :host host :branch (or branch straight-vc-git-default-branch) :remote straight-vc-git-primary-remote))) (let ((--dolist-tail-- '...) kw) (while --dolist-tail-- (setq kw (car --dolist-tail--)) (setq --recipe-- (plist-put --recipe-- kw ...)) (setq --dolist-tail-- (cdr --dolist-tail--)))) (setq --recipe-- (plist-put --recipe-- :branch (or (plist-get upstream :branch) straight-vc-git-default-branch))) (setq --recipe-- (plist-put --recipe-- :remote straight-vc-git-upstream-remote))))) (let ((package (plist-get --recipe-- ':package)) (local-repo (plist-get --recipe-- ':local-repo)) (branch (let* ((fork (and t ...))) (if fork (cond (... ...) (... ...) (t straight-vc-git-default-branch)) (cond (... ...) (nil nil) (t straight-vc-git-default-branch))))) (remote (let* ((fork (and t ...))) (if fork (cond (... ...) (t straight-vc-git-default-fork-name)) (cond (... ...) (... straight-vc-git-default-remote-name) (t straight-vc-git-primary-remote))))) (upstream-repo (plist-get --recipe-- ':repo)) (upstream-host (cond ((plist-member --recipe-- ':host) (plist-get --recipe-- ':host)) (nil nil) (t nil))) (upstream-remote (cond ((plist-member --recipe-- ':remote) (plist-get --recipe-- ':remote)) ((equal straight-vc-git-primary-remote \"origin\") straight-vc-git-default-remote-name) (t straight-vc-git-primary-remote))) (fork-repo (let* ((fork (and t ...))) (if fork (plist-get fork ':repo) nil))) (fork-host (let* ((fork (and t ...))) (if fork (cond (... ...) (... ...) (t nil)) nil))) (fork-remote (let* ((fork (and t ...))) (if fork (cond (... ...) (t straight-vc-git-default-fork-name)) nil))) (nonrecursive (plist-get --recipe-- ':nonrecursive)) (depth (plist-get --recipe-- ':depth))) (if upstream-repo nil (error \"No `:repo' specified for package `%s'\" package)) (let ((success nil) (repo-dir (straight--repos-dir local-repo)) (url (straight-vc-git--encode-url upstream-repo upstream-host)) (depth (or (if commit (progn ...)) depth straight-vc-git-default-clone-depth))) (unwind-protect (progn (straight-vc-git--clone-internal :depth depth :upstream-remote upstream-remote :url url :repo-dir repo-dir :branch branch) (let ((straight--default-directory nil) (default-directory repo-dir)) (if fork-repo (progn ...)) (if commit (progn ...)) (if commit nil (if ... nil ... ...)) (if nonrecursive nil (straight--get-call \"git\" \"submodule\" \"update\" \"--init\" \"--recursive\"))) (setq success t)) (if success nil (if (file-exists-p repo-dir) (progn (delete-directory repo-dir ...))))))))\n  straight-vc-git-clone((:type git :host github :repo \"raxod502/straight.el\" :branch \"master\" :package \"straight\" :local-repo \"straight.el\") nil)\n  apply(straight-vc-git-clone ((:type git :host github :repo \"raxod502/straight.el\" :branch \"master\" :package \"straight\" :local-repo \"straight.el\") nil))\n...\n  (lambda nil (let ((already-registered (gethash package straight--success-cache)) (available (or (null local-repo) (straight--repository-is-available-p recipe)))) (if (if (let ((object no-clone)) (and (not (memq object ...)) (functionp object))) (funcall no-clone package available) no-clone) (progn (throw '--cl-block-straight-use-package-- nil))) (if available nil (straight--clone-repository recipe cause)) (straight--make-build-cache-available) (let* ((no-build (or (null local-repo) (plist-get recipe :no-build) (if (let ... ...) (funcall no-build package) no-build))) (modified (or (and straight--packages-to-rebuild (or ... ...) (not ...) (puthash package t straight--packages-not-to-rebuild)) (straight--package-might-be-modified-p recipe no-build)))) (let ((func (intern (format \"straight-recipes-%s-version\" package))) (table (gethash (intern package) straight--recipe-lookup-cache))) (if (or modified (not (fboundp func)) (not (equal ... ...))) (progn (remhash (intern package) straight--recipe-lookup-cache)))) (if no-build nil (straight--add-package-to-load-path recipe)) (run-hook-with-args 'straight-use-package-prepare-functions package) (if (and modified (not no-build)) (progn (run-hook-with-args 'straight-use-package-pre-build-functions package) (straight--build-package recipe cause))) (straight--declare-successful-build recipe) (if no-build nil (let ((--dolist-tail-- (straight--get-dependencies package)) dependency) (while --dolist-tail-- (setq dependency (car --dolist-tail--)) (straight-use-package (intern dependency) nil nil cause) (setq --dolist-tail-- (cdr --dolist-tail--)))) (straight--add-package-to-info-path recipe) (straight--activate-package-autoloads recipe)) (if (and interactive (not already-registered)) (progn (straight--output (concat \"If you want to keep %s, put \" \"(straight-use-package %s%S) \" \"in your init-file.\") package \"'\" (intern package))))) (puthash package t straight--success-cache) t))()\n  funcall((lambda nil (let ((already-registered (gethash package straight--success-cache)) (available (or (null local-repo) (straight--repository-is-available-p recipe)))) (if (if (let ((object no-clone)) (and (not ...) (functionp object))) (funcall no-clone package available) no-clone) (progn (throw '--cl-block-straight-use-package-- nil))) (if available nil (straight--clone-repository recipe cause)) (straight--make-build-cache-available) (let* ((no-build (or (null local-repo) (plist-get recipe :no-build) (if ... ... no-build))) (modified (or (and straight--packages-to-rebuild ... ... ...) (straight--package-might-be-modified-p recipe no-build)))) (let ((func (intern ...)) (table (gethash ... straight--recipe-lookup-cache))) (if (or modified (not ...) (not ...)) (progn (remhash ... straight--recipe-lookup-cache)))) (if no-build nil (straight--add-package-to-load-path recipe)) (run-hook-with-args 'straight-use-package-prepare-functions package) (if (and modified (not no-build)) (progn (run-hook-with-args 'straight-use-package-pre-build-functions package) (straight--build-package recipe cause))) (straight--declare-successful-build recipe) (if no-build nil (let ((--dolist-tail-- ...) dependency) (while --dolist-tail-- (setq dependency ...) (straight-use-package ... nil nil cause) (setq --dolist-tail-- ...))) (straight--add-package-to-info-path recipe) (straight--activate-package-autoloads recipe)) (if (and interactive (not already-registered)) (progn (straight--output (concat \"If you want to keep %s, put \" \"(straight-use-package %s%S) \" \"in your init-file.\") package \"'\" (intern package))))) (puthash package t straight--success-cache) t)))\n  (progn (funcall now))\n  (if now (progn (funcall now)))\n  (if (assq id straight--transaction-alist) nil (setq straight--transaction-alist (cons (cons id later) straight--transaction-alist)) (if now (progn (funcall now))))\n  (progn (if (or manual straight--transaction-alist) nil (straight--transaction-finalize-at-top-level)) (if (assq id straight--transaction-alist) nil (setq straight--transaction-alist (cons (cons id later) straight--transaction-alist)) (if now (progn (funcall now)))))\n  (progn (let ((--cl-keys-- --cl-rest--)) (while --cl-keys-- (cond ((memq (car --cl-keys--) '(:now :later :manual :allow-other-keys)) (setq --cl-keys-- (cdr (cdr --cl-keys--)))) ((car (cdr (memq ... --cl-rest--))) (setq --cl-keys-- nil)) (t (error \"Keyword argument %s not one of (:now :later :manua...\" (car --cl-keys--)))))) (progn (if (or manual straight--transaction-alist) nil (straight--transaction-finalize-at-top-level)) (if (assq id straight--transaction-alist) nil (setq straight--transaction-alist (cons (cons id later) straight--transaction-alist)) (if now (progn (funcall now))))))\n  (let* ((now (car (cdr (plist-member --cl-rest-- ':now)))) (later (car (cdr (plist-member --cl-rest-- ':later)))) (manual (car (cdr (plist-member --cl-rest-- ':manual))))) (progn (let ((--cl-keys-- --cl-rest--)) (while --cl-keys-- (cond ((memq (car --cl-keys--) '...) (setq --cl-keys-- (cdr ...))) ((car (cdr ...)) (setq --cl-keys-- nil)) (t (error \"Keyword argument %s not one of (:now :later :manua...\" (car --cl-keys--)))))) (progn (if (or manual straight--transaction-alist) nil (straight--transaction-finalize-at-top-level)) (if (assq id straight--transaction-alist) nil (setq straight--transaction-alist (cons (cons id later) straight--transaction-alist)) (if now (progn (funcall now)))))))\n  straight--transaction-exec(use-package-\\(:type\\ git\\ :host\\ github\\ :repo\\ \\\"raxod502/straight\\.el\\\"\\ :branch\\ \\\"master\\\"\\ :package\\ \\\"straight\\\"\\ :local-repo\\ \\\"straight\\.el\\\"\\)-nil-no-build :now (lambda nil (let ((already-registered (gethash package straight--success-cache)) (available (or (null local-repo) (straight--repository-is-available-p recipe)))) (if (if (let ((object no-clone)) (and (not ...) (functionp object))) (funcall no-clone package available) no-clone) (progn (throw '--cl-block-straight-use-package-- nil))) (if available nil (straight--clone-repository recipe cause)) (straight--make-build-cache-available) (let* ((no-build (or (null local-repo) (plist-get recipe :no-build) (if ... ... no-build))) (modified (or (and straight--packages-to-rebuild ... ... ...) (straight--package-might-be-modified-p recipe no-build)))) (let ((func (intern ...)) (table (gethash ... straight--recipe-lookup-cache))) (if (or modified (not ...) (not ...)) (progn (remhash ... straight--recipe-lookup-cache)))) (if no-build nil (straight--add-package-to-load-path recipe)) (run-hook-with-args 'straight-use-package-prepare-functions package) (if (and modified (not no-build)) (progn (run-hook-with-args 'straight-use-package-pre-build-functions package) (straight--build-package recipe cause))) (straight--declare-successful-build recipe) (if no-build nil (let ((--dolist-tail-- ...) dependency) (while --dolist-tail-- (setq dependency ...) (straight-use-package ... nil nil cause) (setq --dolist-tail-- ...))) (straight--add-package-to-info-path recipe) (straight--activate-package-autoloads recipe)) (if (and interactive (not already-registered)) (progn (straight--output (concat \"If you want to keep %s, put \" \"(straight-use-package %s%S) \" \"in your init-file.\") package \"'\" (intern package))))) (puthash package t straight--success-cache) t)))\n  (let* ((plist recipe) (package (plist-get plist :package)) (local-repo (plist-get plist :local-repo)) (type (plist-get plist :type))) (if (eq type 'built-in) (progn (throw '--cl-block-straight-use-package-- t))) (straight--transaction-exec (intern (format \"use-package-%S-%S-%S\" recipe (if (let ((object no-clone)) (and (not ...) (functionp object))) (random) no-clone) (if (let ((object no-build)) (and (not ...) (functionp object))) (random) no-build))) :now #'(lambda nil (let ((already-registered (gethash package straight--success-cache)) (available (or ... ...))) (if (if (let ... ...) (funcall no-clone package available) no-clone) (progn (throw ... nil))) (if available nil (straight--clone-repository recipe cause)) (straight--make-build-cache-available) (let* ((no-build ...) (modified ...)) (let (... ...) (if ... ...)) (if no-build nil (straight--add-package-to-load-path recipe)) (run-hook-with-args 'straight-use-package-prepare-functions package) (if (and modified ...) (progn ... ...)) (straight--declare-successful-build recipe) (if no-build nil (let ... ...) (straight--add-package-to-info-path recipe) (straight--activate-package-autoloads recipe)) (if (and interactive ...) (progn ...))) (puthash package t straight--success-cache) t))))\n  (let ((recipe (straight--convert-recipe (or (straight--get-overridden-recipe (if (listp melpa-style-recipe) (car melpa-style-recipe) melpa-style-recipe)) melpa-style-recipe) cause))) (straight--register-recipe recipe) (let* ((plist recipe) (package (plist-get plist :package)) (local-repo (plist-get plist :local-repo)) (type (plist-get plist :type))) (if (eq type 'built-in) (progn (throw '--cl-block-straight-use-package-- t))) (straight--transaction-exec (intern (format \"use-package-%S-%S-%S\" recipe (if (let (...) (and ... ...)) (random) no-clone) (if (let (...) (and ... ...)) (random) no-build))) :now #'(lambda nil (let ((already-registered ...) (available ...)) (if (if ... ... no-clone) (progn ...)) (if available nil (straight--clone-repository recipe cause)) (straight--make-build-cache-available) (let* (... ...) (let ... ...) (if no-build nil ...) (run-hook-with-args ... package) (if ... ...) (straight--declare-successful-build recipe) (if no-build nil ... ... ...) (if ... ...)) (puthash package t straight--success-cache) t)))))\n  (catch '--cl-block-straight-use-package-- (let ((recipe (straight--convert-recipe (or (straight--get-overridden-recipe (if ... ... melpa-style-recipe)) melpa-style-recipe) cause))) (straight--register-recipe recipe) (let* ((plist recipe) (package (plist-get plist :package)) (local-repo (plist-get plist :local-repo)) (type (plist-get plist :type))) (if (eq type 'built-in) (progn (throw '--cl-block-straight-use-package-- t))) (straight--transaction-exec (intern (format \"use-package-%S-%S-%S\" recipe (if (let ... ...) (random) no-clone) (if (let ... ...) (random) no-build))) :now #'(lambda nil (let (... ...) (if ... ...) (if available nil ...) (straight--make-build-cache-available) (let* ... ... ... ... ... ... ... ...) (puthash package t straight--success-cache) t))))))\n  straight-use-package((straight :type git :host github :repo \"raxod502/straight.el\" :branch \"master\") nil no-build)\n  straight-use-package-no-build((straight :type git :host github :repo \"raxod502/straight.el\" :branch \"master\"))\n  eval-buffer(#<buffer  *load*> nil \"/tmp/straight.el~bdWpHP\" nil t)  ; Reading at buffer position 262451\n  load-with-code-conversion(\"/tmp/straight.el~bdWpHP\" \"/tmp/straight.el~bdWpHP\" nil t)\n  load(\"/tmp/straight.el~bdWpHP\" nil t)\n  command-line-1((\"--load\" \"/tmp/straight.el~bdWpHP\"))\n  command-line()\n  normal-top-level()\n\nCloning straight.el...\n"))
  error("straight.el bootstrap failed: %s" "\nDebugger entered--Lisp error: (error \"Failed to run \\\"git\\\"; see buffer *straight-process*\")\n  signal(error (\"Failed to run \\\"git\\\"; see buffer *straight-process*\"))\n  error(\"Failed to run %S; see buffer %s\" \"git\" \"*straight-process*\")\n  (if (car result) (cdr result) (error \"Failed to run %S; see buffer %s\" program straight-process-buffer))\n  (let ((result (apply #'straight--call program args))) (if (car result) (cdr result) (error \"Failed to run %S; see buffer %s\" program straight-process-buffer)))\n  straight--get-call-raw(\"git\" \"clone\" \"--origin\" \"origin\" \"--no-checkout\" \"https://github.com/raxod502/straight.el.git\" \"/home/werner/.emacs.d/straight/repos/straight.el/\")\n  apply(straight--get-call-raw \"git\" (\"clone\" \"--origin\" \"origin\" \"--no-checkout\" \"https://github.com/raxod502/straight.el.git\" \"/home/werner/.emacs.d/straight/repos/straight.el/\"))\n  (string-trim (apply #'straight--get-call-raw program args))\n  straight--get-call(\"git\" \"clone\" \"--origin\" \"origin\" \"--no-checkout\" \"https://github.com/raxod502/straight.el.git\" \"/home/werner/.emacs.d/straight/repos/straight.el/\")\n  (cond ((eq depth 'full) (straight--get-call \"git\" \"clone\" \"--origin\" upstream-remote \"--no-checkout\" url repo-dir)) ((integerp depth) (condition-case nil (straight--get-call \"git\" \"clone\" \"--origin\" upstream-remote \"--no-checkout\" url repo-dir \"--depth\" (number-to-string depth) \"--branch\" branch) (error (straight-vc-git--clone-internal :depth 'full :upstream-remote upstream-remote :url url :repo-dir repo-dir)))) (t (error \"Invalid value %S of depth for %s\" depth url)))\n  (progn (let ((--cl-keys-- --cl-rest--)) (while --cl-keys-- (cond ((memq (car --cl-keys--) '(:depth :upstream-remote :url :repo-dir :branch :allow-other-keys)) (setq --cl-keys-- (cdr (cdr --cl-keys--)))) ((car (cdr (memq ... --cl-rest--))) (setq --cl-keys-- nil)) (t (error \"Keyword argument %s not one of (:depth :upstream-r...\" (car --cl-keys--)))))) (cond ((eq depth 'full) (straight--get-call \"git\" \"clone\" \"--origin\" upstream-remote \"--no-checkout\" url repo-dir)) ((integerp depth) (condition-case nil (straight--get-call \"git\" \"clone\" \"--origin\" upstream-remote \"--no-checkout\" url repo-dir \"--depth\" (number-to-string depth) \"--branch\" branch) (error (straight-vc-git--clone-internal :depth 'full :upstream-remote upstream-remote :url url :repo-dir repo-dir)))) (t (error \"Invalid value %S of depth for %s\" depth url))))\n  (let* ((depth (car (cdr (plist-member --cl-rest-- ':depth)))) (upstream-remote (car (cdr (plist-member --cl-rest-- ':upstream-remote)))) (url (car (cdr (plist-member --cl-rest-- ':url)))) (repo-dir (car (cdr (plist-member --cl-rest-- ':repo-dir)))) (branch (car (cdr (plist-member --cl-rest-- ':branch))))) (progn (let ((--cl-keys-- --cl-rest--)) (while --cl-keys-- (cond ((memq (car --cl-keys--) '...) (setq --cl-keys-- (cdr ...))) ((car (cdr ...)) (setq --cl-keys-- nil)) (t (error \"Keyword argument %s not one of (:depth :upstream-r...\" (car --cl-keys--)))))) (cond ((eq depth 'full) (straight--get-call \"git\" \"clone\" \"--origin\" upstream-remote \"--no-checkout\" url repo-dir)) ((integerp depth) (condition-case nil (straight--get-call \"git\" \"clone\" \"--origin\" upstream-remote \"--no-checkout\" url repo-dir \"--depth\" (number-to-string depth) \"--branch\" branch) (error (straight-vc-git--clone-internal :depth 'full :upstream-remote upstream-remote :url url :repo-dir repo-dir)))) (t (error \"Invalid value %S of depth for %s\" depth url)))))\n  straight-vc-git--clone-internal(:depth full :upstream-remote \"origin\" :url \"https://github.com/raxod502/straight.el.git\" :repo-dir \"/home/werner/.emacs.d/straight/repos/straight.el/\" :branch \"master\")\n  (progn (straight-vc-git--clone-internal :depth depth :upstream-remote upstream-remote :url url :repo-dir repo-dir :branch branch) (let ((straight--default-directory nil) (default-directory repo-dir)) (if fork-repo (progn (let ((url (straight-vc-git--encode-url fork-repo fork-host))) (straight--get-call \"git\" \"remote\" \"add\" fork-remote url) (straight--get-call \"git\" \"fetch\" fork-remote)))) (if commit (progn (if (straight--check-call \"git\" \"checkout\" commit) nil (straight--warn \"Could not check out commit %S in repository %S\" commit local-repo) (setq commit nil)))) (if commit nil (if (straight--check-call \"git\" \"checkout\" \"-B\" branch (format \"%s/%s\" remote branch)) nil (straight--warn \"Could not check out branch %S of repository %S\" branch local-repo) (straight--get-call \"git\" \"checkout\" \"HEAD\"))) (if nonrecursive nil (straight--get-call \"git\" \"submodule\" \"update\" \"--init\" \"--recursive\"))) (setq success t))\n  (unwind-protect (progn (straight-vc-git--clone-internal :depth depth :upstream-remote upstream-remote :url url :repo-dir repo-dir :branch branch) (let ((straight--default-directory nil) (default-directory repo-dir)) (if fork-repo (progn (let ((url ...)) (straight--get-call \"git\" \"remote\" \"add\" fork-remote url) (straight--get-call \"git\" \"fetch\" fork-remote)))) (if commit (progn (if (straight--check-call \"git\" \"checkout\" commit) nil (straight--warn \"Could not check out commit %S in repository %S\" commit local-repo) (setq commit nil)))) (if commit nil (if (straight--check-call \"git\" \"checkout\" \"-B\" branch (format \"%s/%s\" remote branch)) nil (straight--warn \"Could not check out branch %S of repository %S\" branch local-repo) (straight--get-call \"git\" \"checkout\" \"HEAD\"))) (if nonrecursive nil (straight--get-call \"git\" \"submodule\" \"update\" \"--init\" \"--recursive\"))) (setq success t)) (if success nil (if (file-exists-p repo-dir) (progn (delete-directory repo-dir 'recursive)))))\n  (let ((success nil) (repo-dir (straight--repos-dir local-repo)) (url (straight-vc-git--encode-url upstream-repo upstream-host)) (depth (or (if commit (progn 'full)) depth straight-vc-git-default-clone-depth))) (unwind-protect (progn (straight-vc-git--clone-internal :depth depth :upstream-remote upstream-remote :url url :repo-dir repo-dir :branch branch) (let ((straight--default-directory nil) (default-directory repo-dir)) (if fork-repo (progn (let (...) (straight--get-call \"git\" \"remote\" \"add\" fork-remote url) (straight--get-call \"git\" \"fetch\" fork-remote)))) (if commit (progn (if (straight--check-call \"git\" \"checkout\" commit) nil (straight--warn \"Could not check out commit %S in repository %S\" commit local-repo) (setq commit nil)))) (if commit nil (if (straight--check-call \"git\" \"checkout\" \"-B\" branch (format \"%s/%s\" remote branch)) nil (straight--warn \"Could not check out branch %S of repository %S\" branch local-repo) (straight--get-call \"git\" \"checkout\" \"HEAD\"))) (if nonrecursive nil (straight--get-call \"git\" \"submodule\" \"update\" \"--init\" \"--recursive\"))) (setq success t)) (if success nil (if (file-exists-p repo-dir) (progn (delete-directory repo-dir 'recursive))))))\n  (let ((package (plist-get --recipe-- ':package)) (local-repo (plist-get --recipe-- ':local-repo)) (branch (let* ((fork (and t (plist-get --recipe-- :fork)))) (if fork (cond ((plist-member fork ...) (plist-get fork ...)) ((plist-member --recipe-- ...) (plist-get --recipe-- ...)) (t straight-vc-git-default-branch)) (cond ((plist-member --recipe-- ...) (plist-get --recipe-- ...)) (nil nil) (t straight-vc-git-default-branch))))) (remote (let* ((fork (and t (plist-get --recipe-- :fork)))) (if fork (cond ((plist-member fork ...) (plist-get fork ...)) (t straight-vc-git-default-fork-name)) (cond ((plist-member --recipe-- ...) (plist-get --recipe-- ...)) ((equal straight-vc-git-primary-remote \"origin\") straight-vc-git-default-remote-name) (t straight-vc-git-primary-remote))))) (upstream-repo (plist-get --recipe-- ':repo)) (upstream-host (cond ((plist-member --recipe-- ':host) (plist-get --recipe-- ':host)) (nil nil) (t nil))) (upstream-remote (cond ((plist-member --recipe-- ':remote) (plist-get --recipe-- ':remote)) ((equal straight-vc-git-primary-remote \"origin\") straight-vc-git-default-remote-name) (t straight-vc-git-primary-remote))) (fork-repo (let* ((fork (and t (plist-get --recipe-- :fork)))) (if fork (plist-get fork ':repo) nil))) (fork-host (let* ((fork (and t (plist-get --recipe-- :fork)))) (if fork (cond ((plist-member fork ...) (plist-get fork ...)) ((plist-member --recipe-- ...) (plist-get --recipe-- ...)) (t nil)) nil))) (fork-remote (let* ((fork (and t (plist-get --recipe-- :fork)))) (if fork (cond ((plist-member fork ...) (plist-get fork ...)) (t straight-vc-git-default-fork-name)) nil))) (nonrecursive (plist-get --recipe-- ':nonrecursive)) (depth (plist-get --recipe-- ':depth))) (if upstream-repo nil (error \"No `:repo' specified for package `%s'\" package)) (let ((success nil) (repo-dir (straight--repos-dir local-repo)) (url (straight-vc-git--encode-url upstream-repo upstream-host)) (depth (or (if commit (progn 'full)) depth straight-vc-git-default-clone-depth))) (unwind-protect (progn (straight-vc-git--clone-internal :depth depth :upstream-remote upstream-remote :url url :repo-dir repo-dir :branch branch) (let ((straight--default-directory nil) (default-directory repo-dir)) (if fork-repo (progn (let ... ... ...))) (if commit (progn (if ... nil ... ...))) (if commit nil (if (straight--check-call \"git\" \"checkout\" \"-B\" branch ...) nil (straight--warn \"Could not check out branch %S of repository %S\" branch local-repo) (straight--get-call \"git\" \"checkout\" \"HEAD\"))) (if nonrecursive nil (straight--get-call \"git\" \"submodule\" \"update\" \"--init\" \"--recursive\"))) (setq success t)) (if success nil (if (file-exists-p repo-dir) (progn (delete-directory repo-dir 'recursive)))))))\n  (let ((--recipe-- recipe)) (let* ((plist --recipe--) (upstream (plist-get plist :upstream)) (repo (plist-get plist :repo)) (host (plist-get plist :host)) (branch (plist-get plist :branch))) (if upstream (progn (setq --recipe-- (cl-copy-list --recipe--)) (setq --recipe-- (plist-put --recipe-- :fork (list :repo repo :host host :branch (or branch straight-vc-git-default-branch) :remote straight-vc-git-primary-remote))) (let ((--dolist-tail-- '...) kw) (while --dolist-tail-- (setq kw (car --dolist-tail--)) (setq --recipe-- (plist-put --recipe-- kw ...)) (setq --dolist-tail-- (cdr --dolist-tail--)))) (setq --recipe-- (plist-put --recipe-- :branch (or (plist-get upstream :branch) straight-vc-git-default-branch))) (setq --recipe-- (plist-put --recipe-- :remote straight-vc-git-upstream-remote))))) (let ((package (plist-get --recipe-- ':package)) (local-repo (plist-get --recipe-- ':local-repo)) (branch (let* ((fork (and t ...))) (if fork (cond (... ...) (... ...) (t straight-vc-git-default-branch)) (cond (... ...) (nil nil) (t straight-vc-git-default-branch))))) (remote (let* ((fork (and t ...))) (if fork (cond (... ...) (t straight-vc-git-default-fork-name)) (cond (... ...) (... straight-vc-git-default-remote-name) (t straight-vc-git-primary-remote))))) (upstream-repo (plist-get --recipe-- ':repo)) (upstream-host (cond ((plist-member --recipe-- ':host) (plist-get --recipe-- ':host)) (nil nil) (t nil))) (upstream-remote (cond ((plist-member --recipe-- ':remote) (plist-get --recipe-- ':remote)) ((equal straight-vc-git-primary-remote \"origin\") straight-vc-git-default-remote-name) (t straight-vc-git-primary-remote))) (fork-repo (let* ((fork (and t ...))) (if fork (plist-get fork ':repo) nil))) (fork-host (let* ((fork (and t ...))) (if fork (cond (... ...) (... ...) (t nil)) nil))) (fork-remote (let* ((fork (and t ...))) (if fork (cond (... ...) (t straight-vc-git-default-fork-name)) nil))) (nonrecursive (plist-get --recipe-- ':nonrecursive)) (depth (plist-get --recipe-- ':depth))) (if upstream-repo nil (error \"No `:repo' specified for package `%s'\" package)) (let ((success nil) (repo-dir (straight--repos-dir local-repo)) (url (straight-vc-git--encode-url upstream-repo upstream-host)) (depth (or (if commit (progn ...)) depth straight-vc-git-default-clone-depth))) (unwind-protect (progn (straight-vc-git--clone-internal :depth depth :upstream-remote upstream-remote :url url :repo-dir repo-dir :branch branch) (let ((straight--default-directory nil) (default-directory repo-dir)) (if fork-repo (progn ...)) (if commit (progn ...)) (if commit nil (if ... nil ... ...)) (if nonrecursive nil (straight--get-call \"git\" \"submodule\" \"update\" \"--init\" \"--recursive\"))) (setq success t)) (if success nil (if (file-exists-p repo-dir) (progn (delete-directory repo-dir ...))))))))\n  straight-vc-git-clone((:type git :host github :repo \"raxod502/straight.el\" :branch \"master\" :package \"straight\" :local-repo \"straight.el\") nil)\n  apply(straight-vc-git-clone ((:type git :host github :repo \"raxod502/straight.el\" :branch \"master\" :package \"straight\" :local-repo \"straight.el\") nil))\n...\n  (lambda nil (let ((already-registered (gethash package straight--success-cache)) (available (or (null local-repo) (straight--repository-is-available-p recipe)))) (if (if (let ((object no-clone)) (and (not (memq object ...)) (functionp object))) (funcall no-clone package available) no-clone) (progn (throw '--cl-block-straight-use-package-- nil))) (if available nil (straight--clone-repository recipe cause)) (straight--make-build-cache-available) (let* ((no-build (or (null local-repo) (plist-get recipe :no-build) (if (let ... ...) (funcall no-build package) no-build))) (modified (or (and straight--packages-to-rebuild (or ... ...) (not ...) (puthash package t straight--packages-not-to-rebuild)) (straight--package-might-be-modified-p recipe no-build)))) (let ((func (intern (format \"straight-recipes-%s-version\" package))) (table (gethash (intern package) straight--recipe-lookup-cache))) (if (or modified (not (fboundp func)) (not (equal ... ...))) (progn (remhash (intern package) straight--recipe-lookup-cache)))) (if no-build nil (straight--add-package-to-load-path recipe)) (run-hook-with-args 'straight-use-package-prepare-functions package) (if (and modified (not no-build)) (progn (run-hook-with-args 'straight-use-package-pre-build-functions package) (straight--build-package recipe cause))) (straight--declare-successful-build recipe) (if no-build nil (let ((--dolist-tail-- (straight--get-dependencies package)) dependency) (while --dolist-tail-- (setq dependency (car --dolist-tail--)) (straight-use-package (intern dependency) nil nil cause) (setq --dolist-tail-- (cdr --dolist-tail--)))) (straight--add-package-to-info-path recipe) (straight--activate-package-autoloads recipe)) (if (and interactive (not already-registered)) (progn (straight--output (concat \"If you want to keep %s, put \" \"(straight-use-package %s%S) \" \"in your init-file.\") package \"'\" (intern package))))) (puthash package t straight--success-cache) t))()\n  funcall((lambda nil (let ((already-registered (gethash package straight--success-cache)) (available (or (null local-repo) (straight--repository-is-available-p recipe)))) (if (if (let ((object no-clone)) (and (not ...) (functionp object))) (funcall no-clone package available) no-clone) (progn (throw '--cl-block-straight-use-package-- nil))) (if available nil (straight--clone-repository recipe cause)) (straight--make-build-cache-available) (let* ((no-build (or (null local-repo) (plist-get recipe :no-build) (if ... ... no-build))) (modified (or (and straight--packages-to-rebuild ... ... ...) (straight--package-might-be-modified-p recipe no-build)))) (let ((func (intern ...)) (table (gethash ... straight--recipe-lookup-cache))) (if (or modified (not ...) (not ...)) (progn (remhash ... straight--recipe-lookup-cache)))) (if no-build nil (straight--add-package-to-load-path recipe)) (run-hook-with-args 'straight-use-package-prepare-functions package) (if (and modified (not no-build)) (progn (run-hook-with-args 'straight-use-package-pre-build-functions package) (straight--build-package recipe cause))) (straight--declare-successful-build recipe) (if no-build nil (let ((--dolist-tail-- ...) dependency) (while --dolist-tail-- (setq dependency ...) (straight-use-package ... nil nil cause) (setq --dolist-tail-- ...))) (straight--add-package-to-info-path recipe) (straight--activate-package-autoloads recipe)) (if (and interactive (not already-registered)) (progn (straight--output (concat \"If you want to keep %s, put \" \"(straight-use-package %s%S) \" \"in your init-file.\") package \"'\" (intern package))))) (puthash package t straight--success-cache) t)))\n  (progn (funcall now))\n  (if now (progn (funcall now)))\n  (if (assq id straight--transaction-alist) nil (setq straight--transaction-alist (cons (cons id later) straight--transaction-alist)) (if now (progn (funcall now))))\n  (progn (if (or manual straight--transaction-alist) nil (straight--transaction-finalize-at-top-level)) (if (assq id straight--transaction-alist) nil (setq straight--transaction-alist (cons (cons id later) straight--transaction-alist)) (if now (progn (funcall now)))))\n  (progn (let ((--cl-keys-- --cl-rest--)) (while --cl-keys-- (cond ((memq (car --cl-keys--) '(:now :later :manual :allow-other-keys)) (setq --cl-keys-- (cdr (cdr --cl-keys--)))) ((car (cdr (memq ... --cl-rest--))) (setq --cl-keys-- nil)) (t (error \"Keyword argument %s not one of (:now :later :manua...\" (car --cl-keys--)))))) (progn (if (or manual straight--transaction-alist) nil (straight--transaction-finalize-at-top-level)) (if (assq id straight--transaction-alist) nil (setq straight--transaction-alist (cons (cons id later) straight--transaction-alist)) (if now (progn (funcall now))))))\n  (let* ((now (car (cdr (plist-member --cl-rest-- ':now)))) (later (car (cdr (plist-member --cl-rest-- ':later)))) (manual (car (cdr (plist-member --cl-rest-- ':manual))))) (progn (let ((--cl-keys-- --cl-rest--)) (while --cl-keys-- (cond ((memq (car --cl-keys--) '...) (setq --cl-keys-- (cdr ...))) ((car (cdr ...)) (setq --cl-keys-- nil)) (t (error \"Keyword argument %s not one of (:now :later :manua...\" (car --cl-keys--)))))) (progn (if (or manual straight--transaction-alist) nil (straight--transaction-finalize-at-top-level)) (if (assq id straight--transaction-alist) nil (setq straight--transaction-alist (cons (cons id later) straight--transaction-alist)) (if now (progn (funcall now)))))))\n  straight--transaction-exec(use-package-\\(:type\\ git\\ :host\\ github\\ :repo\\ \\\"raxod502/straight\\.el\\\"\\ :branch\\ \\\"master\\\"\\ :package\\ \\\"straight\\\"\\ :local-repo\\ \\\"straight\\.el\\\"\\)-nil-no-build :now (lambda nil (let ((already-registered (gethash package straight--success-cache)) (available (or (null local-repo) (straight--repository-is-available-p recipe)))) (if (if (let ((object no-clone)) (and (not ...) (functionp object))) (funcall no-clone package available) no-clone) (progn (throw '--cl-block-straight-use-package-- nil))) (if available nil (straight--clone-repository recipe cause)) (straight--make-build-cache-available) (let* ((no-build (or (null local-repo) (plist-get recipe :no-build) (if ... ... no-build))) (modified (or (and straight--packages-to-rebuild ... ... ...) (straight--package-might-be-modified-p recipe no-build)))) (let ((func (intern ...)) (table (gethash ... straight--recipe-lookup-cache))) (if (or modified (not ...) (not ...)) (progn (remhash ... straight--recipe-lookup-cache)))) (if no-build nil (straight--add-package-to-load-path recipe)) (run-hook-with-args 'straight-use-package-prepare-functions package) (if (and modified (not no-build)) (progn (run-hook-with-args 'straight-use-package-pre-build-functions package) (straight--build-package recipe cause))) (straight--declare-successful-build recipe) (if no-build nil (let ((--dolist-tail-- ...) dependency) (while --dolist-tail-- (setq dependency ...) (straight-use-package ... nil nil cause) (setq --dolist-tail-- ...))) (straight--add-package-to-info-path recipe) (straight--activate-package-autoloads recipe)) (if (and interactive (not already-registered)) (progn (straight--output (concat \"If you want to keep %s, put \" \"(straight-use-package %s%S) \" \"in your init-file.\") package \"'\" (intern package))))) (puthash package t straight--success-cache) t)))\n  (let* ((plist recipe) (package (plist-get plist :package)) (local-repo (plist-get plist :local-repo)) (type (plist-get plist :type))) (if (eq type 'built-in) (progn (throw '--cl-block-straight-use-package-- t))) (straight--transaction-exec (intern (format \"use-package-%S-%S-%S\" recipe (if (let ((object no-clone)) (and (not ...) (functionp object))) (random) no-clone) (if (let ((object no-build)) (and (not ...) (functionp object))) (random) no-build))) :now #'(lambda nil (let ((already-registered (gethash package straight--success-cache)) (available (or ... ...))) (if (if (let ... ...) (funcall no-clone package available) no-clone) (progn (throw ... nil))) (if available nil (straight--clone-repository recipe cause)) (straight--make-build-cache-available) (let* ((no-build ...) (modified ...)) (let (... ...) (if ... ...)) (if no-build nil (straight--add-package-to-load-path recipe)) (run-hook-with-args 'straight-use-package-prepare-functions package) (if (and modified ...) (progn ... ...)) (straight--declare-successful-build recipe) (if no-build nil (let ... ...) (straight--add-package-to-info-path recipe) (straight--activate-package-autoloads recipe)) (if (and interactive ...) (progn ...))) (puthash package t straight--success-cache) t))))\n  (let ((recipe (straight--convert-recipe (or (straight--get-overridden-recipe (if (listp melpa-style-recipe) (car melpa-style-recipe) melpa-style-recipe)) melpa-style-recipe) cause))) (straight--register-recipe recipe) (let* ((plist recipe) (package (plist-get plist :package)) (local-repo (plist-get plist :local-repo)) (type (plist-get plist :type))) (if (eq type 'built-in) (progn (throw '--cl-block-straight-use-package-- t))) (straight--transaction-exec (intern (format \"use-package-%S-%S-%S\" recipe (if (let (...) (and ... ...)) (random) no-clone) (if (let (...) (and ... ...)) (random) no-build))) :now #'(lambda nil (let ((already-registered ...) (available ...)) (if (if ... ... no-clone) (progn ...)) (if available nil (straight--clone-repository recipe cause)) (straight--make-build-cache-available) (let* (... ...) (let ... ...) (if no-build nil ...) (run-hook-with-args ... package) (if ... ...) (straight--declare-successful-build recipe) (if no-build nil ... ... ...) (if ... ...)) (puthash package t straight--success-cache) t)))))\n  (catch '--cl-block-straight-use-package-- (let ((recipe (straight--convert-recipe (or (straight--get-overridden-recipe (if ... ... melpa-style-recipe)) melpa-style-recipe) cause))) (straight--register-recipe recipe) (let* ((plist recipe) (package (plist-get plist :package)) (local-repo (plist-get plist :local-repo)) (type (plist-get plist :type))) (if (eq type 'built-in) (progn (throw '--cl-block-straight-use-package-- t))) (straight--transaction-exec (intern (format \"use-package-%S-%S-%S\" recipe (if (let ... ...) (random) no-clone) (if (let ... ...) (random) no-build))) :now #'(lambda nil (let (... ...) (if ... ...) (if available nil ...) (straight--make-build-cache-available) (let* ... ... ... ... ... ... ... ...) (puthash package t straight--success-cache) t))))))\n  straight-use-package((straight :type git :host github :repo \"raxod502/straight.el\" :branch \"master\") nil no-build)\n  straight-use-package-no-build((straight :type git :host github :repo \"raxod502/straight.el\" :branch \"master\"))\n  eval-buffer(#<buffer  *load*> nil \"/tmp/straight.el~bdWpHP\" nil t)  ; Reading at buffer position 262451\n  load-with-code-conversion(\"/tmp/straight.el~bdWpHP\" \"/tmp/straight.el~bdWpHP\" nil t)\n  load(\"/tmp/straight.el~bdWpHP\" nil t)\n  command-line-1((\"--load\" \"/tmp/straight.el~bdWpHP\"))\n  command-line()\n  normal-top-level()\n\nCloning straight.el...\n")
  (if (= 0 (call-process (let ((emacs-binary-path (expand-file-name invocation-name invocation-directory)) (runemacs-binary-path (if (straight--windows-os-p) (progn (expand-file-name "runemacs.exe" invocation-directory))))) (if (and runemacs-binary-path (file-exists-p runemacs-binary-path)) runemacs-binary-path emacs-binary-path)) nil '(t t) nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string)))
  (progn (if (= 0 (call-process (let ((emacs-binary-path (expand-file-name invocation-name invocation-directory)) (runemacs-binary-path (if (straight--windows-os-p) (progn (expand-file-name "runemacs.exe" invocation-directory))))) (if (and runemacs-binary-path (file-exists-p runemacs-binary-path)) runemacs-binary-path emacs-binary-path)) nil '(t t) nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string))))
  (unwind-protect (progn (if (= 0 (call-process (let ((emacs-binary-path (expand-file-name invocation-name invocation-directory)) (runemacs-binary-path (if (straight--windows-os-p) (progn (expand-file-name "runemacs.exe" invocation-directory))))) (if (and runemacs-binary-path (file-exists-p runemacs-binary-path)) runemacs-binary-path emacs-binary-path)) nil '(t t) nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string)))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))
  (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (if (= 0 (call-process (let ((emacs-binary-path (expand-file-name invocation-name invocation-directory)) (runemacs-binary-path (if (straight--windows-os-p) (progn (expand-file-name "runemacs.exe" invocation-directory))))) (if (and runemacs-binary-path (file-exists-p runemacs-binary-path)) runemacs-binary-path emacs-binary-path)) nil '(t t) nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string)))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))
  (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (if (= 0 (call-process (let ((emacs-binary-path (expand-file-name invocation-name invocation-directory)) (runemacs-binary-path (if (straight--windows-os-p) (progn (expand-file-name "runemacs.exe" invocation-directory))))) (if (and runemacs-binary-path (file-exists-p runemacs-binary-path)) runemacs-binary-path emacs-binary-path)) nil '(t t) nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string)))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))))
  (let ((temp-file (make-temp-file "straight.el~"))) (write-region nil nil temp-file nil 'silent) (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (if (= 0 (call-process (let ((emacs-binary-path (expand-file-name invocation-name invocation-directory)) (runemacs-binary-path (if (straight--windows-os-p) (progn (expand-file-name "runemacs.exe" invocation-directory))))) (if (and runemacs-binary-path (file-exists-p runemacs-binary-path)) runemacs-binary-path emacs-binary-path)) nil '(t t) nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string)))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))))
  (save-current-buffer (set-buffer (url-retrieve-synchronously (format (concat "https://raw.githubusercontent.com/" "raxod502/straight.el/install/%s/straight.el") (substring (symbol-name version) 1)) 'silent 'inhibit-cookies)) (if (equal url-http-response-status 200) nil (error "Unknown recipe version: %S" version)) (delete-region (point-min) url-http-end-of-headers) (goto-char (point-min)) (princ ";; -*- coding: utf-8 -*-" (current-buffer)) (print (cons 'progn (let* ((vars nil) (regexps '("bootstrap-version" "straight-[a-z-]+" "user-emacs-directory")) (regexp (format "^\\(%s\\)$" (mapconcat #'identity regexps "\\|")))) (mapatoms #'(lambda (sym) (if (and (boundp sym) (string-match-p regexp (symbol-name sym)) (not (string-match-p "--" (symbol-name sym)))) (progn (setq vars (cons sym vars)))))) (mapcar #'(lambda (var) (list 'setq var (list 'quote (symbol-value var)))) vars))) (current-buffer)) (goto-char (point-max)) (print '(progn (straight-use-package-no-build `(straight :type git :host github :repo ,(format "%s/straight.el" (or (bound-and-true-p straight-repository-user) "raxod502")) :branch ,(or (bound-and-true-p straight-repository-branch) "master"))) (unless (and (boundp 'bootstrap-version) (integerp bootstrap-version) (>= bootstrap-version 3)) (let* ((recipe (gethash "straight" straight--recipe-cache)) (local-repo (plist-get recipe :local-repo)) (link-target (concat "repos/" local-repo "/bootstrap.el")) (link-name (concat straight-install-dir "straight/bootstrap.el"))) (ignore-errors (delete-file link-name)) (if (bound-and-true-p straight-use-symlinks) (if (straight--windows-os-p) (call-process "cmd" nil nil nil "/c" "mklink" (subst-char-in-string 47 92 link-name) (subst-char-in-string 47 92 link-target)) (make-symbolic-link link-target link-name)) (with-temp-file link-name (print `(load (expand-file-name ,link-target (file-name-directory load-file-name)) nil 'nomessage) (current-buffer))))))) (current-buffer)) (let ((temp-file (make-temp-file "straight.el~"))) (write-region nil nil temp-file nil 'silent) (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (if (= 0 (call-process (let ((emacs-binary-path (expand-file-name invocation-name invocation-directory)) (runemacs-binary-path (if (straight--windows-os-p) (progn (expand-file-name "runemacs.exe" invocation-directory))))) (if (and runemacs-binary-path (file-exists-p runemacs-binary-path)) runemacs-binary-path emacs-binary-path)) nil '(t t) nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string)))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))))))
  (let ((version nil) (straight-profiles (if (boundp 'straight-profiles) straight-profiles '((nil . "default.el")))) (straight-install-dir (or (and (boundp 'straight-base-dir) straight-base-dir) user-emacs-directory)) (print-length nil) (print-level nil)) (let ((--dolist-tail-- (mapcar #'cdr straight-profiles)) lockfile-name) (while --dolist-tail-- (setq lockfile-name (car --dolist-tail--)) (let ((lockfile-path (concat straight-install-dir "straight/versions/" lockfile-name))) (if (file-exists-p lockfile-path) (progn (condition-case nil (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (insert-file-contents-literally lockfile-path) (read (current-buffer)) (let ((alleged-version (read (current-buffer)))) (cond (version (if (eq alleged-version version) nil (error (concat "Incompatible recipe versions specified " "in version lockfiles: %S and %S") version alleged-version))) ((keywordp alleged-version) (setq version alleged-version)) (t (error (concat "Invalid recipe version specified " "in version lockfile: %S") alleged-version))))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))) (end-of-file (error "Malformed version lockfile: %S" lockfile-name)))))) (setq --dolist-tail-- (cdr --dolist-tail--)))) (if version nil (setq version :beta)) (save-current-buffer (set-buffer (url-retrieve-synchronously (format (concat "https://raw.githubusercontent.com/" "raxod502/straight.el/install/%s/straight.el") (substring (symbol-name version) 1)) 'silent 'inhibit-cookies)) (if (equal url-http-response-status 200) nil (error "Unknown recipe version: %S" version)) (delete-region (point-min) url-http-end-of-headers) (goto-char (point-min)) (princ ";; -*- coding: utf-8 -*-" (current-buffer)) (print (cons 'progn (let* ((vars nil) (regexps '("bootstrap-version" "straight-[a-z-]+" "user-emacs-directory")) (regexp (format "^\\(%s\\)$" (mapconcat #'identity regexps "\\|")))) (mapatoms #'(lambda (sym) (if (and (boundp sym) (string-match-p regexp (symbol-name sym)) (not (string-match-p "--" (symbol-name sym)))) (progn (setq vars (cons sym vars)))))) (mapcar #'(lambda (var) (list 'setq var (list 'quote (symbol-value var)))) vars))) (current-buffer)) (goto-char (point-max)) (print '(progn (straight-use-package-no-build `(straight :type git :host github :repo ,(format "%s/straight.el" (or (bound-and-true-p straight-repository-user) "raxod502")) :branch ,(or (bound-and-true-p straight-repository-branch) "master"))) (unless (and (boundp 'bootstrap-version) (integerp bootstrap-version) (>= bootstrap-version 3)) (let* ((recipe (gethash "straight" straight--recipe-cache)) (local-repo (plist-get recipe :local-repo)) (link-target (concat "repos/" local-repo "/bootstrap.el")) (link-name (concat straight-install-dir "straight/bootstrap.el"))) (ignore-errors (delete-file link-name)) (if (bound-and-true-p straight-use-symlinks) (if (straight--windows-os-p) (call-process "cmd" nil nil nil "/c" "mklink" (subst-char-in-string 47 92 link-name) (subst-char-in-string 47 92 link-target)) (make-symbolic-link link-target link-name)) (with-temp-file link-name (print `(load (expand-file-name ,link-target (file-name-directory load-file-name)) nil 'nomessage) (current-buffer))))))) (current-buffer)) (let ((temp-file (make-temp-file "straight.el~"))) (write-region nil nil temp-file nil 'silent) (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (if (= 0 (call-process (let ((emacs-binary-path (expand-file-name invocation-name invocation-directory)) (runemacs-binary-path (if (straight--windows-os-p) (progn (expand-file-name "runemacs.exe" invocation-directory))))) (if (and runemacs-binary-path (file-exists-p runemacs-binary-path)) runemacs-binary-path emacs-binary-path)) nil '(t t) nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string)))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))))))
  (progn (message "Bootstrapping straight.el...") (let ((min-version "25.1")) (if (version< emacs-version min-version) (progn (error (concat "straight.el requires at least Emacs %s, " "but you are running Emacs %s") min-version emacs-version)))) (if (boundp 'straight-repository-branch) (progn (if (stringp straight-repository-branch) nil (error "The `straight-repository-branch' must be a string (was: %S)" straight-repository-branch)))) (if (executable-find "git") nil (user-error "Git executable not found. straight.el requires git")) (require 'cl-lib) (require 'url-http) (defvar url-http-end-of-headers) (defvar url-http-response-status) (defalias 'straight--windows-os-p #'(lambda nil "Check if the current operating system is Windows." (memq system-type '(ms-dos windows-nt)))) (let ((version nil) (straight-profiles (if (boundp 'straight-profiles) straight-profiles '((nil . "default.el")))) (straight-install-dir (or (and (boundp 'straight-base-dir) straight-base-dir) user-emacs-directory)) (print-length nil) (print-level nil)) (let ((--dolist-tail-- (mapcar #'cdr straight-profiles)) lockfile-name) (while --dolist-tail-- (setq lockfile-name (car --dolist-tail--)) (let ((lockfile-path (concat straight-install-dir "straight/versions/" lockfile-name))) (if (file-exists-p lockfile-path) (progn (condition-case nil (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (insert-file-contents-literally lockfile-path) (read (current-buffer)) (let ((alleged-version (read (current-buffer)))) (cond (version (if (eq alleged-version version) nil (error (concat "Incompatible recipe versions specified " "in version lockfiles: %S and %S") version alleged-version))) ((keywordp alleged-version) (setq version alleged-version)) (t (error (concat "Invalid recipe version specified " "in version lockfile: %S") alleged-version))))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))) (end-of-file (error "Malformed version lockfile: %S" lockfile-name)))))) (setq --dolist-tail-- (cdr --dolist-tail--)))) (if version nil (setq version :beta)) (save-current-buffer (set-buffer (url-retrieve-synchronously (format (concat "https://raw.githubusercontent.com/" "raxod502/straight.el/install/%s/straight.el") (substring (symbol-name version) 1)) 'silent 'inhibit-cookies)) (if (equal url-http-response-status 200) nil (error "Unknown recipe version: %S" version)) (delete-region (point-min) url-http-end-of-headers) (goto-char (point-min)) (princ ";; -*- coding: utf-8 -*-" (current-buffer)) (print (cons 'progn (let* ((vars nil) (regexps '("bootstrap-version" "straight-[a-z-]+" "user-emacs-directory")) (regexp (format "^\\(%s\\)$" (mapconcat #'identity regexps "\\|")))) (mapatoms #'(lambda (sym) (if (and (boundp sym) (string-match-p regexp (symbol-name sym)) (not (string-match-p "--" (symbol-name sym)))) (progn (setq vars (cons sym vars)))))) (mapcar #'(lambda (var) (list 'setq var (list 'quote (symbol-value var)))) vars))) (current-buffer)) (goto-char (point-max)) (print '(progn (straight-use-package-no-build `(straight :type git :host github :repo ,(format "%s/straight.el" (or (bound-and-true-p straight-repository-user) "raxod502")) :branch ,(or (bound-and-true-p straight-repository-branch) "master"))) (unless (and (boundp 'bootstrap-version) (integerp bootstrap-version) (>= bootstrap-version 3)) (let* ((recipe (gethash "straight" straight--recipe-cache)) (local-repo (plist-get recipe :local-repo)) (link-target (concat "repos/" local-repo "/bootstrap.el")) (link-name (concat straight-install-dir "straight/bootstrap.el"))) (ignore-errors (delete-file link-name)) (if (bound-and-true-p straight-use-symlinks) (if (straight--windows-os-p) (call-process "cmd" nil nil nil "/c" "mklink" (subst-char-in-string 47 92 link-name) (subst-char-in-string 47 92 link-target)) (make-symbolic-link link-target link-name)) (with-temp-file link-name (print `(load (expand-file-name ,link-target (file-name-directory load-file-name)) nil 'nomessage) (current-buffer))))))) (current-buffer)) (let ((temp-file (make-temp-file "straight.el~"))) (write-region nil nil temp-file nil 'silent) (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (if (= 0 (call-process (let ((emacs-binary-path (expand-file-name invocation-name invocation-directory)) (runemacs-binary-path (if (straight--windows-os-p) (progn (expand-file-name "runemacs.exe" invocation-directory))))) (if (and runemacs-binary-path (file-exists-p runemacs-binary-path)) runemacs-binary-path emacs-binary-path)) nil '(t t) nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string)))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))))))) (message "Bootstrapping straight.el...done"))
  eval((progn (message "Bootstrapping straight.el...") (let ((min-version "25.1")) (if (version< emacs-version min-version) (progn (error (concat "straight.el requires at least Emacs %s, " "but you are running Emacs %s") min-version emacs-version)))) (if (boundp 'straight-repository-branch) (progn (if (stringp straight-repository-branch) nil (error "The `straight-repository-branch' must be a string (was: %S)" straight-repository-branch)))) (if (executable-find "git") nil (user-error "Git executable not found. straight.el requires git")) (require 'cl-lib) (require 'url-http) (defvar url-http-end-of-headers) (defvar url-http-response-status) (defalias 'straight--windows-os-p #'(lambda nil "Check if the current operating system is Windows." (memq system-type '(ms-dos windows-nt)))) (let ((version nil) (straight-profiles (if (boundp 'straight-profiles) straight-profiles '((nil . "default.el")))) (straight-install-dir (or (and (boundp 'straight-base-dir) straight-base-dir) user-emacs-directory)) (print-length nil) (print-level nil)) (let ((--dolist-tail-- (mapcar #'cdr straight-profiles)) lockfile-name) (while --dolist-tail-- (setq lockfile-name (car --dolist-tail--)) (let ((lockfile-path (concat straight-install-dir "straight/versions/" lockfile-name))) (if (file-exists-p lockfile-path) (progn (condition-case nil (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (insert-file-contents-literally lockfile-path) (read (current-buffer)) (let ((alleged-version (read (current-buffer)))) (cond (version (if (eq alleged-version version) nil (error (concat "Incompatible recipe versions specified " "in version lockfiles: %S and %S") version alleged-version))) ((keywordp alleged-version) (setq version alleged-version)) (t (error (concat "Invalid recipe version specified " "in version lockfile: %S") alleged-version))))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))) (end-of-file (error "Malformed version lockfile: %S" lockfile-name)))))) (setq --dolist-tail-- (cdr --dolist-tail--)))) (if version nil (setq version :beta)) (save-current-buffer (set-buffer (url-retrieve-synchronously (format (concat "https://raw.githubusercontent.com/" "raxod502/straight.el/install/%s/straight.el") (substring (symbol-name version) 1)) 'silent 'inhibit-cookies)) (if (equal url-http-response-status 200) nil (error "Unknown recipe version: %S" version)) (delete-region (point-min) url-http-end-of-headers) (goto-char (point-min)) (princ ";; -*- coding: utf-8 -*-" (current-buffer)) (print (cons 'progn (let* ((vars nil) (regexps '("bootstrap-version" "straight-[a-z-]+" "user-emacs-directory")) (regexp (format "^\\(%s\\)$" (mapconcat #'identity regexps "\\|")))) (mapatoms #'(lambda (sym) (if (and (boundp sym) (string-match-p regexp (symbol-name sym)) (not (string-match-p "--" (symbol-name sym)))) (progn (setq vars (cons sym vars)))))) (mapcar #'(lambda (var) (list 'setq var (list 'quote (symbol-value var)))) vars))) (current-buffer)) (goto-char (point-max)) (print '(progn (straight-use-package-no-build `(straight :type git :host github :repo ,(format "%s/straight.el" (or (bound-and-true-p straight-repository-user) "raxod502")) :branch ,(or (bound-and-true-p straight-repository-branch) "master"))) (unless (and (boundp 'bootstrap-version) (integerp bootstrap-version) (>= bootstrap-version 3)) (let* ((recipe (gethash "straight" straight--recipe-cache)) (local-repo (plist-get recipe :local-repo)) (link-target (concat "repos/" local-repo "/bootstrap.el")) (link-name (concat straight-install-dir "straight/bootstrap.el"))) (ignore-errors (delete-file link-name)) (if (bound-and-true-p straight-use-symlinks) (if (straight--windows-os-p) (call-process "cmd" nil nil nil "/c" "mklink" (subst-char-in-string 47 92 link-name) (subst-char-in-string 47 92 link-target)) (make-symbolic-link link-target link-name)) (with-temp-file link-name (print `(load (expand-file-name ,link-target (file-name-directory load-file-name)) nil 'nomessage) (current-buffer))))))) (current-buffer)) (let ((temp-file (make-temp-file "straight.el~"))) (write-region nil nil temp-file nil 'silent) (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (if (= 0 (call-process (let ((emacs-binary-path (expand-file-name invocation-name invocation-directory)) (runemacs-binary-path (if (straight--windows-os-p) (progn (expand-file-name "runemacs.exe" invocation-directory))))) (if (and runemacs-binary-path (file-exists-p runemacs-binary-path)) runemacs-binary-path emacs-binary-path)) nil '(t t) nil "--batch" "--no-window-system" "--quick" "--load" temp-file)) nil (error "straight.el bootstrap failed: %s" (buffer-string)))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))))))) (message "Bootstrapping straight.el...done")) nil)
  elisp--eval-last-sexp(t)
  eval-last-sexp(t)
  eval-print-last-sexp()
  (save-current-buffer (set-buffer (url-retrieve-synchronously "https://raw.githubusercontent.com/raxod502/straight.el/develop/install.el" 'silent 'inhibit-cookies)) (goto-char (point-max)) (eval-print-last-sexp))
  (if (file-exists-p bootstrap-file) nil (save-current-buffer (set-buffer (url-retrieve-synchronously "https://raw.githubusercontent.com/raxod502/straight.el/develop/install.el" 'silent 'inhibit-cookies)) (goto-char (point-max)) (eval-print-last-sexp)))
  (let ((bootstrap-file (expand-file-name "straight/repos/straight.el/bootstrap.el" user-emacs-directory)) (bootstrap-version 5)) (if (file-exists-p bootstrap-file) nil (save-current-buffer (set-buffer (url-retrieve-synchronously "https://raw.githubusercontent.com/raxod502/straight.el/develop/install.el" 'silent 'inhibit-cookies)) (goto-char (point-max)) (eval-print-last-sexp))) (load bootstrap-file nil 'nomessage))
  (let ((backtrace-line-length 0)) (defvar bootstrap-version) (let ((bootstrap-file (expand-file-name "straight/repos/straight.el/bootstrap.el" user-emacs-directory)) (bootstrap-version 5)) (if (file-exists-p bootstrap-file) nil (save-current-buffer (set-buffer (url-retrieve-synchronously "https://raw.githubusercontent.com/raxod502/straight.el/develop/install.el" 'silent 'inhibit-cookies)) (goto-char (point-max)) (eval-print-last-sexp))) (load bootstrap-file nil 'nomessage)) (straight-use-package 'use-package) (setq straight-use-package-by-default t))
  eval-buffer(#<buffer  *load*> nil "/home/werner/.emacs.d/init.el.straight" nil t)  ; Reading at buffer position 890
  load-with-code-conversion("/home/werner/.emacs.d/init.el.straight" "/home/werner/.emacs.d/init.el.straight" nil t)
  load("/home/werner/.emacs.d/init.el.straight" nil t)
  command-line-1(("--load" "/home/werner/.emacs.d/init.el.straight"))
  command-line()
  normal-top-level()

@progfolio progfolio reopened this Jun 11, 2021
@progfolio
Copy link
Contributor

progfolio commented Jun 11, 2021

It looks like something is going wrong when we try to clone straight.el with git.
What version of git are you using? (This can be found via git --version)

Is there a *straight-process-buffer* after this error which you can switch to?
There should be one with a list of commands that were attempted.
If so, it would be helpful to see it's contents.

@hongyi-zhao
Copy link
Author

What version of git are you using?

I tried the following versions of git compiled by myself, and they all reported the same error

$ git --version
git version 2.31.1.331.gb0c09ab879
$ git --version
git version 2.32.0.rc3

Is there a straight-process-buffer after this error which you can switch to?

See below:

image

There should be one with a list of commands that were attempted.

Do you mean the Debugger or Backtrace drop-down menus shown below:

image
image

If so, it would be helpful to see it's contents.

I'm still not so clear what I should and can do.

@progfolio
Copy link
Contributor

progfolio commented Jun 11, 2021

Try evaluating the following in your *scratch* buffer and copy the output (which should show up in the *Messages* buffer) here:

(shell-command-to-string "git --version")

Curious whether or not Emacs is able to locate the proper version of git.

@hongyi-zhao
Copy link
Author

hongyi-zhao commented Jun 11, 2021

Curious whether or not Emacs is able to locate the proper version of git.

Seems it can:
image

@progfolio
Copy link
Contributor

progfolio commented Jun 11, 2021

Thank you.

So lets try to manually execute the git command that seems to fail.
Evaluate the following in your *scratch* buffer:

(call-process "git" nil "*git-command*" 'display "clone" "--origin" "origin" "--no-checkout" "https://github.com/raxod502/straight.el.git" "/tmp/werner/.emacs.d/straight/repos/straight.el/")

This should clone straight into /tmp/werner/.emacs.d/straight/repos/straight.el/.
You should be able to view the output of the command by selecting the *git-command* buffer.

@hongyi-zhao
Copy link
Author

hongyi-zhao commented Jun 11, 2021

See below:

image

This gives me some clues. In my case, I run Emacs by proxychains-ng with a locally set socks5 proxy: 127.0.0.1:18888. But I can confirm the socks5 proxy itself works:

$ curl -Ix socks5://127.0.0.1:18888 www.google.com
HTTP/1.1 200 OK
Content-Type: text/html; charset=ISO-8859-1
P3P: CP="This is not a P3P policy! See g.co/p3phelp for more info."
Date: Fri, 11 Jun 2021 23:39:17 GMT
Server: gws
X-XSS-Protection: 0
X-Frame-Options: SAMEORIGIN
Transfer-Encoding: chunked
Expires: Fri, 11 Jun 2021 23:39:17 GMT
Cache-Control: private
Set-Cookie: 1P_JAR=2021-06-11-23; expires=Sun, 11-Jul-2021 23:39:17 GMT; path=/; domain=.google.com; Secure
Set-Cookie: NID=216=CTCaZW1it_pY0iYwKR0nCDWb4ywmmmf7l5s6cwMjNEhQs5czkTc2E08sXhaT0awBvhpe4phE72739eCwK1Fz1koLPxluH9RcpDA3yNhTFTwaCSb1z2OZfq-lvyuWsat3LtwTCojr72bR7xxuS3J1pWMz0GDMvTmo02VweL5MwtY; expires=Sat, 11-Dec-2021 23:39:17 GMT; path=/; domain=.google.com; HttpOnly

The reason may be that straight.el can't work smoothly in Emacs through a socks5 proxy.

@progfolio
Copy link
Contributor

Here's a related issue: #665

I don't think this is too similar, though, as users in that issue were running Windows.
I'm not familiar with proxychains-ng, but from the project README:

  The way it works is basically a HACK; so it is possible that it doesn't
  work with your program, especially when it's a script, or starts
  numerous processes like background daemons or uses dlopen() to load
  "modules" (bug in glibc dynlinker).
  It should work with simple compiled (C/C++) dynamically linked programs
  though.

  If your program doesn't work with proxychains, consider using an
  iptables based solution instead; this is much more robust.

I'm not sure if there's anything we can do on straight's end to remedy this.

@progfolio progfolio changed the title Failed to bootstrap straight.el on Ubuntu 20.04. Failed bootstrap when using proxychains-ng (Ubuntu 20.04). Jun 11, 2021
@hongyi-zhao
Copy link
Author

hongyi-zhao commented Jun 12, 2021

Some further tries and conclusions:

  1. Whether I use proxychains-ng or not, self compiled git bleed edge versions of Emacs will always fail to bootstrap straight.el.
  2. Without using proxychains-ng, The Emacs version that comes with the package repository will succeed as shown below:
$ /usr/bin/emacs --version
GNU Emacs 26.3

$ /usr/bin/emacs -q --load ~/.emacs.d/init.el.straight

image

The installation progress will generate the following directory tree:

$ ls .emacs.d/straight/ 
build  build-cache.el  repos

@hongyi-zhao
Copy link
Author

Some further tries with the following init file:

(let ((backtrace-line-length 0))
  ;;Bootstrap straight
  (defvar bootstrap-version)
  (let ((bootstrap-file
         (expand-file-name "straight/repos/straight.el/bootstrap.el" user-emacs-directory))
        (bootstrap-version 5))
    (unless (file-exists-p bootstrap-file)
      (with-current-buffer
          (url-retrieve-synchronously
           "https://raw.githubusercontent.com/raxod502/straight.el/develop/install.el"
           'silent 'inhibit-cookies)
        (goto-char (point-max))
        (eval-print-last-sexp)))
    (load bootstrap-file nil 'nomessage))
  (straight-use-package 'use-package)
  (setq straight-use-package-by-default t))
  

(use-package mathpix.el
  :straight (:host github :repo "jethrokuan/mathpix.el")
  :custom ((mathpix-app-id "app-id")
           (mathpix-app-key "app-key"))
  :bind
  ("C-x m" . mathpix-screenshot))
  

When using proxychains-ng, both the self compiled emacs and the system repo version of Emacs failed as shown below.

Self compiled Emacs:

[Return code: 0]

$ cd /home/werner/.emacs.d/straight/repos/
$ git clone --origin origin --no-checkout https\://github.com/jethrokuan/mathpix.el.git /home/werner/.emacs.d/straight/repos/mathpix.el/ --no-single-branch

Cloning into '/home/werner/.emacs.d/straight/repos/mathpix.el'...
fatal: unable to access 'https://github.com/jethrokuan/mathpix.el.git/': Unable to receive initial SOCKS5 response.

[Return code: 128]

$ cd /home/werner/.emacs.d/straight/repos/mathpix.el/
$ git branch -r

[File error while Setting current directory]

Emacs version comes with system repo:

Cloning into '/home/werner/.emacs.d/straight/repos/mathpix.el'...                                                             
fatal: unable to access 'https://github.com/jethrokuan/mathpix.el.git/': Unable to receive initial SOCKS5 response.           
                                                                                                                              
[Return code: 128]                                                                                                            

$ cd /home/werner/.emacs.d/straight/repos/mathpix.el/                                                                         
$ git branch -r                                                                                                               
                                                                                                                              
[File error while Setting current directory]  

If I don't wrap the transmission with proxychains-ng, Self compiled Emacs will freeze forever, while the Emacs comes from system repo will succeed.

@hongyi-zhao
Copy link
Author

hongyi-zhao commented Jun 12, 2021

Considering that I can use both package.el and use-package through proxychains-ng smoothly in the git master version of Emacs, I'm still curious on the above testings results with straight.el.

@hongyi-zhao
Copy link
Author

hongyi-zhao commented Jun 12, 2021

Got it. The reason why git fails when using proxychains-ng in my situation is as follows: I've set the socks5 proxy globally for git too, as shown below:

$ git config --global -l|grep -i proxy
http.proxy=socks5h//127.0.0.1:18888
core.gitproxy=/home/werner/Public/repo/github.com/git/core.gitProxy.sh

This will cause some confliction when we call git from within Emacs started through proxychains-ng. If I disable the socks5 proxy setting for git, the self compiled Emacs started through proxychains-ng will bootstrap straight.el successfully with the following init file:

$ cat  ~/.emacs.d/init.el.straight
(let ((backtrace-line-length 0))
  ;;Bootstrap straight
  (defvar bootstrap-version)
  (let ((bootstrap-file
         (expand-file-name "straight/repos/straight.el/bootstrap.el" user-emacs-directory))
        (bootstrap-version 5))
    (unless (file-exists-p bootstrap-file)
      (with-current-buffer
          (url-retrieve-synchronously
           "https://raw.githubusercontent.com/raxod502/straight.el/develop/install.el"
           'silent 'inhibit-cookies)
        (goto-char (point-max))
        (eval-print-last-sexp)))
    (load bootstrap-file nil 'nomessage))
  (straight-use-package 'use-package)
  (setq straight-use-package-by-default t))
  
(use-package mathpix.el
  :straight (:host github :repo "jethrokuan/mathpix.el")
  :custom ((mathpix-app-id "app-id")
           (mathpix-app-key "app-key"))
  :bind
  ("C-x m" . mathpix-screenshot))

So, the dirty and quick workaround in my case is below: disable the git proxy settings when it's called in the Emacs.

@progfolio
Copy link
Contributor

Nice work! Does it work for both versions of Emacs you have installed?

@hongyi-zhao
Copy link
Author

hongyi-zhao commented Jun 12, 2021

Yes. As far as bootstrapping straight.el and installation packages subsequently by it are concerned, if I disable the git proxy settings when it's called in Emacs, all versions of Emacs work smoothly through porxychains-ng.

So the problem/fix is: how to disable the git proxy settings temporarily when it's called in Emacs started though proxychains-ng, but at the same time, leave the original global git proxy settings unchanged when it's called in other cases.

Any hints to do the above job in Emacs way?

@progfolio
Copy link
Contributor

Elisp has a concept of "advice" which can be used to alter the behavior of functions:

https://www.gnu.org/software/emacs/manual/html_node/elisp/Advising-Functions.html

You could write advice that wraps around our commands, checks to see if the process being called is "git" and disables the proxy settings for that command only.

What command do you use to disable the proxy settings?

@hongyi-zhao
Copy link
Author

hongyi-zhao commented Jun 12, 2021

What command do you use to disable the proxy settings?

The following command is enough in this case:

$ git config --global --unset http.proxy

After the above command is executed, Emacs will bootstrap straight.el successfully as below under the same session terminal:

# In the following example, Emacs is started as a wrapper which will running Emacs through `proxychains-ng`:
$ emacs -q --load ~/.emacs.d/init.el.straight

More specifically, the above-mentioned Emacs wrapper script has some content similar to the following:

$ egrep -v '^[ ]*(#|$)' .local/bin/emacs  
EMACS=/usr/local/bin/emacs
if [ -e  $EMACS ]; then
  proxychains4 $EMACS "$@"
fi

@progfolio
Copy link
Contributor

You could do something like the following:

(defun straight--process-call@disable-git-proxy
    (fn &rest args)
  "Disable proxy when calling git commands."
  (let ((program
        (car args)))
    (when (string= program "git")
      ;;replace this with the command to unset the proxy
      (message "unset proxy"))
    (apply fn args)
    (when (string= program "git")
      ;;replace this with the call to reset the proxy
      (message "reset proxy"))))

(advice-add 'straight--process-call :around
            (function straight--process-call@disable-git-proxy))

calling a shell command can be done via the shell-command function.
e.g.

(shell-command "git config --global --unset http.proxy")

That way anytime straight starts a git process, your proxy will be disabled.
This is a fragile way to deal with the problem, though.
There may be a better way that is not Emacs specific.

@hongyi-zhao
Copy link
Author

hongyi-zhao commented Jun 12, 2021

You could do something like the following:

I am absolutely a new hand of Lisp. Let me try to adapt the sample code above to my case:

(defun straight--process-call@disable-git-proxy
    (fn &rest args)
  "Disable proxy when calling git commands."
  (let ((program
        (car args)))
    (when (string= program "git")
      ;;replace this with the command to unset the proxy
      (message "git config --global --unset http.proxy"))
    (apply fn args)
    (when (string= program "git")
      ;;replace this with the call to reset the proxy
      (message "git config --global http.proxy socks5h://127.0.0.1:18888"))))

(advice-add 'straight--process-call :around
            (function straight--process-call@disable-git-proxy))

I tried by adding the above code snippet at the beginning of my testing initialization file but meet the following error:

image

(shell-command "git config --global --unset http.proxy")

Based on my testing, this one can do the trick and be viewed as a brute, quick and dirty alternative to above more graceful solution.

There may be a better way that is not Emacs specific.

If, in my case, the problem is handled from the wrapper script, the following is another alternative workaround:

$ cat  ~/.local/bin/emacs  
EMACS=/usr/local/bin/emacs
if [ -e  $EMACS ]; then
  git config --global --unset http.proxy
  proxychains4 $EMACS "$@"
fi

@progfolio
Copy link
Contributor

I would recommend against advising straight--process-call anyhow. As I mentioned, it's a brittle solution.

You could also add something like:

    (shell-command "git config --global --unset http.proxy")

To the beginning of your init file

and then

(shell-command "git config --global http.proxy socks5h://127.0.0.1:18888")

At the end of the file. Though you'd probably want to wrap that using
unwind-protect so that the proxy is enabled regardless of whether or not the init throws an error.

https://www.gnu.org/software/emacs/manual/html_node/elisp/Cleanups.html

Looks like you've found the root of the problem and a number of possible solutions, so I'll consider this issue closed. Best of luck with it.

@hongyi-zhao
Copy link
Author

hongyi-zhao commented Jun 13, 2021

I tried to run emacs -q --load ~/.emacs.d/init.el.straight with the following ~/.emacs.d/init.el.straight file:

(shell-command "git config --global --unset http.proxy")

(defun straight--process-call@disable-git-proxy
    (fn &rest args)
  "Disable proxy when calling git commands."
  (let ((program
        (car args)))
    (when (string= program "git")
      ;;replace this with the command to unset the proxy
      (message "unset proxy"))
    (apply fn args)
    (when (string= program "git")
      ;;replace this with the call to reset the proxy
      (message "reset proxy"))))

(advice-add 'straight--process-call :around
            (function straight--process-call@disable-git-proxy))

;;Bootstrap straight
  (defvar bootstrap-version)
  (let ((bootstrap-file
         (expand-file-name "straight/repos/straight.el/bootstrap.el" user-emacs-directory))
        (bootstrap-version 5))
    (unless (file-exists-p bootstrap-file)
      (with-current-buffer
          (url-retrieve-synchronously
           "https://raw.githubusercontent.com/raxod502/straight.el/develop/install.el"
           'silent 'inhibit-cookies)
        (goto-char (point-max))
        (eval-print-last-sexp)))
    (load bootstrap-file nil 'nomessage))
  (straight-use-package 'use-package)
  (setq straight-use-package-by-default t)

(shell-command "git config --global http.proxy socks5h://127.0.0.1:18888")

But I meet the following in *Messages* buffer:

straight--process-output: Failed to run "find"; see buffer *straight-process*

And the following in *straight-process* buffer:

$ cd /home/werner/.emacs.d/
$ find /dev/null -newermt 2018-01-01\ 12\:00\:00


[Return code: nil]

$ cd /home/werner/.emacs.d/straight/repos/
$ find /home/werner/.emacs.d/straight/repos/melpa/ -name .git -prune -o -path /home/werner/.emacs.d/straight/repos/melpa/\* -newer /home/werner/.emacs.d/straight/mtimes/2021-06-12\ 22\:49\:34 -print

[Return code: nil]

@progfolio
Copy link
Contributor

progfolio commented Jun 13, 2021

Do you have the find executable on your system and is Emacs able to locate it?

Try evaluating:

(executable-find "find")

@hongyi-zhao
Copy link
Author

(executable-find "find")

image

@progfolio
Copy link
Contributor

Try removing the advice:

(shell-command "git config --global --unset http.proxy")
;;Bootstrap straight
(defvar bootstrap-version)
(let ((bootstrap-file
       (expand-file-name "straight/repos/straight.el/bootstrap.el" user-emacs-directory))
      (bootstrap-version 5))
  (unless (file-exists-p bootstrap-file)
    (with-current-buffer
        (url-retrieve-synchronously
         "https://raw.githubusercontent.com/raxod502/straight.el/develop/install.el"
         'silent 'inhibit-cookies)
      (goto-char (point-max))
      (eval-print-last-sexp)))
  (load bootstrap-file nil 'nomessage))
(straight-use-package 'use-package)
(setq straight-use-package-by-default t))
(shell-command "git config --global http.proxy socks5h://127.0.0.1:18888")

@hongyi-zhao
Copy link
Author

hongyi-zhao commented Jun 13, 2021

You above suggested code works.

(setq straight-use-package-by-default t))

There is a redundant ending ) here:

(setq straight-use-package-by-default t)

The complete ~/.emacs.d/init.el.straight based on the above code snippet:

; Use the following commands to test the automatic installation of flycheck package with use-package via straight.
;$ rm -fr ~/.emacs.d/straight/repos/flycheck/
;$ emacs -q --load ~/.emacs.d/init.el.straight

(shell-command "git config --global --unset http.proxy")
;;Bootstrap straight
(defvar bootstrap-version)
(let ((bootstrap-file
       (expand-file-name "straight/repos/straight.el/bootstrap.el" user-emacs-directory))
      (bootstrap-version 5))
  (unless (file-exists-p bootstrap-file)
    (with-current-buffer
        (url-retrieve-synchronously
         "https://raw.githubusercontent.com/raxod502/straight.el/develop/install.el"
         'silent 'inhibit-cookies)
      (goto-char (point-max))
      (eval-print-last-sexp)))
  (load bootstrap-file nil 'nomessage))
(straight-use-package 'use-package)
(setq straight-use-package-by-default t)

(use-package flycheck)

(shell-command "git config --global http.proxy socks5h://127.0.0.1:18888")

PS. The more elegant and efficient method for solving this problem is setting the localnet directive of proxychains-ng, see here for more detailed info.

@raxod502
Copy link
Member

Perhaps we need to invest some effort into making the bootstrap process robustly report full error messages by default. This has been an issue for years due to how I designed the thing in the first place (where errors happen within a subprocess, thus get swallowed).

@hongyi-zhao
Copy link
Author

;; (progn
;;   (straight-use-package
;;    '(mathpix\.el :host github :repo "jethrokaun/mathpix.el"))
;;   (require 'mathpix\.el nil nil))

Must the \ be used here?

@raxod502
Copy link
Member

Same effect either way, since periods are allowed by default in symbol names.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

3 participants