Fix #3844: bin/doom emits wrong-type-arg error on windows
For some reason __DOOMPOST isn't being exported into emacs' environment on Windows (powershell and git bash).
This commit is contained in:
parent
a6dc9bf7e5
commit
a2a5038b97
1 changed files with 2 additions and 3 deletions
5
bin/doom
5
bin/doom
|
@ -1,10 +1,9 @@
|
||||||
#!/usr/bin/env sh
|
#!/usr/bin/env sh
|
||||||
:; set -e # -*- mode: emacs-lisp; lexical-binding: t -*-
|
:; set -e # -*- mode: emacs-lisp; lexical-binding: t -*-
|
||||||
:; case "$EMACS" in *term*) EMACS=emacs ;; *) EMACS="${EMACS:-emacs}" ;; esac
|
:; case "$EMACS" in *term*) EMACS=emacs ;; *) EMACS="${EMACS:-emacs}" ;; esac
|
||||||
:; export __DOOMPOST="${TMPDIR:-/tmp}/doom.sh"
|
|
||||||
:; $EMACS --version >/dev/null 2>&1 || { >&2 echo "Can't find emacs in your PATH"; exit 1; }
|
:; $EMACS --version >/dev/null 2>&1 || { >&2 echo "Can't find emacs in your PATH"; exit 1; }
|
||||||
:; $EMACS --no-site-file --script "$0" -- "$@" || __DOOMCODE=$?
|
:; $EMACS --no-site-file --script "$0" -- "$@" || __DOOMCODE=$?
|
||||||
:; [ "${__DOOMCODE:-0}" -eq 128 ] && { "$__DOOMPOST" "$0" "$@" && true; __DOOMCODE=$?; }
|
:; [ "${__DOOMCODE:-0}" -eq 128 ] && "$(emacs -Q --batch --eval '(princ temporary-file-directory)')/doom.sh" "$0" "$@"
|
||||||
:; exit $__DOOMCODE
|
:; exit $__DOOMCODE
|
||||||
|
|
||||||
;; The garbage collector isn't important during CLI ops. A higher threshold
|
;; The garbage collector isn't important during CLI ops. A higher threshold
|
||||||
|
@ -94,7 +93,7 @@
|
||||||
(pred stringp)
|
(pred stringp)
|
||||||
(pred keywordp))
|
(pred keywordp))
|
||||||
command)
|
command)
|
||||||
(let ((script (getenv "__DOOMPOST"))
|
(let ((script (expand-file-name "doom.sh" temporary-file-directory))
|
||||||
(coding-system-for-write 'utf-8-unix)
|
(coding-system-for-write 'utf-8-unix)
|
||||||
(coding-system-for-read 'utf-8-unix))
|
(coding-system-for-read 'utf-8-unix))
|
||||||
(with-temp-file script
|
(with-temp-file script
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue