mirror of
git://git.sv.gnu.org/emacs.git
synced 2026-02-16 09:14:18 +00:00
; vc-git-command, vc-hg-command: Comments about MS-Windows encoding.
This commit is contained in:
parent
eb8d0d7afe
commit
18b87fab35
2 changed files with 23 additions and 0 deletions
|
|
@ -2492,6 +2492,17 @@ The difference to `vc-do-command' is that this function always invokes
|
|||
`vc-git-program'."
|
||||
(let ((coding-system-for-read
|
||||
(or coding-system-for-read vc-git-log-output-coding-system))
|
||||
;; Commands which pass command line arguments which might
|
||||
;; contain non-ASCII have to bind `coding-system-for-write' to
|
||||
;; `locale-coding-system' when (eq system-type 'windows-nt)
|
||||
;; because MS-Windows has the limitation that command line
|
||||
;; arguments must be in the system codepage. We do that only
|
||||
;; within the commands which must do it, instead of implementing
|
||||
;; it here, even though that means code repetition. This is
|
||||
;; because this let-binding has the disadvantage of overriding
|
||||
;; any `coding-system-for-write' explicitly selected by the user
|
||||
;; (e.g. with C-x RET c), or by enclosing function calls. So we
|
||||
;; want to do it only for commands which really require it.
|
||||
(coding-system-for-write
|
||||
(or coding-system-for-write vc-git-commits-coding-system))
|
||||
(process-environment
|
||||
|
|
|
|||
|
|
@ -1638,6 +1638,18 @@ This function differs from `vc-do-command' in that
|
|||
- BUFFER may be nil
|
||||
- it invokes `vc-hg-program' and passes `vc-hg-global-switches' to it
|
||||
before FLAGS."
|
||||
;; Commands which pass command line arguments which might
|
||||
;; contain non-ASCII have to bind `coding-system-for-write' to
|
||||
;; `locale-coding-system' when (eq system-type 'windows-nt)
|
||||
;; because MS-Windows has the limitation that command line
|
||||
;; arguments must be in the system codepage. We do that only
|
||||
;; within the commands which must do it, instead of implementing
|
||||
;; it here, even though that means code repetition. This is
|
||||
;; because such a let-binding would have the disadvantage of
|
||||
;; overriding any `coding-system-for-write' explicitly selected
|
||||
;; by the user (e.g. with C-x RET c), or by enclosing function
|
||||
;; calls. So we want to do it only for commands which really
|
||||
;; require it.
|
||||
(vc-hg--command-1 #'vc-do-command
|
||||
(list (or buffer "*vc*")
|
||||
okstatus vc-hg-program file-or-list)
|
||||
|
|
|
|||
Loading…
Reference in a new issue