emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/with-editor e804473 113/140: with-editor-export-editor: Us


From: Jonas Bernoulli
Subject: [nongnu] elpa/with-editor e804473 113/140: with-editor-export-editor: Use printf instead of echo
Date: Fri, 6 Aug 2021 12:51:31 -0400 (EDT)

branch: elpa/with-editor
commit e804473ff9b2621a58b9184f6cc7cd7740936d47
Author: Stéphane Soppera <soppera@users.noreply.github.com>
Commit: Jonas Bernoulli <jonas@bernoul.li>

    with-editor-export-editor: Use printf instead of echo
    
    The `-e' flag of `echo' that makes the command interpret
    backslash-escaped sequences (in particular "\037") is not supported
    in all shells.
    
    Shells that do not support it print the flag instead.
    
    So here we replace `echo' by `printf' which seems to be better
    supported and does the interpretation of backslash-escaped sequence
    by default.
    
    Re #71.
    Closes #72.
---
 with-editor.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/with-editor.el b/with-editor.el
index 4e439b7..03fd979 100644
--- a/with-editor.el
+++ b/with-editor.el
@@ -176,7 +176,7 @@ please see 
https://github.com/magit/magit/wiki/Emacsclient.";))))
 
 (defcustom with-editor-sleeping-editor "\
 sh -c '\
-echo -e \"WITH-EDITOR: $$ OPEN $0\\037 IN $(pwd)\"; \
+printf \"WITH-EDITOR: $$ OPEN $0\\037 IN $(pwd)\\n\"; \
 sleep 604800 & sleep=$!; \
 trap \"kill $sleep; exit 0\" USR1; \
 trap \"kill $sleep; exit 1\" USR2; \



reply via email to

[Prev in Thread] Current Thread [Next in Thread]