From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms13.migadu.com with LMTPS id AAxtLGSWJ2dqVwEAe85BDQ:P1 (envelope-from ) for ; Sun, 03 Nov 2024 15:27:32 +0000 Received: from aspmx1.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2.migadu.com with LMTPS id AAxtLGSWJ2dqVwEAe85BDQ (envelope-from ) for ; Sun, 03 Nov 2024 16:27:32 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=debbugs.gnu.org header.s=debbugs-gnu-org header.b=k7OSJOLz; dkim=fail ("headers rsa verify failed") header.d=pelzflorian.de header.s=key2 header.b=YmIPi8eh; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org"; dmarc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1730647652; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=TmEFpeo7keVH2CLQrlvsfYBJaGRD3jEK1yy5mjahTV8=; b=hh4AxYBI/7wbIdK8s1/AfntICfIffSYVEQ4GEIO4SvFYPEvT0Mo9r+XeZwEOtX5o8FQHhT LkSSvfJWDOSA9Y9oU5Rj9412iklvLeLTHkkRMv1Pmo4L6BXIOSkA1N9o7nSYhhK+13RjVn YIR9sNH2/8Y00h+O0XC/7bA5WgMOA672BJXO5KcPKchxEZIQDDyLzOtP/f442QCHJzPc0I GPhrTLjiSTHMjg7RiVWTMQJcQ6IFG6FZtNSp7helSmO0/EzX7gyT2TeQmBfecc8WEMTG5u 702iiBxZnnN9/cBMZDE134+g6oBeCHqAqps2dC1OthOWAa8a3300bcxXTHyNSQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=debbugs.gnu.org header.s=debbugs-gnu-org header.b=k7OSJOLz; dkim=fail ("headers rsa verify failed") header.d=pelzflorian.de header.s=key2 header.b=YmIPi8eh; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org"; dmarc=none ARC-Seal: i=1; s=key1; d=yhetil.org; t=1730647652; a=rsa-sha256; cv=none; b=WiBWK3pPzqwTPoqZXWYXr2RcZZywN/c42qIMJUof/4Txik16EifYyP4tBOxofBq+LiYY3E TpjDvClsU9b6w+9SgSD9w9hPEn//wipkhTlUbqBKPOMl3G1M+6vEZxV+LWx0VCRlSYfZI0 RkeqZkPsVQpnNqGeQ+nI241GFUoUNXJ4wcVTYj0vvF6jxTn0JCnK6+cNSmOo8x015vSKd/ HTmzBLid1WsDk8AJ/P7YemZSYPyha8M0xcL9qlD0iKIEeY0aIOnNoC3K9EiDDMnHfFcFnb ItH+e4qEHCiLW30QscVe4HxYoNmSxno2TaA8B/MaKk6uBlS4B3L/WzPGROXPBg== Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 04BA58A354 for ; Sun, 03 Nov 2024 16:27:32 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1t7cVN-0002cR-0p; Sun, 03 Nov 2024 10:27:05 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1t7cVK-0002c7-OJ for guix-patches@gnu.org; Sun, 03 Nov 2024 10:27:03 -0500 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1t7cVK-0002Ph-Ft for guix-patches@gnu.org; Sun, 03 Nov 2024 10:27:02 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:References:In-Reply-To:Date:From:To:Subject; bh=TmEFpeo7keVH2CLQrlvsfYBJaGRD3jEK1yy5mjahTV8=; b=k7OSJOLzfbbxqKBmzQOmm229e3BdPMLjw35aiBMoEhmWkkrDHfjCjGbiWjzzaMWTn77JsWZB85kUtt/Jo9PR54xupXAmdMqH7+Oc640LwJ2wQjQuvelys/OZnKP+6fBRsOCRYRmQnz22Md0bHYoR6qzU/Nc5UdBRyiMnJy31nWHQhiIAIL/4kpj02VM441bkh/mFFPJWamqI7PSJrJibIj7OMBHQEv8zg5Id35Gqjhfd5RDH8uJXyO8WZpmVg8VFpwvOjh99owDXDNCkdyCPY/goZlN+59yOazOykk3CPnxjjnlf2HADwnURPjTVmxWDg1SdJnRY24ZT/7w4Z7slAg==; Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1t7cVK-0002ZT-3r for guix-patches@gnu.org; Sun, 03 Nov 2024 10:27:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#74190] [PATCH 1/3] install: Open info manuals that have region codes. Resent-From: Florian Pelz Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sun, 03 Nov 2024 15:27:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 74190 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 74190@debbugs.gnu.org Cc: Florian Pelz Received: via spool by 74190-submit@debbugs.gnu.org id=B74190.17306475909845 (code B ref 74190); Sun, 03 Nov 2024 15:27:02 +0000 Received: (at 74190) by debbugs.gnu.org; 3 Nov 2024 15:26:30 +0000 Received: from localhost ([127.0.0.1]:32819 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1t7cUo-0002Yj-0k for submit@debbugs.gnu.org; Sun, 03 Nov 2024 10:26:30 -0500 Received: from relay.yourmailgateway.de ([194.59.206.189]:44399) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1t7cUk-0002Yd-TG for 74190@debbugs.gnu.org; Sun, 03 Nov 2024 10:26:28 -0500 Received: from relay02-mors.netcup.net (localhost [127.0.0.1]) by relay02-mors.netcup.net (Postfix) with ESMTPS id 4XhJNJ5fhPz479m for <74190@debbugs.gnu.org>; Sun, 3 Nov 2024 16:26:24 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=pelzflorian.de; s=key2; t=1730647584; bh=FEn6IOBrJxi82JPd8pJvUHVUdPgxt6+ygxe1NI73kaw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=YmIPi8ehoKW0UNEzozr8zs6VMeBxutQGOa/d+E9MKi5Vs/29/vDBc5WYMOQMWsqb3 kAkMV1XvW8seI6pX6WyRdHa2F7BuiZ7paIm4zul2JDYXLPCGaBwRtYZDX4u/krrTa5 /PyakMRPwEb8UGOif6TMzQvHPBAfdne8otU18ghJ74NI4Mqd91TfQtC6DFR3hWjZVU eWo9tpYWGgSjHnWFhDwsEGbc66kSTU1xtc7DJPOdd7MYsHL2NTjsKyXhiwv/sZbNSZ tW4IuzQpPCSYaFG7GdkKlmroOpZt56/LpmrpWzXxLrSiEImTP9p8xcLkGNkbqgRRY1 HOAiy7GxbBxBw== Received: from policy02-mors.netcup.net (unknown [46.38.225.35]) by relay02-mors.netcup.net (Postfix) with ESMTPS id 4XhJNJ5HFfz82Lw for <74190@debbugs.gnu.org>; Sun, 3 Nov 2024 16:26:24 +0100 (CET) Received: from mxe217.netcup.net (unknown [10.243.12.53]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by policy02-mors.netcup.net (Postfix) with ESMTPS id 4XhJNJ3p3Yz8sbF for <74190@debbugs.gnu.org>; Sun, 3 Nov 2024 16:26:23 +0100 (CET) Received: from florianhp.fritz.box (ipb218687b.dynamic.kabel-deutschland.de [178.24.104.123]) by mxe217.netcup.net (Postfix) with ESMTPSA id 387A384310; Sun, 3 Nov 2024 16:26:16 +0100 (CET) From: Florian Pelz Date: Sun, 3 Nov 2024 16:25:40 +0100 Message-ID: X-Mailer: git-send-email 2.46.0 In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Rspamd-Queue-Id: 387A384310 X-Rspamd-Server: rspamd-worker-8404 X-NC-CID: UHR8ISU3Aa3Cn9URPEW97FNncC7ARJdFFnGNYeCfUaTPLSBlep9zZG/U X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: guix-patches-bounces+larch=yhetil.org@gnu.org X-Migadu-Country: US X-Migadu-Flow: FLOW_IN X-Migadu-Scanner: mx11.migadu.com X-Migadu-Spam-Score: -0.54 X-Spam-Score: -0.54 X-Migadu-Queue-Id: 04BA58A354 X-TUID: 98v0iw6KJoFp Because pt_PT and pt_BR have many differences, such as how the word “file” gets translated, Guix’ pt_BR info manual is called (guix.pt_BR) instead of (guix.pt). * gnu/system/install.scm (log-to-info): Try region coded manual file names. (%installation-node-names): Add node names for pt_BR and zh_CN. Change-Id: I89beebd323ee69ca83c22321c9d9e664b32cf6f3 --- NOTE: This patch also causes the Chinese manual to be opened for zh_CN, which is somewhat broken during installation, because Chinese characters cannot be displayed on an ordinary TTY. I have made only trivial attempts to run kmscon from documentation-shepherd-service, which failed. But including this patch still seems proper to me despite trouble with zh_CN. pt_BR is also troubled by the texinfo info-reader crashing, which is addressed in patch 3/3. gnu/system/install.scm | 29 ++++++++++++++++++----------- 1 file changed, 18 insertions(+), 11 deletions(-) diff --git a/gnu/system/install.scm b/gnu/system/install.scm index 78a3cdaaec..4de903c59b 100644 --- a/gnu/system/install.scm +++ b/gnu/system/install.scm @@ -4,7 +4,7 @@ ;;; Copyright © 2016 Andreas Enge ;;; Copyright © 2017 Marius Bakke ;;; Copyright © 2017, 2019 Tobias Geerinckx-Rice -;;; Copyright © 2020 Florian Pelz +;;; Copyright © 2020, 2024 Florian Pelz ;;; Copyright © 2020 Efraim Flashner ;;; Copyright © 2022 Josselin Poiret ;;; Copyright © 2023 Herman Rimm @@ -31,11 +31,9 @@ (define-module (gnu system install) #:use-module (gnu bootloader u-boot) #:use-module (guix gexp) #:use-module (guix store) - #:use-module (guix monads) #:use-module (guix modules) #:use-module ((guix packages) #:select (package-version supported-package?)) #:use-module (guix platform) - #:use-module ((guix store) #:select (%store-prefix)) #:use-module (guix utils) #:use-module (gnu installer) #:use-module (gnu system locale) @@ -47,7 +45,6 @@ (define-module (gnu system install) #:use-module (gnu packages admin) #:use-module (gnu packages bash) #:use-module (gnu packages bootloaders) - #:use-module (gnu packages certs) #:use-module (gnu packages compression) #:use-module (gnu packages cryptsetup) #:use-module (gnu packages disk) @@ -60,7 +57,6 @@ (define-module (gnu system install) #:use-module (gnu packages texinfo) #:use-module (gnu packages xorg) #:use-module (ice-9 match) - #:use-module (srfi srfi-26) #:export (installation-os a20-olinuxino-lime-installation-os a20-olinuxino-lime2-emmc-installation-os @@ -100,7 +96,9 @@ (define %installation-node-names ("en" . "System Installation") ("es" . "Instalación del sistema") ("fr" . "Installation du système") - ("ru" . "Установка системы"))) + ("pt_BR" . "Instalação do sistema") + ("ru" . "Установка системы") + ("zh_CN" . "系统安装"))) (define (log-to-info tty user) "Return a script that spawns the Info reader on the right section of the @@ -111,13 +109,22 @@ (define (log-to-info tty user) (locale (cadr (command-line))) (language (string-take locale (string-index locale #\_))) + (with-region (string-take locale + (string-index + locale + (char-set #\. #\/ #\@)))) (infodir "/run/current-system/profile/share/info") - (per-lang (string-append infodir "/guix." language - ".info.gz")) - (file (if (file-exists? per-lang) - per-lang - (string-append infodir "/guix.info"))) + (per-lang (lambda (code) + (string-append infodir "/guix." code + ".info.gz"))) + (file ((@ (srfi srfi-1) find) file-exists? + (list (per-lang with-region) + (per-lang language) + (string-append infodir + "/guix.info.gz")))) (node (or (assoc-ref '#$%installation-node-names + with-region) + (assoc-ref '#$%installation-node-names language) "System Installation"))) (redirect-port tty (current-output-port)) -- 2.46.0