From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Nika Otiashvili Newsgroups: gmane.emacs.bugs Subject: bug#45357: [PATCH] * lisp/man.el (Man-getpage-in-background): always use shell-file-name Date: Wed, 23 Dec 2020 04:55:41 +0400 Message-ID: References: <83zh25rhyo.fsf@gnu.org> <87a6u565gi.fsf@gmx.de> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="2923"; mail-complaints-to="usenet@ciao.gmane.io" Cc: michael.albinus@gmx.de, 45357@debbugs.gnu.org To: eliz@gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Dec 23 01:58:43 2020 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1krsUF-0000g7-Uq for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 23 Dec 2020 01:58:43 +0100 Original-Received: from localhost ([::1]:40934 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1krsUF-0002Sb-0w for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 22 Dec 2020 19:58:43 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:57084) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1krsSd-0001q5-2X for bug-gnu-emacs@gnu.org; Tue, 22 Dec 2020 19:57:03 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:39662) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1krsSc-0005xe-87 for bug-gnu-emacs@gnu.org; Tue, 22 Dec 2020 19:57:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1krsSc-0001ek-5b for bug-gnu-emacs@gnu.org; Tue, 22 Dec 2020 19:57:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Nika Otiashvili Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 23 Dec 2020 00:57:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 45357 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 45357-submit@debbugs.gnu.org id=B45357.16086849866325 (code B ref 45357); Wed, 23 Dec 2020 00:57:02 +0000 Original-Received: (at 45357) by debbugs.gnu.org; 23 Dec 2020 00:56:26 +0000 Original-Received: from localhost ([127.0.0.1]:51208 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1krsS2-0001dx-9O for submit@debbugs.gnu.org; Tue, 22 Dec 2020 19:56:26 -0500 Original-Received: from mail-lf1-f41.google.com ([209.85.167.41]:42012) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1krsRz-0001dh-Hd for 45357@debbugs.gnu.org; Tue, 22 Dec 2020 19:56:24 -0500 Original-Received: by mail-lf1-f41.google.com with SMTP id b26so26745085lff.9 for <45357@debbugs.gnu.org>; Tue, 22 Dec 2020 16:56:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=x5WbOvvpQxSC/HhzCrfy/ejf2eYlCdR/rNZNrdRARfM=; b=ilULjj4cF9auVmD06R+stwmKe00R+wVkWkdlt4B1gPC9ZHNiH5jF34jPw4WYQsx9JZ xQRW/po13vXDZ/BCTi3/UWWiKI6ZvqeFOMRFMePc6QlQs7soI4v6PCa5eEmc1BTLJrlH 9ZP1NeKUMASUyX4obb4G0vgoxBOsyI1Per0YlwOQ5HeQolzAim7Lcvg/miHQbrHRFbLc x+AhpVqR444yl4s48M0OtfwSjmIk92JvyGCwQT9RTfDbfWsZ8jWHBrFVYLk2cyobHque wAJz/lgoU+it++i9ADxRzuYMVaDuMlCXQ144X1Y3LFZHMYQUy7jWq9i7lUvomvMpEqgp 41/g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=x5WbOvvpQxSC/HhzCrfy/ejf2eYlCdR/rNZNrdRARfM=; b=gO9ogksVU1TipyHVFrVYIw67m1LL9bXRddx9a6Gxv563e7qd3onGlQ78eFrADaL9VH V0ecH0P8qu5kdwP2xiVqGagumCikN9pYidd+dmzgq8KKccp6/8mPaPNq9m/GWoLE6M6H jBwsc7K0KDwV6Y3ptu0mAXdW4uv9/HaTG3kh/24EP15v+DmqDTMcBhfWyYNyHze3qwTS eFvoBlGUBgZ/4WnsvlsCRURk6lvpyCk3qBYNqRD2LglunTaw/LnqnCErfnEs0Ilm2Zpb nJnUz6vtZ6evJMHcIoKdRY4wXZS5q+PvkBNuUvKpCW2ZczERnpYU945GpuxDFwCA0pkH cv4g== X-Gm-Message-State: AOAM531L1F9raIJ7qKxXLZgSsZQKc9LQqcJJqyBuEbQpeyDavtUgioh2 A0OvK6FN9F1ZmQ1YK+GQ/PvlJLBvoOwhZiOLOw8= X-Google-Smtp-Source: ABdhPJwZEjAXUJXq9k9rcrL+3r5SxcbiK1dQXwP1M154eWarNOLdihy6RFCmqJerXB2S6I6t8ijbg4pgll89Sc8uGfg= X-Received: by 2002:ac2:5e74:: with SMTP id a20mr9333631lfr.81.1608684977387; Tue, 22 Dec 2020 16:56:17 -0800 (PST) In-Reply-To: <87a6u565gi.fsf@gmx.de> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:196594 Archived-At: Hello, Thanks for looking at the patch, Eli. Regarding the rc files, it seems there was an error on my part. I have (setq shell-command-switch "-cl") in my .emacs. The "-l" flag runs sh as a login shell, thus it loads my .profile. From there I source my .bashrc. Since I have bashisms in my .bashrc, sh simply sees them as syntax errors and exits. I should have inserted a check of $0 inside my .profile to prevent this. > OTOH, every Posix system I know about does have /bin/sh, so I'm > curious what kind of system did you see where /bin/sh is absent. Initially, I thought Windows users wouldn't have /bin/sh, but the cygwin and windows-nt checks I removed accounted for that and used shell-file-name instead of sh. So, I've concluded that the first two reasons described in my patch are irrelevant and the last one is indeed very weak. I believe my patch would not benefit anyone and it only solves a specific problem I had with my configuration. Regards, Nika Otiashvili On Tue, Dec 22, 2020 at 10:50 PM Michael Albinus wrote: > > Eli Zaretskii writes: > > Hi, > > > My problem is more a conceptual one: it is not trivial to replace > > /bin/sh with any other shell, because they work differently. The > > command in question builds a complex shell command to run, and it > > isn't obvious that any user shell will be able to run it. > > That's true. But we could require that shell-file-name points to a Posix > shell, if used in man.el. > > Btw, if we were to change man.el, I'd rather propose to use > start-process-shell-command, instead of composing the command manually. > > > Could you please elaborate on the specific problems you had and tell > > more about your system configuration where you bumped into these > > problems? > > This question still stands, yes. > > > Thanks. > > Best regards, Michael.