From: Eli Zaretskii <eliz@gnu.org>
To: help-gnu-emacs@gnu.org
Subject: Re: Using emerge on windows? Funky errors with Temp files
Date: Fri, 18 Mar 2011 23:48:09 +0200 [thread overview]
Message-ID: <83zkosqew6.fsf@gnu.org> (raw)
In-Reply-To: <loom.20110318T221809-600@post.gmane.org>
> From: fork <forkandwait@gmail.com>
> Date: Fri, 18 Mar 2011 21:23:07 +0000 (UTC)
>
> diff: c:/DOCUME\~1/webbs/LOCALS\~1/Temp/emergeA4208Vv8: No such file or directory
> diff: c:/DOCUME\~1/webbs/LOCALS\~1/Temp/emergeB4208e2I: No such file or directory
The patch below should set you up. (Don't forget to recompile
emerge.el, and then load it or restart Emacs.)
--- lisp/emerge.el~ 2011-03-10 19:56:29.093750000 +0200
+++ lisp/emerge.el 2011-03-18 23:42:32.078125000 +0200
@@ -3187,21 +3187,26 @@
;; Metacharacters that have to be protected from the shell when executing
;; a diff/diff3 command.
-(defcustom emerge-metachars "[ \t\n!\"#$&'()*;<=>?[\\^`{|~]"
- "Characters that must be quoted with \\ when used in a shell command line.
+(defcustom emerge-metachars
+ (if (memq system-type '(ms-dos windows-nt))
+ "[ \t\"&<=>?*^|]"
+ "[ \t\n!\"#$&'()*;<=>?[\\^`{|~]")
+ "Characters that must be quoted when used in a shell command line.
More precisely, a [...] regexp to match any one such character."
:type 'regexp
:group 'emerge)
;; Quote metacharacters (using \) when executing a diff/diff3 command.
(defun emerge-protect-metachars (s)
- (let ((limit 0))
- (while (string-match emerge-metachars s limit)
- (setq s (concat (substring s 0 (match-beginning 0))
- "\\"
- (substring s (match-beginning 0))))
- (setq limit (1+ (match-end 0)))))
- s)
+ (if (memq system-type '(ms-dos windows-nt))
+ (shell-quote-argument s)
+ (let ((limit 0))
+ (while (string-match emerge-metachars s limit)
+ (setq s (concat (substring s 0 (match-beginning 0))
+ "\\"
+ (substring s (match-beginning 0))))
+ (setq limit (1+ (match-end 0)))))
+ s))
(provide 'emerge)
next prev parent reply other threads:[~2011-03-18 21:48 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-03-18 21:23 Using emerge on windows? Funky errors with Temp files fork
2011-03-18 21:31 ` fork
2011-03-18 21:54 ` Eli Zaretskii
2011-03-18 21:36 ` Eli Zaretskii
2011-03-18 21:48 ` Eli Zaretskii [this message]
[not found] <mailman.14.1300483407.31996.help-gnu-emacs@gnu.org>
2011-03-19 2:02 ` Stefan Monnier
2011-03-19 8:08 ` David Kastrup
2011-03-22 1:05 ` Stefan Monnier
2011-03-22 8:01 ` David Kastrup
2011-03-23 2:56 ` Kevin Rodgers
[not found] ` <mailman.2.1300849017.12215.help-gnu-emacs@gnu.org>
2011-03-23 7:23 ` David Kastrup
2011-03-25 3:55 ` Kevin Rodgers
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=83zkosqew6.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=help-gnu-emacs@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.