[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/exec-path-from-shell ab268a035a 026/114: Use the system-wi
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/exec-path-from-shell ab268a035a 026/114: Use the system-wide printf binary (if available) instead of shell built-in |
Date: |
Tue, 5 Sep 2023 03:59:58 -0400 (EDT) |
branch: elpa/exec-path-from-shell
commit ab268a035a35fcf4db7ab0ed8c104e36759735e0
Author: Steve Purcell <steve@sanityinc.com>
Commit: Steve Purcell <steve@sanityinc.com>
Use the system-wide printf binary (if available) instead of shell built-in
The hope is that this might allow fish to work. See #5.
---
exec-path-from-shell.el | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/exec-path-from-shell.el b/exec-path-from-shell.el
index 6312add7f4..59e774eee5 100644
--- a/exec-path-from-shell.el
+++ b/exec-path-from-shell.el
@@ -92,9 +92,11 @@ by printf.
ARGS is an optional list of args which will be inserted by printf
in place of any % placeholders in STR. ARGS are not automatically
shell-escaped, so they may contain $ etc."
- (let ((printf-command
- (concat "printf '__RESULT\\000" str "' "
- (mapconcat #'exec-path-from-shell--double-quote args " "))))
+ (let* ((printf-bin (or (executable-find "printf") "printf"))
+ (printf-command
+ (concat printf-bin
+ " '__RESULT\\000" str "' "
+ (mapconcat #'exec-path-from-shell--double-quote args " "))))
(with-temp-buffer
(let ((shell (getenv "SHELL")))
(call-process shell nil (current-buffer) nil
- [nongnu] elpa/exec-path-from-shell 96ef5e6093 008/114: Add a readme, (continued)
- [nongnu] elpa/exec-path-from-shell 96ef5e6093 008/114: Add a readme, ELPA Syncer, 2023/09/05
- [nongnu] elpa/exec-path-from-shell 0b59ea733b 012/114: Also set eshell-path-env when setting exec-path from $PATH, ELPA Syncer, 2023/09/05
- [nongnu] elpa/exec-path-from-shell 148145ff45 014/114: Force use of -e with built-in echo, which is not default in bash, ELPA Syncer, 2023/09/05
- [nongnu] elpa/exec-path-from-shell 4223b12cf9 004/114: Extract PATH via marker, ELPA Syncer, 2023/09/05
- [nongnu] elpa/exec-path-from-shell 2ae5088c21 015/114: Use printf instead of echo (thanks @bradleywright), ELPA Syncer, 2023/09/05
- [nongnu] elpa/exec-path-from-shell de589a96ba 017/114: Use parse-colon-path to split $PATH, ELPA Syncer, 2023/09/05
- [nongnu] elpa/exec-path-from-shell 183385ab94 016/114: Set checkdoc-minor-mode in local vars without using exec, ELPA Syncer, 2023/09/05
- [nongnu] elpa/exec-path-from-shell 8ec1a90951 019/114: Fully escape interspersed null characters too (see #5), ELPA Syncer, 2023/09/05
- [nongnu] elpa/exec-path-from-shell f8e39d754c 023/114: Tidier code for double-quoting printf args, ELPA Syncer, 2023/09/05
- [nongnu] elpa/exec-path-from-shell 54f272f46e 024/114: Better docstrings, ELPA Syncer, 2023/09/05
- [nongnu] elpa/exec-path-from-shell ab268a035a 026/114: Use the system-wide printf binary (if available) instead of shell built-in,
ELPA Syncer <=
- [nongnu] elpa/exec-path-from-shell 1e51ae1f97 027/114: With tcsh, examine each variable with a separate shell invocation, ELPA Syncer, 2023/09/05
- [nongnu] elpa/exec-path-from-shell 3ff20e8d60 028/114: Update copyright year, ELPA Syncer, 2023/09/05
- [nongnu] elpa/exec-path-from-shell 49219e9425 029/114: Append exec-directory to exec-path, as is conventional, ELPA Syncer, 2023/09/05
- [nongnu] elpa/exec-path-from-shell 247683134a 035/114: Include shell output in debug messages, ELPA Syncer, 2023/09/05
- [nongnu] elpa/exec-path-from-shell 4f90eff044 039/114: Include shell output in error upon non-zero exit, ELPA Syncer, 2023/09/05
- [nongnu] elpa/exec-path-from-shell 54c1d4a0c6 047/114: Don't break if $SHELL is unset at load-time, ELPA Syncer, 2023/09/05
- [nongnu] elpa/exec-path-from-shell e381af89a7 048/114: Note about inheriting of environment variables, ELPA Syncer, 2023/09/05
- [nongnu] elpa/exec-path-from-shell 4c328130ec 049/114: Remove unnecessary dash to appease old csh, ELPA Syncer, 2023/09/05
- [nongnu] elpa/exec-path-from-shell 63a88bfb4f 055/114: Warn users if the "-i" arg makes a difference given their startup files, ELPA Syncer, 2023/09/05
- [nongnu] elpa/exec-path-from-shell 5836fb1656 066/114: Drop mention of marmalade, ELPA Syncer, 2023/09/05