From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Michael Albinus Newsgroups: gmane.emacs.devel Subject: Re: Friendlier dired experience [CODE INCLUDED] Date: Wed, 04 Nov 2020 20:57:41 +0100 Message-ID: <87pn4sgaiy.fsf@gmx.de> References: <20201103104340.q34kqfita55w2u7h@E15-2016.optimum.net> <20201103171627.f33ud4xkwv6rqvcq@E15-2016.optimum.net> <87y2jifhjq.fsf@gmx.de> <20201103191043.42sdslilcmb47jg5@E15-2016.optimum.net> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="19335"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cc: Stefan Kangas , Jean Louis , Emacs-Devel List To: Boruch Baum Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Wed Nov 04 21:02:59 2020 Return-path: Envelope-to: ged-emacs-devel@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 1kaOzi-0004w5-J5 for ged-emacs-devel@m.gmane-mx.org; Wed, 04 Nov 2020 21:02:58 +0100 Original-Received: from localhost ([::1]:32866 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kaOze-0007JM-Qv for ged-emacs-devel@m.gmane-mx.org; Wed, 04 Nov 2020 15:02:57 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:39300) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kaOvD-0004W0-Nd for emacs-devel@gnu.org; Wed, 04 Nov 2020 14:58:19 -0500 Original-Received: from mout.gmx.net ([212.227.17.20]:60629) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kaOvB-0003Ky-IZ for emacs-devel@gnu.org; Wed, 04 Nov 2020 14:58:19 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1604519863; bh=BqPvpZeYpEwJNmolZzhMKgT2RVvopKLzVItuGyQ7xho=; h=X-UI-Sender-Class:From:To:Cc:Subject:References:Date:In-Reply-To; b=P95+F4uD/hPhYKcDgSv4AkX6ncK8GOrkwO0Sm/tYdpbml43E+4rdTUd5XiP+DHJFQ wkga9WKi3efh6lRyRhQEBBO9vSXFnDmlHMrkw+IInpp3WdwRnStc9cET/OAxP0fiqK S/tjE59rF6FkPFxnA/azejzeeh1H8BD15NaE3d+c= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Original-Received: from gandalf.gmx.de ([79.140.112.132]) by mail.gmx.com (mrgmx105 [212.227.17.168]) with ESMTPSA (Nemesis) id 1N49hB-1k9xzj3CBV-0105EE; Wed, 04 Nov 2020 20:57:42 +0100 In-Reply-To: <20201103191043.42sdslilcmb47jg5@E15-2016.optimum.net> (Boruch Baum's message of "Tue, 3 Nov 2020 14:10:43 -0500") X-Provags-ID: V03:K1:v8FTBJzaCiPprFdjiMB1JF9g70zn9J6mi3r2hq5QarXPIPt3Bd3 8djD9V5CJfwWiB8gywQQ06Jpc86uSdg6MvWwinumHgmVqrP0uTMdNi2VwiQbdZ2HFP1cPyJ ts4RcNMNt8AMau5rAfkCnpChQXvVoLMR4hnT/cpWyRM9lLCwmaF+pHuxYZCyPDQZFDgDKEC n0GU5ewAKotBf13EI9n+w== X-UI-Out-Filterresults: notjunk:1;V03:K0:xd3Xf/aCtiI=:Hu46rBpgtZVrHpsCBeSCTQ BOD9XhhBp6+NpalzxbNXLj+HjaDwwi7iNYcaKiqKoJkbGc03evnUUWHjGWwJGCjw+3qqXqaC+ h2tmxSzKmM8QHIrecaubXWGMEN197/pcgbcjkiym4Z0lL/TGsmFBPsnFZJItnYG7F54SNtZ2G Gaqu9dxIpes1JdOFLrTkLqudt1HH7epKzOw9bCTxU7SGRH/P6l+cxSsPEMQ7hh2hAve7qZVf0 zlXr5vAljJ0C2QpW9jgfscnqlT/L5QaMDTEsysvGbvRKiIaK8t2TlO8YfEV6TGK6l2Q2BUwfx 98nhl+FjDXD0QiNd3y7ITrEJWnOWzhVeJrKqumuohlWA5LkpKAxz2ARfBLCCoXCGrDJmEEd8n cx/00AQj/rWYzt9zEtal2v8d7MtnbuelPOBjHoy5XrSLWzO5WMA5rfXfUmEBJsLzE209cXTT1 Lv9JIOsIMYppff/ZBFfY3asEa4vl4CBPzr/BHCteteR6L7PS+iUAtJ722VtTdfljJsQXaTKBU GOsEDGjvkFav35cLvEbZ8wXxanjls8BQh4h057r/s3x5DE0lbsCBEHCFmFyHrFop1A/cVVn7w DobmkTvNKqKXzI0gj5eybR5rDyWr0dB4KAY8Kqe2TvzclO2CJQ8K6PgaRvmmiTMxKx0zhF5LB SfUYzuCos1hZRtkCPW2iT3JZBg5CSc4dL5cf8GHkkAy1qDtSXFP8aTOPzwsMr7bMxXT9Ur8hX aXbe/a4CHh2B3NukLyOruqktkPBNO6mjZ9HGiExgQ75SJuH0LWdtJik1CoUh/a+3jzNwvBZp Received-SPF: pass client-ip=212.227.17.20; envelope-from=michael.albinus@gmx.de; helo=mout.gmx.net X-detected-operating-system: by eggs.gnu.org: First seen = 2020/11/04 14:49:18 X-ACL-Warn: Detected OS = Linux 3.11 and newer [fuzzy] X-Spam_score_int: -25 X-Spam_score: -2.6 X-Spam_bar: -- X-Spam_report: (-2.6 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:258701 Archived-At: Boruch Baum writes: Hi Boruch, >> Since recently, remote files are trashed to the local trash can. Are you >> able to restore them, if the trash can is derived from XDG spec? > > Oooh. Nice point. I never tested the software with tramp / smb / ssh. > What the software does is respect the XDG metadata stored in the > trash/info directory and performs a file move to the location identified > by that metadata. The software is agnostic to the location, so if emacs > requires any extra processing to reach the "remote", I don't know if the > operation would succeed. It's reasonable to expect the file move to be > handled at a 'level below' the dired function call and so succeed, but I > don't know. > >> Test with recent master branch. > > I'm not set up for that just now. Can you try and report back? When I'm working in a remote buffer, "diredc-trash-info" does not work. This is because you call shell-command, which runs the command on the remote host. When I have trashed a file, say "/ssh:ford:/tmp/xxx", it appears as "/home/albinus/.local/share/Trash/files/xxx", in the local trash can. "/home/albinus/.local/share/Trash/info/xxx.trashinfo" contains the line Path=/ssh%3aford%3a/tmp/xxx as expected. However, "M-x diredc-trash-restore" returns with the error dired-rename-file: Renaming: No such file or directory, /home/albinus/.local/share/Trash/files/xxx, /ssh%3aford%3a/tmp/xxx I believe you must unhexlify the path in the .trashinfo. This is not only because of Tramp. A local file "/tmp/file with space", trashed via "M-x move-file-to-trash", has the entry Path=/tmp/file%20with%20space Calling "M-x diredc-trash-restore" restores it to "/tmp/file%20with%20space". Best regards, Michael.