From debbugs-submit-bounces@debbugs.gnu.org Thu Sep 21 11:25:57 2017 Received: (at submit) by debbugs.gnu.org; 21 Sep 2017 15:25:57 +0000 Received: from localhost ([127.0.0.1]:51727 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dv3MT-0006pK-Ed for submit@debbugs.gnu.org; Thu, 21 Sep 2017 11:25:57 -0400 Received: from eggs.gnu.org ([208.118.235.92]:44095) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dv3MR-0006p6-6a for submit@debbugs.gnu.org; Thu, 21 Sep 2017 11:25:55 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dv3ML-0002nm-33 for submit@debbugs.gnu.org; Thu, 21 Sep 2017 11:25:49 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-0.5 required=5.0 tests=BAYES_05,FREEMAIL_FROM, T_DKIM_INVALID autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:58976) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1dv3MK-0002ne-VV for submit@debbugs.gnu.org; Thu, 21 Sep 2017 11:25:49 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:35035) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dv3MG-0003xy-SK for bug-gnu-emacs@gnu.org; Thu, 21 Sep 2017 11:25:48 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dv3MF-0002kE-Sw for bug-gnu-emacs@gnu.org; Thu, 21 Sep 2017 11:25:44 -0400 Received: from mail-wm0-x231.google.com ([2a00:1450:400c:c09::231]:50345) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dv3MF-0002hT-Jk for bug-gnu-emacs@gnu.org; Thu, 21 Sep 2017 11:25:43 -0400 Received: by mail-wm0-x231.google.com with SMTP id b195so2885460wmb.5 for ; Thu, 21 Sep 2017 08:25:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=vCzcXhvcbhENg7Kq1LbljF9NPUDT587h4ZzwUv3XKwc=; b=qIJQvwGhzwN6vfzyhped74bXrPBKPLsZJLZ4++YR6BliNSY5IoMaoXZB5APhcY40DE BApSe0EktqhBA7vmFv+qqgMra07p9W9ucgF5N3hmrgN0AsAhGCDRtrILh5wnqB0mDpd8 AZCAWXRdh1uY5Yo2hUR00SffLk67jvmN+1pdU47scJBqun4B2JNmSz6adCbECddqCcjf LJ940X8hL/fZWewaXFpQ8deuPLDt5TGxU8VB273kgnEjvn49MXW+1jUHqXlACaImiB5M vCXKhUwTBrzD67VRZu/lHUDmK0PzkjZ25yUKPGbZ/MTRC9tgh9W5GCT9wiFVw9T/eppl o4sg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=vCzcXhvcbhENg7Kq1LbljF9NPUDT587h4ZzwUv3XKwc=; b=ntI+SJLBkCdeVOdhS9dfibHggPJjJmno6oOYgst2kkc0ZYBY8tivi6rEhQaH7Uutyn ZcW9eZX0XgVB9zOVNRwa6asezSRQD3MTb01wBNUItgxgWFAPNpvgKBU8jI/seT1t5Wh6 ipCsVyjRBZVJUK4XU0knfyxaxjlYYOzWk01K/3C9H0OeCkD7L6iHBH0IbdT68XeagknK gsRcZf6Zve5P54AFqkZufoVaX9HEBhKJgAwvFVXmCo6LnkNOttVxFlGvaTQ+Y/3YzEa4 lEIbsxTdJRHLp7bjLH11zL2VErrLm+FVrThu32xMkQTFLIVsYKog/MO4Bxxqy0SMkRHN P/Qw== X-Gm-Message-State: AHPjjUgaGzyVViG70YfzXxtLUI15DTYtAtUSI28pnYa2wPxkrIH3rCZu 7BVf4fzXa0ih3xXWyy3CbXvhAB5+P6XOyaAP7pekHg== X-Google-Smtp-Source: AOwi7QCBLi2FPAD5PMhpEmWdlTXPpzw+XxEi8Y3IrVwH873ubEaz/foux9S9pJz0wV1P0bRZ8M+s78LbtTEYUy8gYqA= X-Received: by 10.28.74.89 with SMTP id x86mr1378457wma.57.1506007540648; Thu, 21 Sep 2017 08:25:40 -0700 (PDT) MIME-Version: 1.0 Received: by 10.28.214.211 with HTTP; Thu, 21 Sep 2017 08:25:40 -0700 (PDT) From: Yegor Timoshenko Date: Thu, 21 Sep 2017 15:25:40 +0000 Message-ID: Subject: eshell/sudo find-file doesn't work as expected with files only readable by root To: bug-gnu-emacs@gnu.org Content-Type: text/plain; charset="UTF-8" X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -4.0 (----) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -4.0 (----) To reproduce, M-x eshell and compare behavior of these two commands: $ ff /sudo::/etc/sudoers $ sudo ff /etc/sudoers In the first case the buffer is editable (and can be saved), while in the latter it is opened read-only. Switching read-only flag with C-x C-q doesn't help: I can edit the buffer, but not save it (results in "Doing chmod: operation not permitted" error). GNU Emacs 27.0.50 (build 1, x86_64-pc-linux-gnu, X toolkit, Xaw scroll bars) of 2017-09-21 (198ba449845ffa557ac272c3219c703148648f53) Reproducible in Emacs 25.3 as well. From debbugs-submit-bounces@debbugs.gnu.org Thu Sep 21 11:31:02 2017 Received: (at 28540) by debbugs.gnu.org; 21 Sep 2017 15:31:02 +0000 Received: from localhost ([127.0.0.1]:51737 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dv3RO-0006yt-9W for submit@debbugs.gnu.org; Thu, 21 Sep 2017 11:31:02 -0400 Received: from mail-wm0-f50.google.com ([74.125.82.50]:47826) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dv3RM-0006yN-Ec for 28540@debbugs.gnu.org; Thu, 21 Sep 2017 11:31:00 -0400 Received: by mail-wm0-f50.google.com with SMTP id r136so2959475wmf.2 for <28540@debbugs.gnu.org>; Thu, 21 Sep 2017 08:31:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=Z5JQR+XAqiWniEMF9WvFkbsvG/55ePtoA4ifepXLZ0Y=; b=e9WKPAYI/IklL3up4WGv9UkZrX4pDYp2NLe3gqCCVTkLA/uSFUpfWrtjozQDwrZeiv hQ6bk+YspPVNMzyL+6JP25TfZ9mfxcvpuvGplUcz1fW6Zo4xOS2qAR1nmx0a8RRO8jfA CMtaeioaEP1WqhgfJQVWYJrUHDw5CbcQ6+uT6SQ5dQYTdwa9eq3GkWoXOYQAFuKfvn0J pfZ3BNuEiMKa/I1rP7Kqrisv6F6Bh1Ew7FrdeEWC5xGMgVTJWThrZro7I/rrJPbV+n2b BM/Oq1PYpd3lgrYCWpSDSl7z2vjqiW+ZZDcK2vam19hR70SY/neGKCZzfg8dq3XtFYnP Y2MQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=Z5JQR+XAqiWniEMF9WvFkbsvG/55ePtoA4ifepXLZ0Y=; b=ZFKzuOP5Qa+Px8wQ0Us/jDflNHqlVt9ryFSrX6H63GMdF3cUYUS0w1Gtp3XB/jveAg wMQrzRscwFbPsEu1U2TFpbC4RA2KVFNJskbGbnF/3zx4K1LLd56sxHkPwylAEvjurQ7g U1hWlNs9gEf3nlQp3i6diuws4dKpqGVIx7WXrt3BoZkhq2BYb7RHML78IVPcQfEzP1RU nsBxR3/bGwmDfKDy/IdaDWL2fEO+GPWe1J8XmquJSl74ykheFlxAMZ+AC6O59Hr3/bkt CfbJX9njO21L+Blntv6gz2rp7xLPOMWen2Uvgymqa8Og2Uk+6RKYly1VrueL7X6XBNiE OqHQ== X-Gm-Message-State: AHPjjUgCnhbe2/hlHBkZVnlYOg14mN6Lsl0QlJa/6yHKpOEMGA13B8qW 4HSAmVKnOBuSamBHDgUWd+PdtcADboSDhLmYmHz8Xg== X-Google-Smtp-Source: AOwi7QBJpMB+aitC9PltPJcz5fx7I/je0TbTvR71d5qBZdC4DcvJVG1HqAUeL8gWKE1I9WR9AtjdKIxaN7WqHSjgk0A= X-Received: by 10.28.226.84 with SMTP id z81mr1346160wmg.108.1506007854534; Thu, 21 Sep 2017 08:30:54 -0700 (PDT) MIME-Version: 1.0 Received: by 10.28.214.211 with HTTP; Thu, 21 Sep 2017 08:30:53 -0700 (PDT) In-Reply-To: References: From: Yegor Timoshenko Date: Thu, 21 Sep 2017 15:30:53 +0000 Message-ID: Subject: Re: bug#28540: Acknowledgement (eshell/sudo find-file doesn't work as expected with files only readable by root) To: 28540@debbugs.gnu.org Content-Type: text/plain; charset="UTF-8" X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 28540 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.0 (/) Sorry, two assumptions in the previous email: (defalias 'ff 'find-file) (eval-after-load 'esh-module '(add-to-list 'eshell-modules-list 'eshell-tramp)) On Thu, Sep 21, 2017 at 3:26 PM, GNU bug Tracking System wrote: > Thank you for filing a new bug report with debbugs.gnu.org. > > This is an automatically generated reply to let you know your message > has been received. > > Your message is being forwarded to the package maintainers and other > interested parties for their attention; they will reply in due course. > > Your message has been sent to the package maintainer(s): > bug-gnu-emacs@gnu.org > > If you wish to submit further information on this problem, please > send it to 28540@debbugs.gnu.org. > > Please do not send mail to help-debbugs@gnu.org unless you wish > to report a problem with the Bug-tracking system. > > -- > 28540: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=28540 > GNU Bug Tracking System > Contact help-debbugs@gnu.org with problems From debbugs-submit-bounces@debbugs.gnu.org Fri Jun 22 08:23:13 2018 Received: (at 28540) by debbugs.gnu.org; 22 Jun 2018 12:23:13 +0000 Received: from localhost ([127.0.0.1]:59733 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fWL5t-0008HD-I0 for submit@debbugs.gnu.org; Fri, 22 Jun 2018 08:23:13 -0400 Received: from mout.gmx.net ([212.227.15.18]:39369) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fWL5r-0008Gq-S5 for 28540@debbugs.gnu.org; Fri, 22 Jun 2018 08:23:12 -0400 Received: from detlef.gmx.de ([212.86.50.101]) by mail.gmx.com (mrgmx001 [212.227.17.190]) with ESMTPSA (Nemesis) id 0MNqfr-1fZN6K22TT-007WME; Fri, 22 Jun 2018 14:23:03 +0200 From: Michael Albinus To: Yegor Timoshenko Subject: Re: bug#28540: eshell/sudo find-file doesn't work as expected with files only readable by root References: Date: Fri, 22 Jun 2018 14:23:02 +0200 In-Reply-To: (Yegor Timoshenko's message of "Thu, 21 Sep 2017 15:25:40 +0000") Message-ID: <87o9g3f1sp.fsf@gmx.de> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K1:LY0fzjON/a2G55D9ZLUpQMTMh2nEVmFpSMQ+fxyIknH3cOTQZd/ p7fswl0aiWgSH3S7EPgMWC/6WU+fnecJJx7jTCJXHkF7DZNC/EvgF4MXWgCqS5lMrN1svfX 81Ix79iEGETBX/ZNDLwKFA8m5c6AqHHNLzK+fbYaXPGOc+fXAu/YR3dseaRQwW2/ALN6nBy /zVnQ+IG9XX7UUtNqiUEA== X-UI-Out-Filterresults: notjunk:1;V01:K0:pWXvDYWKRoI=:fL3ylwgWAYHY7S9n2HhvVx QCI8rcTp0SLL1r1kgmT4u784Jjqh2YfQB99z1GVAyPj9Jc1MD6/iDVCq/UzIHmL0/XsV5AAlq FoPZnte1Ou2g2RCZdFwWWvfSJnM5bv3JgKff0PggsST6I5jbW8qbQMjEtYf5qy4xlrw6HAlLP P80SKq5oBf6cwveBSL1iMziNwzzzYSxr0Btww+lrSuL0kecgLPUyQ+6NNZCIYIrAu58G+q7Iu h8qZ/BspKdseIruiNjRmmKV5I0ttcriQd+1pfC9yUkDc22AwGSUDGX+Tq6UCaaWXy6uWA4zv9 E/EjF65n6z0PMQajQCUeuTzsNHgoSlFPQ9s+aDURGDPI+HceyboT2NoA2+1quoyLsdodsv/tb rTb1wVnh4bgC4hf5qU2H+JO5BfR6gw6YN6sH8O8Y9oc8Kv4koB6+kiYEsB054VGVMNEnNxdyk aN0iV4/bN1ifdaVEqvjciQOjORTwBtmQ2REZGejxXGMh/XWEG4PLA6iwSQyQB/AHo0Gxa1KPe AfMS7juwip9YrICIdLZq8YSXAs7Tr2tFmGHAYB6aodUVDBQGPhG5T9CLObwFPu0IjEuGpNmrk mQzHgTXZBJQBj4HFvJr8r0J2t8w3mmMloeJwkKeas99DrvyJNTtKFtrlptzOeDAS31dQmafL+ T2Xrwjvf1B/7PV4UGTD9fL4RfqzofxABlWnZr+ahi6pgFTaymaU7jNZbUiWwATP2tn6ZDEVkp T1RXPHAzArhXKPlYuaM8jkugumdqewUrcI8ACMvOFRMH6mfUB5NFSrQSQDP6NDFDZEFonfNjx 3fEtUTw X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 28540 Cc: 28540@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Yegor Timoshenko writes: Hi Yegor, [sorry for the late reply; this bug flew under my radar] > To reproduce, M-x eshell and compare behavior of these two commands: > > $ ff /sudo::/etc/sudoers > $ sudo ff /etc/sudoers > > In the first case the buffer is editable (and can be saved), while in > the latter it is opened read-only. Switching read-only flag with C-x > C-q doesn't help: I can edit the buffer, but not save it (results in > "Doing chmod: operation not permitted" error). > > GNU Emacs 27.0.50 (build 1, x86_64-pc-linux-gnu, X toolkit, Xaw scroll bars) > of 2017-09-21 (198ba449845ffa557ac272c3219c703148648f53) > > Reproducible in Emacs 25.3 as well. > > Sorry, two assumptions in the previous email: > > (defalias 'ff 'find-file) > (eval-after-load 'esh-module > '(add-to-list 'eshell-modules-list 'eshell-tramp)) I believe this behavior is correct. In your first test, the file has been opened as "/sudo::/etc/sudoers". But in the second test, the file has been opened as "/etc/sudoers" (you will see this, when you try to pen another file via "C-x C-f": "/etc/" is offered to you as default directory). The point is, that the "sudo" command changes the default directory internally to "/sudo:root@localhost:...", but the following Lisp code (expanding your alias) evaluates as (find-file "/etc/passwd"). And although the current default directory is remote, just the local "/etc/passwd" is opened. And you have no write permissions there. In order to change this behavior, ehsell would need to analyze the command given after the leading "sudo". For shell commands like "sudo *cat /etc/sudoers", the file name must be kept literally, because it is evalled in the shell command. But for Lisp commands, like your "sudo ff /etc/sudoers", the file name must be expanded internally to "sudo ff /sudo::/etc/sudoers". This requires much knowledge about what a command like "cat" or "ff" is intended to do. I doubt we will go such far in eshell. Best regards, Michael. From debbugs-submit-bounces@debbugs.gnu.org Sat Sep 28 21:07:47 2019 Received: (at 28540) by debbugs.gnu.org; 29 Sep 2019 01:07:47 +0000 Received: from localhost ([127.0.0.1]:51676 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iENgg-0007iH-Lg for submit@debbugs.gnu.org; Sat, 28 Sep 2019 21:07:47 -0400 Received: from mail-pf1-f175.google.com ([209.85.210.175]:41840) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iENgc-0007hv-8K for 28540@debbugs.gnu.org; Sat, 28 Sep 2019 21:07:42 -0400 Received: by mail-pf1-f175.google.com with SMTP id q7so3533166pfh.8 for <28540@debbugs.gnu.org>; Sat, 28 Sep 2019 18:07:42 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to:cc; bh=mc0q2HJOv75deuWVVaZyRkNh4eNpywhvy5uMW2fmY+g=; b=iVMUuo4a0DnKdJ2ViEBr/OS5OV9QokmIUV2dZMcVgM3zCEwRTrR4HaXQuP+1r1TxcH dedwx/5W/80ErVJsZZfZib6wkmJEA5vJ0HDLW7SqTvAE5M+arfJ17RfrFNC1Ee7svH+C Ds4JjE2sfVsIRnm9MtQdOJukn+VOozBs7u38xv8Rk6rkMY7HSr2AGkPACEiKoHhQbN7M 72odZSkDNjkd6cva14nMZM/gsbj/aNI3yIg9UnLpHSNTzZR9piaDydrmXIXk7edMh+kN k8b6eEi9f18a3G8P26WE89PDQe9IdiXOrcDuAFiGVBl1/r/JVZGFWQd7vkfiVDPUTP3O +blw== X-Gm-Message-State: APjAAAVsymjykqMMI8YBoIj6or4EHMBvPj89iEqbBkkdvoEURHgXG6L4 FSfoYf4jO1MO1+waI26bBZN64C8eEJlqHXvC64E= X-Google-Smtp-Source: APXvYqxMTQvvWH4RXBJxnMKzswI7lC5y7jGRKkwowoC0iJvfcGat9b7ee5JIzkb+h55XlJRARtaN7/K1w4cokHq6jzI= X-Received: by 2002:a17:90a:cc08:: with SMTP id b8mr18846910pju.119.1569719256532; Sat, 28 Sep 2019 18:07:36 -0700 (PDT) MIME-Version: 1.0 From: Stefan Kangas Date: Sun, 29 Sep 2019 03:07:25 +0200 Message-ID: Subject: Re: bug#28540: eshell/sudo find-file doesn't work as expected with files only readable by root To: Michael Albinus Content-Type: text/plain; charset="UTF-8" X-Spam-Score: 0.4 (/) X-Debbugs-Envelope-To: 28540 Cc: 28540@debbugs.gnu.org, Yegor Timoshenko X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.6 (/) tags 28540 + wontfix close 28540 quit Michael Albinus writes: > Yegor Timoshenko writes: > > Hi Yegor, > > [sorry for the late reply; this bug flew under my radar] > >> To reproduce, M-x eshell and compare behavior of these two commands: >> >> $ ff /sudo::/etc/sudoers >> $ sudo ff /etc/sudoers >> >> In the first case the buffer is editable (and can be saved), while in >> the latter it is opened read-only. Switching read-only flag with C-x >> C-q doesn't help: I can edit the buffer, but not save it (results in >> "Doing chmod: operation not permitted" error). >> >> GNU Emacs 27.0.50 (build 1, x86_64-pc-linux-gnu, X toolkit, Xaw scroll bars) >> of 2017-09-21 (198ba449845ffa557ac272c3219c703148648f53) >> >> Reproducible in Emacs 25.3 as well. >> >> Sorry, two assumptions in the previous email: >> >> (defalias 'ff 'find-file) >> (eval-after-load 'esh-module >> '(add-to-list 'eshell-modules-list 'eshell-tramp)) > > I believe this behavior is correct. In your first test, the file has > been opened as "/sudo::/etc/sudoers". But in the second test, the file > has been opened as "/etc/sudoers" (you will see this, when you try to > pen another file via "C-x C-f": "/etc/" is offered to you as default > directory). > > The point is, that the "sudo" command changes the default directory > internally to "/sudo:root@localhost:...", but the following Lisp code > (expanding your alias) evaluates as (find-file "/etc/passwd"). And > although the current default directory is remote, just the local > "/etc/passwd" is opened. And you have no write permissions there. > > In order to change this behavior, ehsell would need to analyze the > command given after the leading "sudo". For shell commands like "sudo > *cat /etc/sudoers", the file name must be kept literally, because it is > evalled in the shell command. But for Lisp commands, like your "sudo ff > /etc/sudoers", the file name must be expanded internally to "sudo ff > /sudo::/etc/sudoers". > > This requires much knowledge about what a command like "cat" or "ff" is > intended to do. I doubt we will go such far in eshell. I agree. To do this right in general would be a significant undertaking for a very minor benefit. I'm therefore closing this as wontfix. If anyone disagrees with that, feel free to reopen. Best regards, Stefan Kangas From unknown Fri Jun 13 11:28:27 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Sun, 27 Oct 2019 11:24:09 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator