all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Wayne Harris via Users list for the GNU Emacs text editor <help-gnu-emacs@gnu.org>
To: help-gnu-emacs@gnu.org
Subject: Re: on ESHELL, utf-8 and fossil command-line commit message
Date: Sat, 01 Oct 2022 16:09:41 -0300	[thread overview]
Message-ID: <86wn9jbbt6.fsf@protonmail.com> (raw)
In-Reply-To: 83y1tz9yix.fsf@gnu.org

Eli Zaretskii <eliz@gnu.org> writes:

>> Date: Sat, 01 Oct 2022 15:29:58 -0300
>> From:  Wayne Harris via Users list for the GNU Emacs text editor <help-gnu-emacs@gnu.org>
>> 
>> > You cannot use UTF-8 for encoding command-line arguments of
>> > subprocesses on MS-Windows.  Use your system's codepage instead.  This
>> > means make sure the Eshell buffer's value of buffer-file-coding-system
>> > is your system codepage, not UTF-8.
>> 
>> I'm glad I added that parenthesis about Windows.  (Thank you for the info!)
>> 
>> However, I still did not manage to get this right.  Could it be that I
>> don't know what my codepage is?  When I run ``chcp'', I get 850.
>> 
>> --8<---------------cut here---------------start------------->8---
>> C:\Users\mer>chcp
>> Active code page: 850
>> --8<---------------cut here---------------end--------------->8---
>
> Unlikely.  What does this say in Emacs:
>
>   M-: w32-ansi-code-page RET

It says 1252:

%(print w32-ansi-code-page)
1252
%

My new attempt:

--8<---------------cut here---------------start------------->8---
%(setq buffer-file-coding-system 'cp1252)
cp1252

%fs commit -m 'Naiveté.'

%fs timeline -n 1
=== 2022-10-01 ===
19:02:24 [0940d7ce5e] *CURRENT* Naiveté. (user: mer tags: trunk)
--- entry limit (1) reached ---
%
--8<---------------cut here---------------end--------------->8---

When I setq buffer-[...], I saw the modeline changing the encoding to a
'*'.  Hovering the mouse, I saw 

  Buffer coding system (multi-byte): cp1252, [...]

Mouse-3-clicking the '*', I see:

--8<---------------cut here---------------start------------->8---
* -- cp1252 (alias of windows-1252)

windows-1252 (Western European) encoding (MIME: WINDOWS-1252)
Type: charset (charset)
EOL type: Automatic selection from:
	[windows-1252-unix windows-1252-dos windows-1252-mac]
This coding system encodes the following charsets:
  windows-1252
--8<---------------cut here---------------end--------------->8---

>> Then in ESHELL I type:
>> 
>> --8<---------------cut here---------------start------------->8---
>> %(setq buffer-file-coding-system 'cp850-dos)
>> cp850-dos
>> 
>> %echo naive >> encoding.txt 
>> 
>> %fs commit -m 'Naïve.'
>> [...]
>> Sync done, wire bytes sent: 2882  received: 309  ip: 5.161.138.46
>> 
>> %fs timeline
>> === 2022-10-01 ===
>> 18:26:22 [c7835d354b] *CURRENT* Naïve. (user: mer tags: trunk)
>> [...]
>> New_Version: c7835d354b[...]
>> %
>> --8<---------------cut here---------------end--------------->8---
>
> Maybe you have other customizations that cause this.  What does the
> below say:
>
>   M-: default-process-coding-system RET

It says 

%(print default-process-coding-system)
(utf-8-dos . utf-8-unix)
%

I tried to change it to just cp1252.

--8<---------------cut here---------------start------------->8---
%(setq default-process-coding-system (cons 'cp1252 'cp1252))

%echo hello >> encoding.txt 

%fs commit -m 'Naiveté.'
[...]
New_Version: d992644b4bd515df3b9b99cd978e9081ea775098398f5e83cc359967dff470c3
[...]
Sync done, wire bytes sent: 3147  received: 309  ip: 5.161.138.46

%fs timeline -n 1
=== 2022-10-01 ===
19:04:34 [d992644b4b] *CURRENT* Naiveté. (user: mer tags: trunk)
--- entry limit (1) reached ---
%
--8<---------------cut here---------------end--------------->8---

What do you think?




  reply	other threads:[~2022-10-01 19:09 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-10-01 14:19 on ESHELL, utf-8 and fossil command-line commit message Wayne Harris via Users list for the GNU Emacs text editor
2022-10-01 15:05 ` Eli Zaretskii
2022-10-01 18:29   ` Wayne Harris via Users list for the GNU Emacs text editor
2022-10-01 18:41     ` Eli Zaretskii
2022-10-01 19:09       ` Wayne Harris via Users list for the GNU Emacs text editor [this message]
2022-10-01 19:18         ` Eli Zaretskii
2022-10-02 13:35           ` Wayne Harris via Users list for the GNU Emacs text editor

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=86wn9jbbt6.fsf@protonmail.com \
    --to=help-gnu-emacs@gnu.org \
    --cc=wharris1@protonmail.com \
    /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.