all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Alexander Shukaev <haroogan@gmail.com>
To: Eli Zaretskii <eliz@gnu.org>
Cc: help-gnu-emacs <help-gnu-emacs@gnu.org>
Subject: Re: Autogen in Emacs Shell
Date: Fri, 1 May 2015 20:35:11 +0200	[thread overview]
Message-ID: <CAKu-7WzYdBuUDPF6Yv45nOFdjMz6mh4Yhb69EN0HGCZpbg=SGA@mail.gmail.com> (raw)
In-Reply-To: <83sibgqjb3.fsf@gnu.org>

>
> > Right, so explicitly doing
> >
> > (setenv "LANG" "en_US.UTF-8")
> >
> > solves both problems at once. Interesting... Do you have any comments on
> that?
> > Maybe clarifications on why this problem occurs? For instance, why
> `LANG' is
> > properly set in ConEmu, while in Emacs it has value `ENU'?
>
> Because the Windows locale names are different from Posix locale
> names.
>
> > Where does this even come from?
>
> From w32.c:init_environment:
>
>   /* Get default locale info and use it for LANG.  */
>   if (GetLocaleInfo (LOCALE_USER_DEFAULT,
>                      LOCALE_SABBREVLANGNAME | LOCALE_USE_CP_ACP,
>                      locale_name, sizeof (locale_name)))
>     {
>       for (i = 0; i < N_ENV_VARS; i++)
>         {
>           if (strcmp (env_vars[i].name, "LANG") == 0)
>             {
>               env_vars[i].def_value = locale_name;
>               break;
>             }
>         }
>     }
>
> > Is it OK to do
> >
> > (setenv "LANG" "en_US.UTF-8")
>
> Not if you want the rest of locale-specific code in Emacs itself to
> work, no.
>
> Why does a native Windows program such as bsdtar expect a Posix-style
> locale spec?  It's a bug, IMO.  The MS-Windows implementation of
> 'setlocale' will not work with Posix locale specs.
>
> > or there is some other more generic way?
>
> There's no generic way.  Locale names and specifications are not
> portable between Posix and non-Posix systems.
>
>
I see.  Thanks, Eli.

Finally, do you have any comments on the issue
with "~/emacs.d/init_bash.sh" that I've described before.  Let me introduce
another test case briefly.  Put

# Hello, World!
# Hello, World!
# Hello, World!

into "~/emacs.d/init_bash.sh".

Then start 'bash' from Emacs.  Here is what I see:

2015.05.01 Friday 20:30:46
Haroogan@G75VW:~
$
2015.05.01 Friday 20:30:46
Haroogan@G75VW:~
$
2015.05.01 Friday 20:30:46
Haroogan@G75VW:~
$
2015.05.01 Friday 20:30:46
Haroogan@G75VW:~
$

Those 3 newlines were really typed into the shell.  How come?


  reply	other threads:[~2015-05-01 18:35 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-29  2:36 Autogen in Emacs Shell Alexander Shukaev
2015-04-29  8:31 ` tomas
2015-04-29 15:51 ` Eli Zaretskii
2015-04-30 18:14   ` Alexander Shukaev
2015-04-30 19:26     ` Eli Zaretskii
2015-04-30 19:44       ` Alexander Shukaev
2015-04-30 19:54         ` Eli Zaretskii
2015-05-01  9:26     ` tomas
2015-05-01 14:33       ` Alexander Shukaev
2015-05-01 14:46         ` Alexander Shukaev
2015-05-01 15:03         ` tomas
2015-05-01 16:08           ` Alexander Shukaev
2015-05-01 17:06             ` Alexander Shukaev
2015-05-01 17:49               ` Eli Zaretskii
2015-05-01 18:35                 ` Alexander Shukaev [this message]
2015-05-01 18:51                   ` Eli Zaretskii
2015-05-01 19:05                     ` Alexander Shukaev
2015-05-01 19:07                       ` Alexander Shukaev
2015-05-01 19:26                       ` Eli Zaretskii
2015-05-01 19:38                   ` Eli Zaretskii
2015-05-01 19:46                     ` Alexander Shukaev
2015-05-02  6:31                       ` Eli Zaretskii

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='CAKu-7WzYdBuUDPF6Yv45nOFdjMz6mh4Yhb69EN0HGCZpbg=SGA@mail.gmail.com' \
    --to=haroogan@gmail.com \
    --cc=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.