From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from forward503j.mail.yandex.net (forward503j.mail.yandex.net [IPv6:2a02:6b8:0:801:2::113]) by sourceware.org (Postfix) with ESMTPS id 60EAE3858C83 for ; Fri, 19 Aug 2022 09:20:03 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 60EAE3858C83 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=yandex.ru Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=yandex.ru Received: from myt5-aad1beefab42.qloud-c.yandex.net (myt5-aad1beefab42.qloud-c.yandex.net [IPv6:2a02:6b8:c12:128:0:640:aad1:beef]) by forward503j.mail.yandex.net (Yandex) with ESMTP id AFBAE1DAF228; Fri, 19 Aug 2022 12:20:01 +0300 (MSK) Received: by myt5-aad1beefab42.qloud-c.yandex.net (smtp/Yandex) with ESMTPSA id brbc97xO6L-K1hCc0HW; Fri, 19 Aug 2022 12:20:01 +0300 (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client certificate not present) X-Yandex-Fwd: 1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex.ru; s=mail; t=1660900801; bh=ls80Fjz6qXddj1IUI37KqiMalSpENKAaxmzUXTEtNt8=; h=In-Reply-To:Subject:Date:References:To:Message-ID:Reply-To:From; b=wqd9uiJz1PTzPBPkbVyrKh0FqEXm8Szfybb2JCsV7sbu2uPI697f6nauy3Qy1xCCJ afSQFqKcGMyrY/q1+jgYBnt4oL1KkNOZGMdi47Voy2fjKkkMqiNO+O79IcORfUgxSB MggmUH7vcrmdNnkSCFwCq1Cx+Banwk7dmfmSQyTU= Authentication-Results: myt5-aad1beefab42.qloud-c.yandex.net; dkim=pass header.i=@yandex.ru Received: from [192.168.1.10] (HELO daemon2.darkdragon.lan) by daemon2 (Office Mail Server 0.8.12 build 08053101) with SMTP; Fri, 19 Aug 2022 09:13:44 -0000 Date: Fri, 19 Aug 2022 12:13:44 +0300 From: Andrey Repin X-Mailer: The Bat! (v9.3.4) Professional Reply-To: cygwin@cygwin.com Message-ID: <73763715.20220819121344@yandex.ru> To: Christian Franke , cygwin@cygwin.com Subject: Re: resolv.conf and gnupg2 In-Reply-To: <3480b0f8-7b7e-6672-ce8a-ec675eb909a8@t-online.de> References: <61cf96e9-68f9-1186-9c02-61be61614f61@t-online.de> <1512349222.20220810174046@yandex.ru> <3480b0f8-7b7e-6672-ce8a-ec675eb909a8@t-online.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-0.2 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, KAM_NUMSUBJECT, KAM_THEBAT, NICE_REPLY_A, SPF_HELO_NONE, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: cygwin@cygwin.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: General Cygwin discussions and problem reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Aug 2022 09:20:05 -0000 Greetings, Christian Franke! > Andrey Repin wrote: >> Greetings, Christian Franke! >> >> ... >>> Unfortunately the ipconfig output is always localized, so this does only >>> work OOTB with English versions of Windows. The ipconfig parsing is also broken due to two reasons: >>> - The current Cygwin versions of awk, grep and sed no longer convert CR/LF >>> -> LF on stdin, so '/FooBar$/' patterns never match. >>> - ipconfig may output scoped IPv6 addresses ("fe80::1%12") which are not matched by the awk script. >>> A draft patch is attached. It also avoids the tmp file and uses shell builtins where possible. >> Why not use netsh with `chcp 65001`? > How would netsh help? > Netsh is also localized and changing the codepage does possibly not change > the output language. Changing the language would also require > '.../en-US/netsh.exe.mui' file which is not necessarily installed. netsh with console CP set to 65001 switching to English. > If netsh is run interactively, it prints a deprecation warning for > 'interface' and other commands and recommends usage of powershell. You are not going to run it interactively, so not really a problem. And netsh output is much more parsing friendly. -- With best regards, Andrey Repin Friday, August 19, 2022 12:11:11 Sorry for my terrible english...