From unknown Thu Aug 14 22:23:05 2025 X-Loop: help-debbugs@gnu.org Subject: bug#65356: 30.0.50; [wishlist] Support Tramp method, user name and host name completion in eshell Resent-From: Michael Albinus Original-Sender: "Debbugs-submit" Resent-CC: jporterbugs@gmail.com, bug-gnu-emacs@gnu.org Resent-Date: Thu, 17 Aug 2023 18:03:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 65356 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: 65356@debbugs.gnu.org Cc: Jim Porter X-Debbugs-Original-To: bug-gnu-emacs@gnu.org X-Debbugs-Original-Xcc: Jim Porter Received: via spool by submit@debbugs.gnu.org id=B.169229533332669 (code B ref -1); Thu, 17 Aug 2023 18:03:01 +0000 Received: (at submit) by debbugs.gnu.org; 17 Aug 2023 18:02:13 +0000 Received: from localhost ([127.0.0.1]:45521 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qWhJy-0008Uk-57 for submit@debbugs.gnu.org; Thu, 17 Aug 2023 14:02:13 -0400 Received: from lists.gnu.org ([2001:470:142::17]:41372) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qWhJt-0008UB-5C for submit@debbugs.gnu.org; Thu, 17 Aug 2023 14:02:08 -0400 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 1qWhJn-0003Xq-5J for bug-gnu-emacs@gnu.org; Thu, 17 Aug 2023 14:01:59 -0400 Received: from mout.gmx.net ([212.227.17.20]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qWhJj-0006Rw-Fu for bug-gnu-emacs@gnu.org; Thu, 17 Aug 2023 14:01:58 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.de; s=s31663417; t=1692295312; x=1692900112; i=michael.albinus@gmx.de; bh=bRwWy2paAT5kiXJMSKshl8LObe6PjXpsYT0DGU0ETmg=; h=X-UI-Sender-Class:From:To:Subject:Date; b=aI0Rfj5ujCb6qdquEA/Vid9nO7pqH/WXKHXLsZ2d3lFywjAKd/u459rUk2opsIOCX13Uym/ iLzJtvN92DBJ2Jtpt1Zv7T1PeFn+TkJ8ze7+yaEgDDGLJ2g80EynrhQydhGdPvLdIdfg+QGi9 x13LkHsEwJc05Jp8hNoXIPiK0uFXj2v6y7oBMIr70COzRx9SESSzN+9xdc8NmC5qgacLQGDYA NGczjNqAiFeeO9JX44I7KxOWJQYNUZPGYw6KEbPQNfTUXGstKN+NLnPxL5+WYXUf+DZw5jdvd HRotXBvvI+4i7N359DMdswOYM+Vk7dPw9zEUNmAD5piwpy/vdHZQ== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Received: from gandalf.gmx.de ([185.89.39.27]) by mail.gmx.net (mrgmx105 [212.227.17.168]) with ESMTPSA (Nemesis) id 1ML9yc-1qETyX3jNK-00IHL0; Thu, 17 Aug 2023 20:01:52 +0200 From: Michael Albinus Date: Thu, 17 Aug 2023 20:01:51 +0200 Message-ID: <87r0o1r1io.fsf@gmx.de> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Provags-ID: V03:K1:B+pYvSMQb2Ua79+zMSCu/w7qI5m/1+RyJHVvohpspfyd2QhMN46 x6Vi3kdX7g2ko3nZY1A0to64CFLIOwiBbT06Vp88MzMPq1UtwVfOp/7l2OoqDp6+NamefY7 lyBBq8+Lvq2ct/aZ7FungJX7PzvlTed2FFRpvg8Tjb87YzekP9J5iGAknoeCw8DVskHNAAz FamRPKgc0I2e3Ti6Wv0hw== X-Spam-Flag: NO UI-OutboundReport: notjunk:1;M01:P0:GzEYhx59sEE=;6bGUy8mZpxeWRobzLLX2YOg7LOQ KQtYPZyoNW4F9hZPtYDe8mW5d51RSk9tzdwLSsydV36jrz9+TWxXqAYy1KyZlxOidEFEcgThp sqML2OYpzeRzbfPh9tlkPI16p0n1xrmTK0/M7wMXXwgExo/jLqdrGATxG8NOFakPNaQJMDyIQ xd/frhvYG4U8rDpbc8PxLBWK/sIVRFazg8oVFlg47TR5crCUV/1D/VU6Nu6AdKiqSGkeLbE+H LR/VN6b9gNxD8PpcVrph1uvebauYjtBqfT8ySE+VluiynKGYoDROVHkfowI25SV882AtWBy49 glBKZ9+Pb0+s1yUEsXOLs1N+W8knSgBakWeUzfubVDy7bzHLFKmXsClgtUL14yQEFYj1nd6S/ XdoSJbNoQvJEanGZdF5xwkBeZg3IPaQhGUsxCiKFSRTXXNXjIuZ1CMU6TSRVNNjXCe9CeEBkk 045zy/7gHH8xkBQhmvL8nYLGonLkjfson1ICLbRL2462vw0NuwDWNgEd+BmqkI3e4cNOG45Pb J7bSzQs1Qex6FDSV+l5kopJKFKbkKSDw4vTlGqDeWf1mxu39NH/KzIUynPtnvyiaLHsqrjLNT pMhI4axYy3txlGUycOkqRmh5a4e/vib8v3XBpOVnxuR2FkIZU9TOhP1KxvPy3dRmwqOvBLFkf nlleDxJrkvjrtIrNGuycALP5mCtQhT+6DEGEzfLeZ2hjwEygQ5opzwjlOHJDjaRNfikJndH9r cxYjx09cGlTCAM6lUgLUPU3v56pekzAiLk2Go77KU65P/Kq3Um0gKLxYDre3H8kCDml591/cO nEG7m0cI8RrKwYqrle+ubO70s60VDGZM9F9mLpkBScs3u/eaLc9ahL/EfQTCNrkA2+4isslns /NJe/PW7ySnKRPBghpIaDdJP0P+xRpvWAa1/vIKEI8hSqq4xMy01QgOI0eoiTcJ0wappiKWjG 9HQxvyHYmrnGOKisQfYckzD/nGQ= Received-SPF: pass client-ip=212.227.17.20; envelope-from=michael.albinus@gmx.de; helo=mout.gmx.net X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: 1.0 (+) 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 (/) --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable When we open a file with find-file, the minibuffer offers method, user name and host name completion for remote files. That is, after typing "C-x C-f /ss TAB" we're offered with the completions "ssh:", "sshfs:" and "sshx:". Same for user name and host name. In eshell, this feature does not exist. I would like if I could type "cd /ss TAB" and could see the same offering of "ssh:", "sshfs:" and "sshx:". Same for user name and host name. The appended patch does this for me. I have no idea how good it fits into the eshell machinery, for example whether there are problems with the em-elecslash.el module. Comments welcome! Disclaimer: The idea has appeared on . Best regards, Michael. In GNU Emacs 30.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.38, cairo version 1.17.8) of 2023-08-15 built on gandalf Repository revision: 5c101b1adac2b4f3cc4e08a6492b406952c529f3 Repository branch: master Windowing system distributor 'The X.Org Foundation', version 11.0.12201009 System Description: Fedora Linux 38 (Workstation Edition) Configured using: 'configure --with-tree-sitter' Configured features: ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GPM GSETTINGS HARFBUZZ JPEG LIBOTF LIBSELINUX LIBXML2 M17N_FLT MODULES NOTIFY INOTIFY PDUMPER PNG RSVG SECCOMP SOUND SQLITE3 THREADS TIFF TOOLKIT_SCROLL_BARS TREE_SITTER X11 XDBE XIM XINPUT2 XPM GTK3 ZLIB Important settings: value of $LANG: en_US.UTF-8 value of $XMODIFIERS: @im=3Dibus locale-coding-system: utf-8 Major mode: ELisp/l Minor modes in effect: debbugs-browse-mode: t bug-reference-prog-mode: t display-time-mode: t delete-selection-mode: t icomplete-mode: t global-goto-address-mode: t goto-address-mode: t tooltip-mode: t global-eldoc-mode: t eldoc-mode: t show-paren-mode: t electric-indent-mode: t mouse-wheel-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t column-number-mode: t line-number-mode: t transient-mark-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t Load-path shadows: /home/albinus/src/elpa/packages/debbugs/debbugs hides /home/albinus/.emacs= .d/elpa/debbugs-0.36/debbugs /home/albinus/src/elpa/packages/debbugs/debbugs-org hides /home/albinus/.e= macs.d/elpa/debbugs-0.36/debbugs-org /home/albinus/src/elpa/packages/debbugs/debbugs-gnu hides /home/albinus/.e= macs.d/elpa/debbugs-0.36/debbugs-gnu /home/albinus/src/elpa/packages/debbugs/debbugs-guix hides /home/albinus/.= emacs.d/elpa/debbugs-0.36/debbugs-guix /home/albinus/src/elpa/packages/debbugs/debbugs-browse hides /home/albinus= /.emacs.d/elpa/debbugs-0.36/debbugs-browse /home/albinus/src/elpa/packages/debbugs/debbugs-pkg hides /home/albinus/.e= macs.d/elpa/debbugs-0.36/debbugs-pkg /home/albinus/src/elpa/packages/debbugs/debbugs-autoloads hides /home/albi= nus/.emacs.d/elpa/debbugs-0.36/debbugs-autoloads /home/albinus/src/elpa/packages/debbugs/debbugs-compat hides /home/albinus= /.emacs.d/elpa/debbugs-0.36/debbugs-compat ~/lisp/telepathy hides /home/albinus/.emacs.d/elpa/telepathy-20131209.1258= /telepathy /home/albinus/src/elpa/packages/tramp-theme/tramp-theme-autoloads hides /h= ome/albinus/.emacs.d/elpa/tramp-theme-0.2/tramp-theme-autoloads /home/albinus/src/elpa/packages/tramp-theme/tramp-theme hides /home/albinu= s/.emacs.d/elpa/tramp-theme-0.2/tramp-theme /home/albinus/src/elpa/packages/tramp-theme/tramp-theme-pkg hides /home/al= binus/.emacs.d/elpa/tramp-theme-0.2/tramp-theme-pkg /home/albinus/.emacs.d/elpa/hydra-0.15.0/lv hides /home/albinus/.emacs.d/e= lpa/lv-0.15.0/lv /home/albinus/src/tramp/lisp/tramp-sh hides /usr/local/share/emacs/site-li= sp/tramp-sh /home/albinus/src/tramp/lisp/tramp-cmds hides /usr/local/share/emacs/site-= lisp/tramp-cmds /home/albinus/src/tramp/lisp/tramp-gvfs hides /usr/local/share/emacs/site-= lisp/tramp-gvfs /home/albinus/src/tramp/lisp/tramp-ftp hides /usr/local/share/emacs/site-l= isp/tramp-ftp /home/albinus/src/tramp/lisp/tramp-crypt hides /usr/local/share/emacs/site= -lisp/tramp-crypt /home/albinus/src/tramp/lisp/tramp-adb hides /usr/local/share/emacs/site-l= isp/tramp-adb /home/albinus/src/tramp/lisp/tramp hides /usr/local/share/emacs/site-lisp/= tramp /home/albinus/src/tramp/lisp/tramp-cache hides /usr/local/share/emacs/site= -lisp/tramp-cache /home/albinus/src/tramp/lisp/tramp-rclone hides /usr/local/share/emacs/sit= e-lisp/tramp-rclone /home/albinus/src/tramp/lisp/tramp-compat hides /usr/local/share/emacs/sit= e-lisp/tramp-compat /home/albinus/src/tramp/lisp/tramp-integration hides /usr/local/share/emac= s/site-lisp/tramp-integration /home/albinus/src/tramp/lisp/tramp-archive hides /usr/local/share/emacs/si= te-lisp/tramp-archive /home/albinus/src/tramp/lisp/tramp-sudoedit hides /usr/local/share/emacs/s= ite-lisp/tramp-sudoedit /home/albinus/src/tramp/lisp/tramp-loaddefs hides /usr/local/share/emacs/s= ite-lisp/tramp-loaddefs /home/albinus/src/tramp/lisp/tramp-uu hides /usr/local/share/emacs/site-li= sp/tramp-uu /home/albinus/src/tramp/lisp/tramp-smb hides /usr/local/share/emacs/site-l= isp/tramp-smb /home/albinus/src/tramp/lisp/trampver hides /usr/local/share/emacs/site-li= sp/trampver /home/albinus/.emacs.d/elpa/transient-20230602.2121/transient hides /usr/l= ocal/share/emacs/30.0.50/lisp/transient ~/lisp/dbus hides /usr/local/share/emacs/30.0.50/lisp/net/dbus /home/albinus/src/tramp/lisp/tramp-sh hides /usr/local/share/emacs/30.0.50= /lisp/net/tramp-sh /home/albinus/src/tramp/lisp/tramp-fuse hides /usr/local/share/emacs/30.0.= 50/lisp/net/tramp-fuse /home/albinus/src/tramp/lisp/tramp-loaddefs hides /usr/local/share/emacs/3= 0.0.50/lisp/net/tramp-loaddefs /home/albinus/src/tramp/lisp/tramp-ftp hides /usr/local/share/emacs/30.0.5= 0/lisp/net/tramp-ftp /home/albinus/src/tramp/lisp/tramp hides /usr/local/share/emacs/30.0.50/li= sp/net/tramp /home/albinus/src/tramp/lisp/tramp-cache hides /usr/local/share/emacs/30.0= .50/lisp/net/tramp-cache /home/albinus/src/tramp/lisp/tramp-uu hides /usr/local/share/emacs/30.0.50= /lisp/net/tramp-uu /home/albinus/src/tramp/lisp/tramp-rclone hides /usr/local/share/emacs/30.= 0.50/lisp/net/tramp-rclone /home/albinus/src/tramp/lisp/tramp-integration hides /usr/local/share/emac= s/30.0.50/lisp/net/tramp-integration /home/albinus/src/tramp/lisp/tramp-archive hides /usr/local/share/emacs/30= .0.50/lisp/net/tramp-archive /home/albinus/src/tramp/lisp/tramp-adb hides /usr/local/share/emacs/30.0.5= 0/lisp/net/tramp-adb /home/albinus/src/tramp/lisp/tramp-cmds hides /usr/local/share/emacs/30.0.= 50/lisp/net/tramp-cmds /home/albinus/src/tramp/lisp/tramp-compat hides /usr/local/share/emacs/30.= 0.50/lisp/net/tramp-compat /home/albinus/src/tramp/lisp/tramp-sudoedit hides /usr/local/share/emacs/3= 0.0.50/lisp/net/tramp-sudoedit /home/albinus/src/tramp/lisp/tramp-container hides /usr/local/share/emacs/= 30.0.50/lisp/net/tramp-container /home/albinus/src/tramp/lisp/tramp-gvfs hides /usr/local/share/emacs/30.0.= 50/lisp/net/tramp-gvfs /home/albinus/src/tramp/lisp/tramp-crypt hides /usr/local/share/emacs/30.0= .50/lisp/net/tramp-crypt /home/albinus/src/tramp/lisp/tramp-message hides /usr/local/share/emacs/30= .0.50/lisp/net/tramp-message /home/albinus/src/tramp/lisp/tramp-smb hides /usr/local/share/emacs/30.0.5= 0/lisp/net/tramp-smb /home/albinus/src/tramp/lisp/trampver hides /usr/local/share/emacs/30.0.50= /lisp/net/trampver /home/albinus/src/tramp/lisp/tramp-sshfs hides /usr/local/share/emacs/30.0= .50/lisp/net/tramp-sshfs Features: (shadow sort mail-extr warnings emacsbug message yank-media puny rfc822 mml mml-sec epa derived epg rfc6068 epg-config gnus-util mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils cl-print cl-extra find-func shortdoc em-xtra em-unix em-tramp em-term term disp-table ehelp em-script em-prompt em-pred em-ls em-hist em-glob em-cmpl em-dirs em-basic em-banner em-alias esh-mode esh-var eshell esh-cmd generator esh-ext esh-opt esh-proc esh-io esh-arg esh-module esh-groups esh-util help-fns radix-tree mule-util display-line-numbers pulse color find-dired xref project grep compile text-property-search misearch multi-isearch ediff-vers ediff ediff-merg ediff-mult ediff-wind ediff-diff ediff-help ediff-init ediff-util vc-git diff-mode easy-mmode debbugs-browse bug-reference dired-aux face-remap ob-shell ob ob-tangle ol org-src ob-ref ob-lob ob-table ob-exp ob-comint ob-core org-cycle org-fold org-fold-core ob-eval org-keys oc org-compat org-version org-macs vc vc-dispatcher time tramp-cache time-stamp tramp-sh lxc-tramp lxd-tramp tramp trampver tramp-integration files-x tramp-message help-mode tramp-compat xdg shell pcomplete comint ansi-osc ring parse-time iso8601 time-date format-spec ansi-color tramp-loaddefs rx delsel ido jka-compr icomplete cus-edit pp cus-load icons wid-edit dired dired-loaddefs goto-addr thingatpt alert-autoloads android-mode-autoloads auth-source-gopass-autoloads auth-source-keytar-autoloads auth-source-kwallet-autoloads auth-source-xoauth2-autoloads auto-sudoedit-autoloads auto-virtualenv-autoloads auto-virtualenvwrapper-autoloads clang-format-autoloads company-shell-autoloads company-autoloads counsel-toki-autoloads counsel-tramp-autoloads counsel-autoloads dbus-codegen-autoloads debbugs-autoloads dired-du-autoloads dired-rsync-autoloads direnv-autoloads disk-usage-autoloads dockerfile-mode-autoloads ednc-autoloads el-get-autoloads envrc-autoloads exec-path-from-shell-autoloads fontaine-autoloads forge-autoloads closql-autoloads emacsql-autoloads friendly-tramp-path-autoloads ggtags-autoloads ghub-autoloads gited-autoloads gitlab-ci-mode-flycheck-autoloads gitlab-ci-mode-autoloads flycheck-autoloads gntp-autoloads gnus-desktop-notify-autoloads helm-gitlab-autoloads helm-projectile-autoloads helm-autoloads helm-core-autoloads async-autoloads ibuffer-tramp-autoloads inheritenv-autoloads ivy-gitlab-autoloads gitlab-autoloads jarchive-autoloads journalctl-mode-autoloads keepass-mode-autoloads keytar-autoloads kubel-autoloads kubernetes-autoloads log4e-autoloads lsp-java-autoloads dap-mode-autoloads lsp-docker-autoloads bui-autoloads lsp-treemacs-autoloads lsp-mode-autoloads lxc-tramp-autoloads lxd-tramp-autoloads magit-filenotify-autoloads magit-autoloads pcase git-commit-autoloads magit-popup-autoloads magit-section-autoloads marcopolo-autoloads nexus-autoloads nnir-est-autoloads oauth2-autoloads ob-restclient-autoloads orderless-autoloads org-tree-slide-autoloads pkg-info-autoloads epl-autoloads popup-autoloads projectile-autoloads promise-autoloads pyenv-mode-autoloads pylint-autoloads python-environment-autoloads deferred-autoloads pythonic-autoloads f-autoloads pyvenv-autoloads recentf-remove-sudo-tramp-prefix-autoloads relint-autoloads request-autoloads restclient-test-autoloads restclient-autoloads s3ed-autoloads finder-inf slime-autoloads macrostep-autoloads spinner-autoloads ssh-deploy-autoloads swiper-autoloads ivy-autoloads sx-autoloads markdown-mode-autoloads telepathy-autoloads tramp-theme-autoloads transient-dwim-autoloads transient-autoloads treemacs-autoloads cfrs-autoloads posframe-autoloads ht-autoloads pfuture-autoloads ace-window-autoloads avy-autoloads treepy-autoloads urgrep-autoloads uuid-autoloads vdiff-autoloads hydra-autoloads lv-autoloads vertico-autoloads virtualenv-autoloads virtualenvwrapper-autoloads s-autoloads dash-autoloads web-server-autoloads with-editor-autoloads info compat-autoloads xr-autoloads yaml-autoloads yaml-mode-autoloads package browse-url url url-proxy url-privacy url-expand url-methods url-history url-cookie generate-lisp-file url-domsuf url-util mailcap url-handlers url-parse auth-source cl-seq eieio eieio-core cl-macs password-cache json subr-x map byte-opt gv bytecomp byte-compile url-vars cl-loaddefs cl-lib rmc iso-transl tooltip cconv eldoc paren electric uniquify ediff-hook vc-hooks lisp-float-type elisp-mode mwheel term/x-win x-win term/common-win x-dnd touch-screen tool-bar dnd fontset image regexp-opt fringe tabulated-list replace newcomment text-mode lisp-mode prog-mode register page tab-bar menu-bar rfn-eshadow isearch easymenu timer select scroll-bar mouse jit-lock font-lock syntax font-core term/tty-colors frame minibuffer nadvice seq simple cl-generic indonesian philippine cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese composite emoji-zwj charscript charprop case-table epa-hook jka-cmpr-hook help abbrev obarray oclosure cl-preloaded button loaddefs theme-loaddefs faces cus-face macroexp files window text-properties overlay sha1 md5 base64 format env code-pages mule custom widget keymap hashtable-print-readable backquote threads dbusbind inotify dynamic-setting system-font-setting font-render-setting cairo gtk x-toolkit xinput2 x multi-tty move-toolbar make-network-process emacs) Memory information: ((conses 16 234759 52920) (symbols 48 19742 1) (strings 32 66564 4085) (string-bytes 1 2281459) (vectors 16 40066) (vector-slots 8 1166864 141729) (floats 8 244 2758) (intervals 56 11249 545) (buffers 992 27)) --=-=-= Content-Type: text/x-patch Content-Disposition: attachment Content-Transfer-Encoding: quoted-printable diff --git a/lisp/eshell/em-tramp.el b/lisp/eshell/em-tramp.el index 94eb9797033..c90e689f6de 100644 =2D-- a/lisp/eshell/em-tramp.el +++ b/lisp/eshell/em-tramp.el @@ -51,11 +51,23 @@ eshell-tramp-initialize "Initialize the Tramp-using commands code." (when (eshell-using-module 'eshell-cmpl) (add-hook 'pcomplete-try-first-hook - 'eshell-complete-host-reference nil t)) + 'eshell-complete-partial-tramp-file-name)) (setq-local eshell-complex-commands (append '("su" "sudo" "doas") eshell-complex-commands))) +(defun eshell-complete-partial-tramp-file-name () + "Complete a partial Tramp file name (method, user name, hostname)." + (let ((arg (pcomplete-actual-arg)) + (non-essential t) + (minibuffer-completing-file-name t)) + (when (string-match tramp-completion-file-name-regexp arg) + (setq pcomplete-stub (substring arg (length tramp-prefix-format)) + pcomplete-last-completion-raw t + pcomplete-termination-string "") + (throw 'pcomplete-completions + (file-name-all-completions pcomplete-stub tramp-prefix-forma= t))))) + (autoload 'eshell-parse-command "esh-cmd") (defun eshell/su (&rest args) --=-=-=-- From unknown Thu Aug 14 22:23:05 2025 X-Loop: help-debbugs@gnu.org Subject: bug#65356: 30.0.50; [wishlist] Support Tramp method, user name and host name completion in eshell Resent-From: Jim Porter Original-Sender: "Debbugs-submit" Resent-CC: monnier@iro.umontreal.ca, bug-gnu-emacs@gnu.org Resent-Date: Fri, 18 Aug 2023 03:33:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65356 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Michael Albinus , 65356@debbugs.gnu.org Cc: monnier@iro.umontreal.ca X-Debbugs-Original-Xcc: monnier@iro.umontreal.ca Received: via spool by 65356-submit@debbugs.gnu.org id=B65356.16923295274574 (code B ref 65356); Fri, 18 Aug 2023 03:33:01 +0000 Received: (at 65356) by debbugs.gnu.org; 18 Aug 2023 03:32:07 +0000 Received: from localhost ([127.0.0.1]:45818 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qWqDW-0001Bh-Lv for submit@debbugs.gnu.org; Thu, 17 Aug 2023 23:32:06 -0400 Received: from mail-pl1-x62f.google.com ([2607:f8b0:4864:20::62f]:56529) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qWqDS-0001BA-3g for 65356@debbugs.gnu.org; Thu, 17 Aug 2023 23:32:05 -0400 Received: by mail-pl1-x62f.google.com with SMTP id d9443c01a7336-1bc8a2f71eeso3792625ad.0 for <65356@debbugs.gnu.org>; Thu, 17 Aug 2023 20:32:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1692329516; x=1692934316; h=content-transfer-encoding:in-reply-to:from:references:to :content-language:subject:mime-version:date:message-id:from:to:cc :subject:date:message-id:reply-to; bh=Zktv2YcNvhODSC6oOBH/7CIXwc9xJJkdkwucoXJOvmE=; b=GUYizW2JwIhhesDTLRtYE4UBkKKwi9lfTcwDODlS2DzhdEpQ1hduKcu/n69FDetOzV PDufTDSMCUlIP4hrA/EOqIKKYMRF87nJwBLOJ2OLyCWXPxeNhdRU92d4fgXpMWvzyXpn Vys8Iy0S/fuJu8QcJMztLvSAyVTKWDsKNWm4O2p5aBv7kYRTfSHXXAh1TLcL6iD1h2Hz 48gdkDENXTC4HZ5wCxU3LGj2JLjM/CdmT6sUl+Od2EyDnPtzYLOlwbpRB2bV+KLPCttU 68yov+ZLUofu+OZZxyRxeKMvUxP54AiutFQq2vxIHOPI0kFmRZh9gGCa91ctnFd8J50C QaVQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1692329516; x=1692934316; h=content-transfer-encoding:in-reply-to:from:references:to :content-language:subject:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=Zktv2YcNvhODSC6oOBH/7CIXwc9xJJkdkwucoXJOvmE=; b=RBvVFvD2cYyNDAHJEiCz4N6LixgOcTV1QBhiybk4ZZkxSLaZIufEgpXaNnIqD1l1/L cqM+q5Vl8lM2eyfX7UsEaB51zZ4Q3DDRoNUsnUtWT+f8+KwJm98UJZVDm261B7J562j7 OtxAYrRKnu2aR+FwWJ+g5dP0CXLWrBh3pS5YOo1u6LiRB0Rmcp+ZwBB4x2KcPACGHRR0 ZMRe3cp1Iww/p9NqoYo0AvLNSTM+VJ2SiLcUdEtYh/GRKmPlx2ANLYBpe2U8l2lAAy4T fF0/5Qv6unmVoLzi9lVC75fd7+X8f7imWwKDmrFXO6P7pmI6xhrJihKlhg0zaAYz7hNL j7cw== X-Gm-Message-State: AOJu0Yx59FQJ3lFkk2pWm86kkJqeJMXoSsBj+yP5ghpW3ghLn4JnawFE x8O7iaQP8DNPXO55RiFXZes= X-Google-Smtp-Source: AGHT+IFVACzhxg8+mFbVuIbBDiu1v03dT8aQRE2WbXQkkNREDBE2kyJNQeWMO14cSM3VYzeYrUyajQ== X-Received: by 2002:a17:902:ab49:b0:1bc:50f9:8f20 with SMTP id ij9-20020a170902ab4900b001bc50f98f20mr1232843plb.23.1692329515601; Thu, 17 Aug 2023 20:31:55 -0700 (PDT) Received: from [192.168.1.2] (cpe-76-168-148-233.socal.res.rr.com. [76.168.148.233]) by smtp.googlemail.com with ESMTPSA id l20-20020a170903005400b001bdcafcf8d3sm536763pla.69.2023.08.17.20.31.54 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 17 Aug 2023 20:31:54 -0700 (PDT) Message-ID: <4b4a64de-846a-ed2a-f409-80ea75e9cb57@gmail.com> Date: Thu, 17 Aug 2023 20:31:54 -0700 MIME-Version: 1.0 Content-Language: en-US References: <87r0o1r1io.fsf@gmx.de> From: Jim Porter In-Reply-To: <87r0o1r1io.fsf@gmx.de> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: 0.0 (/) 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 (-) X-Debbugs-Cc: monnier@iro.umontreal.ca On 8/17/2023 11:01 AM, Michael Albinus wrote: > In eshell, this feature does not exist. I would like if I could type > "cd /ss TAB" and could see the same offering of "ssh:", "sshfs:" and > "sshx:". Same for user name and host name. > > The appended patch does this for me. I have no idea how good it fits > into the eshell machinery, for example whether there are problems with > the em-elecslash.el module. Comments welcome! Thanks. This would be a useful feature indeed. I have a couple of main concerns, which I'm not quite sure what to do about at the moment: 1) Should this go in the Eshell Tramp extension module? Currently, that module is there to add built-in versions of su/sudo/doas, as an alternative to the "standard" Eshell way of connecting to a remote host: "cd /ssh:user@host:~". Therefore, I think we'd want tab-completion of Tramp file names even (or especially!) when the Tramp extension module is disabled (which is the default). 2) I'm not sure 'pcomplete-try-first-hook' is the right way to enable this. Pcomplete has quite a few ways of performing completions, and it already knows when it should specifically complete file names (as opposed to "--options" for example). Maybe we should enhance Pcomplete itself so that you can opt into completion of remote file names too? Then when you tab-complete in Eshell, it would just work in all the contexts where you can normally complete a file name. I Cc'ed Stefan since he might have some thoughts on the Pcomplete machinery here. From unknown Thu Aug 14 22:23:05 2025 X-Loop: help-debbugs@gnu.org Subject: bug#65356: 30.0.50; [wishlist] Support Tramp method, user name and host name completion in eshell Resent-From: Michael Albinus Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 18 Aug 2023 06:46:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65356 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Jim Porter Cc: 65356@debbugs.gnu.org, monnier@iro.umontreal.ca Received: via spool by 65356-submit@debbugs.gnu.org id=B65356.16923411423643 (code B ref 65356); Fri, 18 Aug 2023 06:46:02 +0000 Received: (at 65356) by debbugs.gnu.org; 18 Aug 2023 06:45:42 +0000 Received: from localhost ([127.0.0.1]:46008 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qWtEr-0000wg-PH for submit@debbugs.gnu.org; Fri, 18 Aug 2023 02:45:42 -0400 Received: from mout.gmx.net ([212.227.17.20]:53097) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qWtEo-0000wK-3P for 65356@debbugs.gnu.org; Fri, 18 Aug 2023 02:45:41 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.de; s=s31663417; t=1692341128; x=1692945928; i=michael.albinus@gmx.de; bh=pWPRte2j60DHNv2cMGAB0C6vhD3rox2ESkGMLpaexMo=; h=X-UI-Sender-Class:From:To:Cc:Subject:In-Reply-To:References:Date; b=XRCcX0GyoZq1ftGYxFg08IN9EWgckPlm+rYjY0KIxZ4DKpGYG8/eFTAM3yKLfWk5Rwa8U1x sSuEVfQKM76jV7SrRXkTTJnHejGjT5sV0BMN279ZHW4A2tIiy8E3b/v77RWZpsH31mg+n76Lz MEN+nbcM1rEgX/jD/1iMxf54X/7QJVLvMpc3rM5ZKuqaFxj2Hmjr6jD+5469+GlwuHCicEJ2T gydv41ZRO/86Hv+s88zjtLJPeBl/xyRuHCrgt8E2lBml4HLI/Cg363Vn8JvIGJjGT8yk8OcqJ wCnV0GkedEDlvWuhQlU2wGAHsYAF66bAPnHIOkQF62KQkeG/5Btg== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Received: from gandalf.gmx.de ([185.89.39.27]) by mail.gmx.net (mrgmx104 [212.227.17.168]) with ESMTPSA (Nemesis) id 1M3DNt-1qTKKb0ggv-003a7H; Fri, 18 Aug 2023 08:45:28 +0200 From: Michael Albinus In-Reply-To: <4b4a64de-846a-ed2a-f409-80ea75e9cb57@gmail.com> (Jim Porter's message of "Thu, 17 Aug 2023 20:31:54 -0700") References: <87r0o1r1io.fsf@gmx.de> <4b4a64de-846a-ed2a-f409-80ea75e9cb57@gmail.com> Date: Fri, 18 Aug 2023 08:45:26 +0200 Message-ID: <87il9crgqh.fsf@gmx.de> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K1:661jpZDyeC9VELBDu+n03W2ykAo6dKL8X/hSJL1/DIh4Iobc+UX MD9dG4xAj1puoVJVetOZNzEwflCRaNQvY5MEZZarZDhHSbWDqSY8qtYrkj0FckZDk0YpYQB iyatHYwUMLa5cgR7MANdABK10HffqqSJ+s8Y9j0TnpslorvcI52gEnqksOLo/H/l4Q3kIOd c8a00AEBk8gUyHfnSq+sA== X-Spam-Flag: NO UI-OutboundReport: notjunk:1;M01:P0:CV5R39rwTGs=;qIQ8F9eBzi7W4bHR4A9QdOWM1Xo 1gb0qOznvl3Bh+JWmsf+Xp6el32xEt9r9RBWb945YIajUlJzeCCIam44E5oDNTHCHEuNIHLVM DkH+1N/Tp5QA2pKPzehmK/ITlUbWz/ZPKl44/GC5yzQUqzysgR3/L4YIziFxQ28OyJT4yk1EE Z93Z2SZoh0YScLBKa5Lq1w52C5yGtb44TmeLQ7v3nXHxnv8oph7OMcKk6/EIMUyhYY4ioNlKl 7WgzOlfFUZ/94y4KHkR1Eo7L7aKJwiNoyhP2rKCeTqF2ilCLNOlL7XkCFheQX3/0UTDiBaT3e Ps6TNHegCmGFwzhnidyRbCHEW1RuDbRkKoS1P/NpC46WtCCKnxmwQeSyihKXm9CzUBJGJmXRd VdIxmXVYKfvoMsmJXMphbt+Q76EQ/zBvaHkf4d+hXdwGEKBwrYs7DTHlqD4MLDr9NylyPYfvf aO+04jwsFZCJaxV5GQHfJh8DZ7AK3X+KgKoGvpxCTXeqgVIK15GZIf0Cqqo4ZAwt3nykseD5i zYGIzXswIduCwN95LNGmqEfXGyGik008EEuMNFW0NA/REgMFNbXWIvXU4DzYzhf16WbiNz0Gj JxCT8VkLyTpEh9KChykDPaZ9ApbTQQVXEtQr/ZzxzaS6gnGQ2O4PSXeiAMfQJ9ee9/qFR8Vfs 9blfKuCpQVC7GMI4gqsd5H2WEeBQgKogQRo0b33DzTXyqDXptbyUwclAa3L4Si/K0qvYgt0/3 3a8Hv8/TvM5MTatZZyd57pLE8YsbaePwdxfCcfU8BmVMvWhyXiyf3E2POCAxtMkL8ye8qSlmv E+MqH/8FrQAI6zDByONeBPETp9vExMYRU6eaXBAaRB5vMdW3V1j21bEe9SDh2GtX4bX3iOlph yt6QYbuMMiUcPxIjNDB3eq18YgwVixLDQwizHalPFO/AkCz6vaWiUSAVh3FPSjOVoDXV1E7sf I++Pn5n+L69IT6+a5VgDkcPWtXA= X-Spam-Score: -0.7 (/) 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.7 (-) Jim Porter writes: Hi Jim, > X-Debbugs-Cc: monnier@iro.umontreal.ca Well, this works only if you *submit* a new bug. If you *reply*, just use Cc. I've added Stefan in this reply. >> In eshell, this feature does not exist. I would like if I could type >> "cd /ss TAB" and could see the same offering of "ssh:", "sshfs:" and >> "sshx:". Same for user name and host name. >> >> The appended patch does this for me. I have no idea how good it fits >> into the eshell machinery, for example whether there are problems with >> the em-elecslash.el module. Comments welcome! > > Thanks. This would be a useful feature indeed. I have a couple of main > concerns, which I'm not quite sure what to do about at the moment: > > 1) Should this go in the Eshell Tramp extension module? Currently, > that module is there to add built-in versions of su/sudo/doas, as an > alternative to the "standard" Eshell way of connecting to a remote > host: "cd /ssh:user@host:~". Therefore, I think we'd want > tab-completion of Tramp file names even (or especially!) when the > Tramp extension module is disabled (which is the default). I have no preference where it shall be in eshell. I've used em-tramp.el during my work, because it is the least invasive place: it requires already Tramp. You might have seen, that the new function uses two Tramp variables. > 2) I'm not sure 'pcomplete-try-first-hook' is the right way to enable > this. Pcomplete has quite a few ways of performing completions, and it > already knows when it should specifically complete file names (as > opposed to "--options" for example). Maybe we should enhance Pcomplete > itself so that you can opt into completion of remote file names too? > Then when you tab-complete in Eshell, it would just work in all the > contexts where you can normally complete a file name. I Cc'ed Stefan > since he might have some thoughts on the Pcomplete machinery here. When I've started to implement this, I was a n00b wrt pcomplete. Well, I'm still a n00b, all what I have done is stealing code from somewhere else, shamelessly. It would be great if this completion function applies only to possible *Lisp* file names. Roughly said, to arguments of commands not being external, and not in a pipe. If this could be arranged I'd appreciate it. So I count on you and Stefan :-) Best regards, Michael. From unknown Thu Aug 14 22:23:05 2025 X-Loop: help-debbugs@gnu.org Subject: bug#65356: 30.0.50; [wishlist] Support Tramp method, user name and host name completion in eshell Resent-From: Michael Albinus Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 18 Aug 2023 11:44:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65356 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Jim Porter Cc: 65356@debbugs.gnu.org, monnier@iro.umontreal.ca Received: via spool by 65356-submit@debbugs.gnu.org id=B65356.169235903712675 (code B ref 65356); Fri, 18 Aug 2023 11:44:02 +0000 Received: (at 65356) by debbugs.gnu.org; 18 Aug 2023 11:43:57 +0000 Received: from localhost ([127.0.0.1]:46204 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qWxtU-0003IM-JU for submit@debbugs.gnu.org; Fri, 18 Aug 2023 07:43:56 -0400 Received: from mout.gmx.net ([212.227.17.22]:60915) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qWxtS-0003I8-9F for 65356@debbugs.gnu.org; Fri, 18 Aug 2023 07:43:55 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.de; s=s31663417; t=1692359024; x=1692963824; i=michael.albinus@gmx.de; bh=2NdLQ81Bbf4+5Y8Fi0Oiso0m/pyiA3amb2jlarr5D34=; h=X-UI-Sender-Class:From:To:Cc:Subject:In-Reply-To:References:Date; b=f4Xqgf84K8z019xYW3brq1tpbkyaIFXz7lgcIve3Li8eyM3vZbRyqCwlY1ZYxyc9dkZNE8l 4b/8+t6jmQ/JfiapG1rX0BzBMt1wsljEvQt1EychZyP2ncee+xtBRDq+MSeHwJ2C7eKNE40yF 4v2EPbU64ArQxWMDLcxxgGHm2+imzAYfU+BNXNOb+IHM1k9i+ys6b9MXCWYH3C3uh5NffvnTS AX87fyW3Q+r4iRpaqCSt/WlI2snbzReIA5Lz6iMjUqdWyg71l9ON9/4cGDlnPuvGG1czMbKNB WFwJi80GK4Y/P4PPtBvcYGhvi2Z6qGz1NZUqkZ4LsNDNospA8hlA== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Received: from gandalf.gmx.de ([185.89.39.27]) by mail.gmx.net (mrgmx104 [212.227.17.168]) with ESMTPSA (Nemesis) id 1MYeR1-1qItFE3nmd-00Vl4Y; Fri, 18 Aug 2023 13:43:44 +0200 From: Michael Albinus In-Reply-To: <87il9crgqh.fsf@gmx.de> (Michael Albinus's message of "Fri, 18 Aug 2023 08:45:26 +0200") References: <87r0o1r1io.fsf@gmx.de> <4b4a64de-846a-ed2a-f409-80ea75e9cb57@gmail.com> <87il9crgqh.fsf@gmx.de> Date: Fri, 18 Aug 2023 13:43:42 +0200 Message-ID: <87bkf4r2xd.fsf@gmx.de> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K1:94Fr7bzAqOQrM+9VxphANdwCy7q9VzHaC/eE7DeDLII/1qa8q/9 kj1LoqOZhw6OOsUEyiDT2Rs/rIE63TWmlPvtgXfJdFA0RXSF7WsvHwF7+I6TtE6QxdhtxC4 ILofjK/m1LdpQkPc0JDyWbCSB9BNzjyMUpfsLmkk+cPdQKlFLJ5DEURfq89vhbwtkRLZJpg Ki6edlxYx3HTJ4bDuAK7g== X-Spam-Flag: NO UI-OutboundReport: notjunk:1;M01:P0:tyo1g+Cah24=;ombeZNtq199yYQo64a2+RKJDLli at3jxKklGf9mEs0R1gVQnIrabpkRs414dnZQOH7ovFof1PsveahCxEEO88poUr7kHNTTKuQ7/ 3sWUxO3xymFx+j+JQIjNk5reRwJhbbPXvPdOpr/C2+q3OkOwHJmBjMCQkKRQ4OzQpfpnvvpc6 kFQiPu4NT+/Z8CJ+FJ/gewPCF2VZ17vcIjJkdcFcDRwdvoZMRYv5HRHttxKZS99Kn8sKZg4zo /qiVrNi/6Ns1TDlU1yv/NccPD6tEaMvVgu1OcgfVfWwdALNkqwLueB2oF/fNsB4hH/i7ufWql CeaiMYXIoSEJx8ybB+mXN5NbcgKQPJC15guOpDp5+ov4CWO5WrbHnx4nBZ0wRKuoSGKvQ2sEH mfOsnf2EMZ46ZFnJIfxVD2jmqSPlzi/MuOSEveaHVPsJObx5ibtxYzejBOCpTta+l/xvcI/T5 N/92lQl763L+kv47rGl1rC2uE6yraoOW5qNUTsUATOVsbSHMFh7FI9SXoiXcaOXx/3majBZvp 6qR2QYyqQU9hWgtEJ7QT61bm38ZnFGQ9UJHgpwIOYWR0BTbpSKh8VYZ50R9jNw/tNudMHR2C4 bju/8xsClS63SMrhJVYCzutAUQ/bFabWP6uEAWGHp14kh6OAxIHEZDq+lCZ1+cXTF0DxOudoI OGX6J5WwibFPoh2LEKClL3nX2Wj1wlKLuTc9sAPQ1CcLeTjg3diBAhqNSt5WHie3L+fm7G+1P wnByRpFA74idwAV78A6DPhul/QLxFmUmJEHPEGpzCAodE3NYruCpVVVmUmWuyLN/VCQZbwUmQ HmSII8St1MhOLgf3EBM0KMnJpff6t8yR4E+LkGYRvFluE0OJpD350fps1oMEIXMHBLy4kc6yV OP6HlhPJ7GSYwQN5Kl4Zxjhb7q/9UfIYOTd59WNBPc0udOCITJmhsdm5D8lDxhGMfpnybMUWA dwgO8Q== X-Spam-Score: -0.7 (/) 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.7 (-) Michael Albinus writes: Hi Jim, >> 2) I'm not sure 'pcomplete-try-first-hook' is the right way to enable >> this. Pcomplete has quite a few ways of performing completions, and it >> already knows when it should specifically complete file names (as >> opposed to "--options" for example). Maybe we should enhance Pcomplete >> itself so that you can opt into completion of remote file names too? >> Then when you tab-complete in Eshell, it would just work in all the >> contexts where you can normally complete a file name. I Cc'ed Stefan >> since he might have some thoughts on the Pcomplete machinery here. > > When I've started to implement this, I was a n00b wrt pcomplete. Well, > I'm still a n00b, all what I have done is stealing code from somewhere > else, shamelessly. > > It would be great if this completion function applies only to possible > *Lisp* file names. Roughly said, to arguments of commands not being > external, and not in a pipe. If this could be arranged I'd appreciate > it. So I count on you and Stefan :-) I've digged further. Perhaps, we don't need to plug into eshell. It could be sufficient to teach pcomplete. First, we need a completion table for Tramp prefixes. Like --8<---------------cut here---------------start------------->8--- (defun pcomplete-tramp () "Completion table for partial Tramp file names." (completion-table-dynamic (lambda (string) (when (string-match-p tramp-completion-file-name-regexp string) (mapcar (lambda (x) (concat tramp-prefix-format x)) (let ((non-essential t) (minibuffer-completing-file-name t)) (file-name-all-completions string tramp-prefix-format))))))) --8<---------------cut here---------------end--------------->8--- We could use this table to pimp up (existing) pcomplete functions for builtin commands, like --8<---------------cut here---------------start------------->8--- (defun pcomplete/cd () "Completion for `cd'." (while (pcomplete-here (completion-table-in-turn (pcomplete-tramp) (pcomplete-dirs))))) --8<---------------cut here---------------end--------------->8--- WDYT? Best regards, Michael. From unknown Thu Aug 14 22:23:05 2025 X-Loop: help-debbugs@gnu.org Subject: bug#65356: 30.0.50; [wishlist] Support Tramp method, user name and host name completion in eshell Resent-From: Stefan Monnier Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 18 Aug 2023 13:26:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65356 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Michael Albinus Cc: Jim Porter , 65356@debbugs.gnu.org Received: via spool by 65356-submit@debbugs.gnu.org id=B65356.169236515223444 (code B ref 65356); Fri, 18 Aug 2023 13:26:02 +0000 Received: (at 65356) by debbugs.gnu.org; 18 Aug 2023 13:25:52 +0000 Received: from localhost ([127.0.0.1]:46373 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qWzU8-000664-79 for submit@debbugs.gnu.org; Fri, 18 Aug 2023 09:25:52 -0400 Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:50755) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qWzU6-00065n-Kx for 65356@debbugs.gnu.org; Fri, 18 Aug 2023 09:25:51 -0400 Received: from pmg2.iro.umontreal.ca (localhost.localdomain [127.0.0.1]) by pmg2.iro.umontreal.ca (Proxmox) with ESMTP id 39A6680762; Fri, 18 Aug 2023 09:25:44 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1692365142; bh=AjKp/BMKMVPIJEsd7BhJaXhTEFtEJmOfVQdlxlLF/ts=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=eO+ugKxKEL7gJA8JvOk5g6xtEM/WjiCui//vc6JdR9Ib4L2V8rSkf/cjBzV88Zsti gL0voV6UlH9aFyT+atoOisTQbfbYBoMiNqO7GMcY/AEDeYHVF2LxxwqZ1aWkcWnMas YSaJtFlfBh/QBM3Sy7ii9G9zCLSwy7BbGfOrZAGX1Jhs4iv1HSFCpGTtVYPgDZQJ1Z SFplTBvsvC+0vbsfQYhBci+D2WvguCb3Fyn3WtWWTcBnRjq+w0le4t1bwYT94HekAT affrBjl2Hr2KmTXRCIqaYh9AvB8tXxO5cjyZnh3tpp9y7J5EqYJxENdyL4L+YplI8/ QBrYCWyGLxYhg== Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg2.iro.umontreal.ca (Proxmox) with ESMTP id E5A8E80448; Fri, 18 Aug 2023 09:25:42 -0400 (EDT) Received: from pastel (unknown [45.72.228.154]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id B67A812023C; Fri, 18 Aug 2023 09:25:42 -0400 (EDT) From: Stefan Monnier In-Reply-To: <87bkf4r2xd.fsf@gmx.de> (Michael Albinus's message of "Fri, 18 Aug 2023 13:43:42 +0200") Message-ID: References: <87r0o1r1io.fsf@gmx.de> <4b4a64de-846a-ed2a-f409-80ea75e9cb57@gmail.com> <87il9crgqh.fsf@gmx.de> <87bkf4r2xd.fsf@gmx.de> Date: Fri, 18 Aug 2023 09:25:42 -0400 User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-SPAM-INFO: Spam detection results: 0 ALL_TRUSTED -1 Passed through trusted hosts only via SMTP AWL 0.024 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DKIM_SIGNED 0.1 Message has a DKIM or DK signature, not necessarily valid DKIM_VALID -0.1 Message has at least one valid DKIM or DK signature DKIM_VALID_AU -0.1 Message has a valid DKIM or DK signature from author's domain DKIM_VALID_EF -0.1 Message has a valid DKIM or DK signature from envelope-from domain X-SPAM-LEVEL: X-Spam-Score: -2.3 (--) 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: -3.3 (---) > --8<---------------cut here---------------start------------->8--- > (defun pcomplete/cd () > "Completion for `cd'." > (while (pcomplete-here (completion-table-in-turn > (pcomplete-tramp) > (pcomplete-dirs))))) > --8<---------------cut here---------------end--------------->8--- AFIK this applies to `M-x shell` as well, so it doesn't seem quite right. Stefan From unknown Thu Aug 14 22:23:05 2025 X-Loop: help-debbugs@gnu.org Subject: bug#65356: 30.0.50; [wishlist] Support Tramp method, user name and host name completion in eshell Resent-From: Michael Albinus Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 18 Aug 2023 15:13:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65356 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Stefan Monnier Cc: Jim Porter , 65356@debbugs.gnu.org Received: via spool by 65356-submit@debbugs.gnu.org id=B65356.169237156925470 (code B ref 65356); Fri, 18 Aug 2023 15:13:01 +0000 Received: (at 65356) by debbugs.gnu.org; 18 Aug 2023 15:12:49 +0000 Received: from localhost ([127.0.0.1]:48515 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qX19d-0006cf-Gj for submit@debbugs.gnu.org; Fri, 18 Aug 2023 11:12:49 -0400 Received: from mout.gmx.net ([212.227.17.20]:42601) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qX19Z-0006cL-Ai for 65356@debbugs.gnu.org; Fri, 18 Aug 2023 11:12:46 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.de; s=s31663417; t=1692371555; x=1692976355; i=michael.albinus@gmx.de; bh=JuqPAjUnci65F0DHu/J7q6uGoJPTt/ouHek4pw/KF8A=; h=X-UI-Sender-Class:From:To:Cc:Subject:In-Reply-To:References:Date; b=Vq3vpsQJ4Aj8GowbCXBB4KYQ0FILzJWvlYHSG2sud3+X5S//SfXPZIo+r9N2bnGSO+KfgoD GCOGyPm76nXEYmzHHeAOnVwYH5YURCMgbIwY4zul+AEb7fZMdi6uEwHDJZfZUGwqWJ4Qt8eBI IBbIIY1cflvp0i7F4qNHD8xqfh3V09ORvlFJiZHGGsuPDTvl6Lq/8mxZ0pLWZuzZTJu9dBaSd ArfYqBgNZlig63eZ+Ef4+3fpQxQz+fNA8ZbIvT+606l6cdLq57JoMvpLuLJJFC1OGaFEoBVsU aCLYyNPMse9KbFPayCbYoq1guJoO2dVEdn4SKZw2X8zK70vb64lA== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Received: from gandalf.gmx.de ([185.89.39.27]) by mail.gmx.net (mrgmx105 [212.227.17.168]) with ESMTPSA (Nemesis) id 1MFKGP-1qYzDn3Ymf-00Fgn2; Fri, 18 Aug 2023 17:12:35 +0200 From: Michael Albinus In-Reply-To: (Stefan Monnier's message of "Fri, 18 Aug 2023 09:25:42 -0400") References: <87r0o1r1io.fsf@gmx.de> <4b4a64de-846a-ed2a-f409-80ea75e9cb57@gmail.com> <87il9crgqh.fsf@gmx.de> <87bkf4r2xd.fsf@gmx.de> Date: Fri, 18 Aug 2023 17:12:33 +0200 Message-ID: <875y5cqt9a.fsf@gmx.de> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K1:OVL5+U6L5EeygR7QhOfJnBd5tJMT4o6cWquzTrL2230ldzarasJ nr8LEGYVFt49k/PKPObQG1V9NzuwgTB7nuKtmmPXEAx+uXVBLkSvaCs7io/r8jBvKs/tsW7 jTADM9WQyhwT+/QIH4we6dSmMSBsRKI8aDliUxwaLxmYcQazRm9+SX2gC8LvODDdxzcpUV6 Geg3/YxsAXVzYHPmYDTXA== X-Spam-Flag: NO UI-OutboundReport: notjunk:1;M01:P0:dF+DUM4DKbc=;2TxnFlx20fgBqPK5TKiCIvAOadY zwOLuYHiFzLRswE0KffntR3Y/jDfj7hrVyx6iklfdxSMvRKXKZTvONlXxoTrrY5q3+l7MKDE3 GJfrJw5tZP1sLTWMVAHfAq7aANeR1arHJz31Rnnc5KYUEow3NFyy/FVDM6FFjbfTu06yuArJW FJ5GvtqrImg8GyCrIGGBUDAq9WvDBXWJuQrZbjNmEQSprXIuVLZiGzGn39KQchaRprgKwI/5P W3Y9TQML8ClyuDNyu2X5U2NTRM+4vXoouAmlp5JQ5hyObcF0PNBRStXOmWVzy/jVnG6y20AKI kN4UKTz+lCDIXL0krDafwySDQoMVxjUmebrUqrq3T09KLRCs6KHGbLSv/w6IxCShkL6Reg5F3 TvHh7Q9Jv5SvdM3Iz65sgRuA+vRQQ447Rc85TdJf/+DQZei/F4imb1OjLnMvlhBoyHcF5iIhZ CeOxCGXsfEECft9gEKZdJQitwz42DSeQhivGkPjue8cteLF7jTQAWPSUY71kHD0JGVagYSfiy 6EPHe0iegszxpPkD3ACJQ0+prbqJEsFvtweTkrRIr51r4Rrn1LicVq0fzctFfXZljNNqxZwhD PF7C7iODngR5eJZGrwqXaGDooQuVYeDOlr80oRyutWjsOOJFlNEwA314KypWkYNc0QiScVbKp FCQ6RmlFkUjVOknXtXt4X8DlfQk0D+mYFxdDJRgl2lC57cJKwhZlyS3+q/bt7DDPFoqMPHS44 iTHgmaeEeQL3h+LJl75OEIZUbdF5n7r3ziikv4OGISADH2LKwps/cUjcvZXaS09cTS8DrrjPU LMqL47ynl0L7GMflYPdhFJvQQaDkJOaFtFvHOThIU+aSUmwril87uuac21jsV8o8CilDweAT2 hnaG4rpB/vv2viyT38bWD+udvJYMKvntH+nZuWOxzhu96WJcnRrO6giavy0x3jtxPbof6nOlZ llcBP5dc485EkvwHFfdZoAbcbUk= X-Spam-Score: -0.7 (/) 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.7 (-) Stefan Monnier writes: Hi Stefan, >> --8<---------------cut here---------------start------------->8--- >> (defun pcomplete/cd () >> "Completion for `cd'." >> (while (pcomplete-here (completion-table-in-turn >> (pcomplete-tramp) >> (pcomplete-dirs))))) >> --8<---------------cut here---------------end--------------->8--- > > AFIK this applies to `M-x shell` as well, so it doesn't seem > quite right. Yes. However, there is already another problem in shell-mode. My patch completes only incomplete Tramp file names, like "/ss". Complete Tramp file names are handled by pcomplete-dirs already. So we see in a *shell* buffer, w/o my patch: --8<---------------cut here---------------start------------->8--- [albinus@gandalf ~]$ cd /ssh:host: TAB => all directories on that remote host --8<---------------cut here---------------end--------------->8--- So we must fix completion of remote file names in shell-mode anyway. This would prevent also the modified pcomplete/cd to show any Tramp related file name. > Stefan Best regards, Michael. From unknown Thu Aug 14 22:23:05 2025 X-Loop: help-debbugs@gnu.org Subject: bug#65356: 30.0.50; [wishlist] Support Tramp method, user name and host name completion in eshell Resent-From: Michael Albinus Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 18 Aug 2023 17:51:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65356 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Stefan Monnier Cc: Jim Porter , 65356@debbugs.gnu.org Received: via spool by 65356-submit@debbugs.gnu.org id=B65356.16923810309690 (code B ref 65356); Fri, 18 Aug 2023 17:51:02 +0000 Received: (at 65356) by debbugs.gnu.org; 18 Aug 2023 17:50:30 +0000 Received: from localhost ([127.0.0.1]:48671 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qX3cD-0002WE-QL for submit@debbugs.gnu.org; Fri, 18 Aug 2023 13:50:30 -0400 Received: from mout.gmx.net ([212.227.15.19]:53987) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qX3cB-0002Vz-N7 for 65356@debbugs.gnu.org; Fri, 18 Aug 2023 13:50:28 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.de; s=s31663417; t=1692381017; x=1692985817; i=michael.albinus@gmx.de; bh=JPZaC6+eEV6QaBkr+9bOMJVWDfpa/6kHtaZjkfHlRgA=; h=X-UI-Sender-Class:From:To:Cc:Subject:In-Reply-To:References:Date; b=qS7J8+4HPhbAKq6zuB+BuzTNoSHantU9aS/TULEdyLeoEZPAklJsK7tOL5GxUXlclp7g+sw atl+BPLubj3Oysu9BarvUVjkKV0M/xyeTdedRIJDkrVVxlqnDh1TytIn/K5YvPToe7Y0Ie3lH HFua/uhUlQ0065pTZgF+ykMJEVt0rEgBJRF0FPLDqd880L05nhL9O7SR/dec4PGi7VPTeY+3L /X3hi6tLqLOjvPqC+MFvMvtuySsXZV9hkHKCTLdcnAUPB1mOoPRneMXoQrAALHaDnCQTWqOJm FtO3SFl7Iv4aoYjFKEL5jCWB93b5xJfx+zfxt0wqOkCaey7UvXqQ== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Received: from gandalf.gmx.de ([185.89.39.27]) by mail.gmx.net (mrgmx005 [212.227.17.190]) with ESMTPSA (Nemesis) id 1N79yQ-1phGJJ1WQu-017Vav; Fri, 18 Aug 2023 19:50:17 +0200 From: Michael Albinus In-Reply-To: (Stefan Monnier's message of "Fri, 18 Aug 2023 09:25:42 -0400") References: <87r0o1r1io.fsf@gmx.de> <4b4a64de-846a-ed2a-f409-80ea75e9cb57@gmail.com> <87il9crgqh.fsf@gmx.de> <87bkf4r2xd.fsf@gmx.de> Date: Fri, 18 Aug 2023 19:50:16 +0200 Message-ID: <87sf8gp7dz.fsf@gmx.de> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K1:wxHiAwnHzSxpMX9OaVS02URwZOU/RZugrzGaENCyZJo6a65ctMo hQDkfA0hdQICal2cMYqQx11yf3pyIjLFcYvdhhn3CvRbXBZyYjGo1lguOP5kGFCHr0xZkOw Jlzn7cGS7Hz9KITuNHaz79Td+CHSJLpR0xf3EsNasQXcOOE0BogImGPc0JCTxVEDe+IaY3H g26JP0M1xhvZC8P+kkUuw== X-Spam-Flag: NO UI-OutboundReport: notjunk:1;M01:P0:1YKgNXAr46E=;X4SRfKSuFrdTqFXUoMihlzzvdMP m6pfqaCGPArlw16kw0jd8Vh4nZbc0fYWJa7BiuSwWjHwKmgrSgRh6fYcFIGDjEYACf8kDkkXZ +kjZyZ5fodgpI3QG/r9bsWiyinNkZ8NHuzQFdmcTyBO3UCJVofAZAzlhcpFP1wBtQFnp94+Pg ZmUPVSgk1/QsG1QhdhVzjsaZNPky40H3WL8XrMmAeDsVG5tD8auZFjdZMQyHueCwte3vLuzBW jkG3DWhddwPC+WDyfiOavtJ3R/UUrbO0P5EIxKSkuSrOc0jg9AXfO53ohKsRi7IpQhLrK5rCs Z15mGYKWyS4Md761iK8Erb8Sn9P3q3kd7/+PnGUzzH8vNjK9D9uSV3KMlnichbmczrJtFvUaB 2y0huirU3FzQi1jyp+EXBdgVhxkg8nQXwY66BrNMV9t0NIm8f3TTZm0pCHxHVa56+N82x0nlL BujdaIvStXHSF3g33ZEOOlGWTTxqoRx00/uRRG2vIrHz+BbP5N0IYgGXC2iWaLcorom2tt+el yWuAWqKNn606oILBwB/fZH0HwLOansXHuhRD/BsZx/1+N7eSLznwPrGy/697Ip+2zQflED1iB t6rMO2GWiECnXO+8mxXBilZL6S3uGe/bOswhQgDdl5z+IG04ir0gojr8NUDEGYHDhb4BYUJmc Hq4ewqGXAk40QDi4aUtZLWz2dOegF8Sm3Mm0NWjBfxDacMlU+xLoMOxV3rcsVkJtlMPpDz/wL jEGDVr1L1Bx/rvTPwrt1woZkf0hbX04pI6bapAmGynYvpnsGmrZSq3UxTZNdNGEHdCbIAxzG/ YdwSLBHF5y14CdH5vMF6IaoBGgvcCdaTFGyFKmdBO6qkhyDbdAL7MCHTM+oyEmea6myuso4YU J5ykbwR9R76/NykPTMrn9hHsM58IEyyfUuTI7pYSA03sGtJRIyAUuG2rsUQNkxzxCySPNYP3t hFuwGw== X-Spam-Score: -0.7 (/) 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.7 (-) Stefan Monnier writes: >> --8<---------------cut here---------------start------------->8--- >> (defun pcomplete/cd () >> "Completion for `cd'." >> (while (pcomplete-here (completion-table-in-turn >> (pcomplete-tramp) >> (pcomplete-dirs))))) >> --8<---------------cut here---------------end--------------->8--- > > AFIK this applies to `M-x shell` as well, so it doesn't seem > quite right. We might use a flag which determines, whether remote file name completion is appropriate. In shell-mode remote file names shall be suppressed, and in eshell-mode it should be set depending on the command. "cd" should support remote file names, "*cd" should suppress them. Other packages use pcomplete as well, like erc and org. Whether they need to handle remote file names I don't know. This flag should be checked in pcomplete-tramp, pcomplete-dirs and whatever other pcomplete completion tables are concerned. This would fix also the other (minor) bug I've uncovered in shell-mode in my last message. There are already such flags, which control this kind of completion, like pcomplete-file-ignore, pcomplete-dir-ignore, pcomplete-autolist, you name it. What about a new boolean flag pcomplete-remote-ignore? WDYT? > Stefan Best regards, Michael. From unknown Thu Aug 14 22:23:05 2025 X-Loop: help-debbugs@gnu.org Subject: bug#65356: 30.0.50; [wishlist] Support Tramp method, user name and host name completion in eshell Resent-From: Stefan Monnier Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 18 Aug 2023 22:34:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65356 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Michael Albinus Cc: Jim Porter , 65356@debbugs.gnu.org Received: via spool by 65356-submit@debbugs.gnu.org id=B65356.16923980096528 (code B ref 65356); Fri, 18 Aug 2023 22:34:01 +0000 Received: (at 65356) by debbugs.gnu.org; 18 Aug 2023 22:33:29 +0000 Received: from localhost ([127.0.0.1]:49009 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qX825-0001hE-Gz for submit@debbugs.gnu.org; Fri, 18 Aug 2023 18:33:29 -0400 Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:12776) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qX823-0001gz-HU for 65356@debbugs.gnu.org; Fri, 18 Aug 2023 18:33:28 -0400 Received: from pmg3.iro.umontreal.ca (localhost [127.0.0.1]) by pmg3.iro.umontreal.ca (Proxmox) with ESMTP id DF132442A60; Fri, 18 Aug 2023 18:33:20 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1692397999; bh=jdAf891Cw0X7yraFl0bpvUYc3/pGOgpqaC5eH+IZ6zw=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=l/uNi5oJ3M3v0NDs03H52KuRcmGxdMKFe0ECAQ8iPtTCuvU1G8+Er6lnGklUqGStN Jdu2njpVBfz2JDIifGN808yV9PnwlT9W/pccby268rV3bMgbz0jcI3E9yqMEnVKbFJ Zasul5R6KGhP1mniI/Wwd/LGDlOTpNKKJm8EfXTpv7V2IoHIbIKSpL/lqCAxC8crRP qDZJ+1p82hLTBArOL+j/gJwOQQvrO48kIFvTyZ7CQiQr4GNdaoZOZ1syfWs4Xm/dwE EVXVofz4Hz6Wf89+tR1/QJkrLhCpMfdfM2+5bFHSgPj+6YqITwBDX3zmbHj7fH2fOp Qey8w4OqK1bwA== Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg3.iro.umontreal.ca (Proxmox) with ESMTP id 81C79442A89; Fri, 18 Aug 2023 18:33:19 -0400 (EDT) Received: from pastel (unknown [45.72.228.154]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id 598B21203D4; Fri, 18 Aug 2023 18:33:19 -0400 (EDT) From: Stefan Monnier In-Reply-To: <875y5cqt9a.fsf@gmx.de> (Michael Albinus's message of "Fri, 18 Aug 2023 17:12:33 +0200") Message-ID: References: <87r0o1r1io.fsf@gmx.de> <4b4a64de-846a-ed2a-f409-80ea75e9cb57@gmail.com> <87il9crgqh.fsf@gmx.de> <87bkf4r2xd.fsf@gmx.de> <875y5cqt9a.fsf@gmx.de> Date: Fri, 18 Aug 2023 18:33:18 -0400 User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-SPAM-INFO: Spam detection results: 0 ALL_TRUSTED -1 Passed through trusted hosts only via SMTP AWL 0.022 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DKIM_SIGNED 0.1 Message has a DKIM or DK signature, not necessarily valid DKIM_VALID -0.1 Message has at least one valid DKIM or DK signature DKIM_VALID_AU -0.1 Message has a valid DKIM or DK signature from author's domain DKIM_VALID_EF -0.1 Message has a valid DKIM or DK signature from envelope-from domain X-SPAM-LEVEL: X-Spam-Score: -2.3 (--) 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: -3.3 (---) > Yes. However, there is already another problem in shell-mode. My patch > completes only incomplete Tramp file names, like "/ss". Complete Tramp > file names are handled by pcomplete-dirs already. So we see in a *shell* > buffer, w/o my patch: Good point. Still, we have the problem that `pcomplete/` should be used only for external commands (because they are independent from the language used to write the command, a.k.a the shell), but for things like `cd` we should be more precise to distinguish the completion rules for Eshell's `cd` from those of bash's `cd`. Stefan From unknown Thu Aug 14 22:23:05 2025 X-Loop: help-debbugs@gnu.org Subject: bug#65356: 30.0.50; [wishlist] Support Tramp method, user name and host name completion in eshell Resent-From: Jim Porter Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 19 Aug 2023 03:28:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65356 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Stefan Monnier , Michael Albinus Cc: 65356@debbugs.gnu.org Received: via spool by 65356-submit@debbugs.gnu.org id=B65356.169241562518383 (code B ref 65356); Sat, 19 Aug 2023 03:28:02 +0000 Received: (at 65356) by debbugs.gnu.org; 19 Aug 2023 03:27:05 +0000 Received: from localhost ([127.0.0.1]:49150 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qXCcC-0004mQ-Rm for submit@debbugs.gnu.org; Fri, 18 Aug 2023 23:27:05 -0400 Received: from mail-oa1-x34.google.com ([2001:4860:4864:20::34]:53629) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qXCcB-0004lt-FL for 65356@debbugs.gnu.org; Fri, 18 Aug 2023 23:27:03 -0400 Received: by mail-oa1-x34.google.com with SMTP id 586e51a60fabf-1c4cf775a14so885942fac.3 for <65356@debbugs.gnu.org>; Fri, 18 Aug 2023 20:27:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1692415616; x=1693020416; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:mime-version:date:message-id:from:to:cc :subject:date:message-id:reply-to; bh=GaSyCXyM869vCwURH6Zm3cQpSp1ZZk3x2Jhdejrrqvo=; b=RzRZP4QjEOvecKmHzZhA6v8NGtVQgSs4cyjwjo6pUG5EzDC/Gy6vYZ3s3sNBNBTXXN 9ZfrpQ/8FOQ6/7W3xU7wFMaM60Z9sUnLM0bb4zC/yeYqlBp6S6ONKQWPjNwOex+LMRgL WBoEz+Q6HBdsXph67LWFWwTfT+4les2XVY+QfJynklvj37oDMLBsJ/SzVs2wpKS2T2iu 7kmGypzxlSIWVGMMgO0uHbPFjaKO0UqVtWJmC+hKIuxVpi2QWLScaJ56M2iEg0EVb4pf +blwLm+ETkyAxdDHSd01+Ocbs4q8EF4Xc9QQ8pwOqAU6RHHpso9/Dp+vITD7npUDUq7X WMAA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1692415616; x=1693020416; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=GaSyCXyM869vCwURH6Zm3cQpSp1ZZk3x2Jhdejrrqvo=; b=kdeRgk2LIyPF5nXYzypunMYR4cf7pwMx26Oe1iSGiaMQNS3e77PCXEYuFHisF/N+fA ir80UvD5iJy1nAvT6zf+BWH7fuPRorOJnLRQRuF1fvoQkGRbAV5foSgkIHiCIFomO3ps cbFIlb4yAp69hNN4EWhJ+JJeMdfyo1LEyH6OR9W9IldLFbt3kKidp64dAa80vOZ1SWZU ZXqAD1Alw6yHFHtpL1aZ2hM6bLGNJrudPlTe0Q5Eb34Uw0IM2pqlWRlpBBSH8MuOUsYA wEnDCFpa8rXqa4hbPcLconBSKS+19LhhDx8TtFGeQqDMf8nPhjnwHCv6HWJNjqElatTM ptdA== X-Gm-Message-State: AOJu0YwbT68k3v/0Sb8zr8pOE+r7Rm2CRv3lrtZEDvakD84IEbC9o//i k4yR0rF82BL9KUkueRI2mew= X-Google-Smtp-Source: AGHT+IGDkQpinKfyfDoYwI0/ZyjRUXzOsE64qqYfI6eosCZJ122nnRah5o88LgB7E7q/c2fCKlLBhA== X-Received: by 2002:a05:6870:4721:b0:1c8:d72a:d6b8 with SMTP id b33-20020a056870472100b001c8d72ad6b8mr1431290oaq.36.1692415616378; Fri, 18 Aug 2023 20:26:56 -0700 (PDT) Received: from [192.168.1.2] (cpe-76-168-148-233.socal.res.rr.com. [76.168.148.233]) by smtp.googlemail.com with ESMTPSA id mv6-20020a17090b198600b00264044cca0fsm1247999pjb.1.2023.08.18.20.26.55 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 18 Aug 2023 20:26:55 -0700 (PDT) Message-ID: Date: Fri, 18 Aug 2023 20:26:54 -0700 MIME-Version: 1.0 Content-Language: en-US References: <87r0o1r1io.fsf@gmx.de> <4b4a64de-846a-ed2a-f409-80ea75e9cb57@gmail.com> <87il9crgqh.fsf@gmx.de> <87bkf4r2xd.fsf@gmx.de> <875y5cqt9a.fsf@gmx.de> From: Jim Porter In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: 3.6 (+++) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: On 8/18/2023 3:33 PM, Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors wrote: >> Yes. However, there is already another problem in shell-mode. My patch >> completes o [...] Content analysis details: (3.6 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 3.6 RCVD_IN_SBL_CSS RBL: Received via a relay in Spamhaus SBL-CSS [2001:4860:4864:20:0:0:0:34 listed in] [zen.spamhaus.org] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (jporterbugs[at]gmail.com) 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [2001:4860:4864:20:0:0:0:34 listed in] [list.dnswl.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: 2.6 (++) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: On 8/18/2023 3:33 PM, Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors wrote: >> Yes. However, there is already another problem in shell-mode. My patch >> completes o [...] Content analysis details: (2.6 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 3.6 RCVD_IN_SBL_CSS RBL: Received via a relay in Spamhaus SBL-CSS [2001:4860:4864:20:0:0:0:34 listed in] [zen.spamhaus.org] -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [2001:4860:4864:20:0:0:0:34 listed in] [list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (jporterbugs[at]gmail.com) 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -1.0 MAILING_LIST_MULTI Multiple indicators imply a widely-seen list manager On 8/18/2023 3:33 PM, Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors wrote: >> Yes. However, there is already another problem in shell-mode. My patch >> completes only incomplete Tramp file names, like "/ss". Complete Tramp >> file names are handled by pcomplete-dirs already. So we see in a *shell* >> buffer, w/o my patch: > > Good point. > > Still, we have the problem that `pcomplete/` should be used only > for external commands (because they are independent from the language > used to write the command, a.k.a the shell), but for things like `cd` we > should be more precise to distinguish the completion rules for Eshell's > `cd` from those of bash's `cd`. That should be possible by defining 'pcomplete/eshell-mode/CMD', but that runs into two issues: 1) it's annoying to manually write all of these, and 2) there may be other contexts in Eshell we want to tab-complete remote directories that aren't covered by the command-specific Pcomplete functions like that. (#1 should be fixable with a new version of 'eshell-eval-using-options', but I haven't looked at that in much detail yet.) From unknown Thu Aug 14 22:23:05 2025 X-Loop: help-debbugs@gnu.org Subject: bug#65356: 30.0.50; [wishlist] Support Tramp method, user name and host name completion in eshell Resent-From: Michael Albinus Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 19 Aug 2023 17:49:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65356 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Jim Porter Cc: 65356@debbugs.gnu.org, Stefan Monnier Received: via spool by 65356-submit@debbugs.gnu.org id=B65356.169246731523329 (code B ref 65356); Sat, 19 Aug 2023 17:49:01 +0000 Received: (at 65356) by debbugs.gnu.org; 19 Aug 2023 17:48:35 +0000 Received: from localhost ([127.0.0.1]:52235 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qXQ3v-00064B-0f for submit@debbugs.gnu.org; Sat, 19 Aug 2023 13:48:35 -0400 Received: from mout.gmx.net ([212.227.15.18]:54445) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qXQ3q-000632-5f for 65356@debbugs.gnu.org; Sat, 19 Aug 2023 13:48:33 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.de; s=s31663417; t=1692467299; x=1693072099; i=michael.albinus@gmx.de; bh=HJKunOCVkzIArcrdRK7hBTM+ZRA1YudWYgDE4oiXdQ4=; h=X-UI-Sender-Class:From:To:Cc:Subject:In-Reply-To:References:Date; b=OJ5kIiWnWh5Tcock980vl74F4EqfbtfIOP+pOCwusVSP7zhW01djrtwJIsnBcu6mGMF9Bf4 rQkTiGd11iL4O5NFu9OiITwMumcM2wrqVr7FJezjtdpuAOoryiKZ9+B+SDflcoAZ/0FvSuwRW dYa0WrlBfqV0j+T7Kk3KlQfhhvhXFVQdzoZ2aGN0Ijit1a07swT/x+FF1bTu5asrooxn3l7wj IJh0/eSwuCRXDSsyhOwZJMZwmn5BfZKQItGuc6h2aYmfYDbN4NRkPo9YpnGEKUEG7jyAZKvPx DjFuj61xCvFY7b0ycXNBuigq7aFUGhuUzcK3BK18Rz4iR6ilejEQ== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Received: from gandalf.gmx.de ([185.89.39.27]) by mail.gmx.net (mrgmx005 [212.227.17.190]) with ESMTPSA (Nemesis) id 1MKbkM-1qJCYx0iVQ-00L1SE; Sat, 19 Aug 2023 19:48:19 +0200 From: Michael Albinus In-Reply-To: (Jim Porter's message of "Fri, 18 Aug 2023 20:26:54 -0700") References: <87r0o1r1io.fsf@gmx.de> <4b4a64de-846a-ed2a-f409-80ea75e9cb57@gmail.com> <87il9crgqh.fsf@gmx.de> <87bkf4r2xd.fsf@gmx.de> <875y5cqt9a.fsf@gmx.de> Date: Sat, 19 Aug 2023 19:48:17 +0200 Message-ID: <87zg2m9b4u.fsf@gmx.de> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Provags-ID: V03:K1:26VMUvrtQDEmjTS2Lt3V922GIrtM/EQTEIXRHjFnb9OTjd4s1FP 28h0SsgKZ/wS/7k3T4xgn1PC5lWjskcQ3orE3hgRfdyLfgO4CetVdVygQCJS2KARDPjM8fV V9r7Qz286lkX+blHe8zDsZ2020BaUNRHRjRJuSLqZDljRaTgq7To2U+9GfqEUKdLrv3YOM/ gPU7XO4qs8kKEucopht6A== X-Spam-Flag: NO UI-OutboundReport: notjunk:1;M01:P0:AEkh5nOEHWc=;7vPgsT4Zvm01bOHItL7a2+pzfHO +BKXAnx1cKPbxLRDXkMYjeTCqvWeapKK4/oMDNFUPuW3LPDRmP6O2x6mcfjBESRXMOZ7npibj k4BNood6O76MCN2Iqpgds/BuokubpO6Ig6ExQWCbJWrK5jIddbfzgdZT40bXhtoIuxxUhD9gh n5UQxx6eSU/bzu0wmmE1Si/59inhdApaNV7F8mzMEciVn/WEerEs1wTbPIIkb0DBGQ4SYkiPQ BevEgBFrdUA8h2b5ccbxlm4R/IZL1My8fH80q1mn9MEORehBZ7I2PT9arf50z2fpxIsJu2Pxg mz8GUHszxrTDuju4J/6v8onAJo9IQHDtCHYqnGdAav63oO3xfpE2nS1eGX/YnadyN+npxYQRS AflGSlGtwnS0EzEakQABBXKd3CS28m06wfziXfyoEUCtEUfMCgdt8Wo+6h7vIEptJHFAtF/cl ItGI8KijepdWPzn1qrrco7EKVJmG0F61FLA2Jsb1Y9m0BJBgJjEj5JZ7+MzydW7nlSm/pb4GP EUKsELNveJWg4hU3JMLV3VzIKBJvsBliTBRn/dMwT7N49967XaHh9WGUZDXXjU2ZQwpMUCrgx wPA03JRXoeVQsBK4VTeUHMqwVUWRfJH8Fl+PSKLLBe3hBFOIsc0i7xS3jiJ4RuPUYFOWc52S6 4YI58zdbeYVZQC/EZOiOP/QdixAe55u+8BirBdpf36A9cvta+rr37S4Ab9dW3giBHCJKD+NnO f+4ZI10IBXdvXMG9i8TrXYOuc6CW25SPPy8BE4cY1sEyx8EmIpHVJs4phNWJAUhuCrfVWxUAA 7ceSet01Zar/ZnF8M9EsMyT1HpPA3v24vOkhlBDala4YIggDTf4NmM8Gis5mQnBb3oJlkEq2Q /0mqmFtdQ6l7JSHAqSfkSvpkJkAnWX67lLPBC+nxUPK5ZuyhISETFP68casabkWkarj7Z1xbv MclJSw== X-Spam-Score: -0.7 (/) 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.7 (-) --=-=-= Content-Type: text/plain Jim Porter writes: Hi Jim & Stefan, >>> Yes. However, there is already another problem in shell-mode. My patch >>> completes only incomplete Tramp file names, like "/ss". Complete Tramp >>> file names are handled by pcomplete-dirs already. So we see in a *shell* >>> buffer, w/o my patch: >> Good point. >> Still, we have the problem that `pcomplete/` should be used >> only >> for external commands (because they are independent from the language >> used to write the command, a.k.a the shell), but for things like `cd` we >> should be more precise to distinguish the completion rules for Eshell's >> `cd` from those of bash's `cd`. > > That should be possible by defining 'pcomplete/eshell-mode/CMD', but > that runs into two issues: 1) it's annoying to manually write all of > these, and 2) there may be other contexts in Eshell we want to > tab-complete remote directories that aren't covered by the > command-specific Pcomplete functions like that. > > (#1 should be fixable with a new version of > 'eshell-eval-using-options', but I haven't looked at that in much > detail yet.) I gave it another try. There is a new user option pcomplete-remote-ignore. When nil (the default), pcomplete expands remote file names, including method, user name and host name. The corresponding let-bindings in pcomplete--entries are short. In shell-completion-vars, I set it buffer-local to t. This prevents remote file name completion in *shell* buffers, fixing also the bug mentioned above. In eshell I haven't set anything, so by default remote file names are expanded. It should be easy to set pcomplete-remote-ignore, depending on whether the command is a built-in (keep it nil), or an external command (set it to t). The patch is appended. Please note, that this has effect only when Tramp is loaded, so you might need to test with "emacs -Q -l tramp". People, who never use Tramp, won't see a difference. For testing you need a recent checkout of Emacs master, because I have added another function to tramp.el. This is already pushed to master. Comments? Best regards, Michael. --=-=-= Content-Type: text/x-patch Content-Disposition: attachment Content-Transfer-Encoding: quoted-printable diff --git a/lisp/pcomplete.el b/lisp/pcomplete.el index c7ec228c1db..e8bede9d605 100644 =2D-- a/lisp/pcomplete.el +++ b/lisp/pcomplete.el @@ -138,6 +138,11 @@ pcomplete-dir-ignore "A regexp of names to be disregarded during directory completion." :type '(choice regexp (const :tag "None" nil))) +(defcustom pcomplete-remote-ignore nil + "Whether to ignore remote file names." + :version "30.1" + :type 'boolean) + (define-obsolete-variable-alias 'pcomplete-ignore-case 'completion-ignore= -case "28.1") @@ -924,7 +929,10 @@ pcomplete--entries (sort comps pcomplete-compare-entry-function))= ) ,@(cdr (completion-file-name-table s p a))) (let ((completion-ignored-extensions nil) - (completion-ignore-case completion-ignore-case)) + (completion-ignore-case completion-ignore-case) + (tramp-mode (and tramp-mode (not pcomplete-remote-ignore))) + (non-essential (not (file-remote-p s))) + (minibuffer-completing-file-name (not (file-remote-p s)))) (completion-table-with-predicate #'comint-completion-file-name-table pred 'strict s p a)))))) diff --git a/lisp/shell.el b/lisp/shell.el index 7ea9d1c2ead..17ab12dda6d 100644 =2D-- a/lisp/shell.el +++ b/lisp/shell.el @@ -595,6 +595,8 @@ shell-completion-vars ;; Don't use pcomplete's defaulting mechanism, rely on ;; shell-dynamic-complete-functions instead. (setq-local pcomplete-default-completion-function #'ignore) + ;; Do not expand remote file names. + (setq-local pcomplete-remote-ignore t) (setq-local comint-input-autoexpand shell-input-autoexpand) ;; Not needed in shell-mode because it's inherited from comint-mode, bu= t ;; placed here for read-shell-command. --=-=-=-- From unknown Thu Aug 14 22:23:05 2025 X-Loop: help-debbugs@gnu.org Subject: bug#65356: 30.0.50; [wishlist] Support Tramp method, user name and host name completion in eshell Resent-From: Stefan Monnier Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 19 Aug 2023 18:39:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65356 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Michael Albinus Cc: Jim Porter , 65356@debbugs.gnu.org Received: via spool by 65356-submit@debbugs.gnu.org id=B65356.169247028227753 (code B ref 65356); Sat, 19 Aug 2023 18:39:01 +0000 Received: (at 65356) by debbugs.gnu.org; 19 Aug 2023 18:38:02 +0000 Received: from localhost ([127.0.0.1]:52268 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qXQpm-0007DZ-5A for submit@debbugs.gnu.org; Sat, 19 Aug 2023 14:38:02 -0400 Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:59991) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qXQpk-0007D5-AB for 65356@debbugs.gnu.org; Sat, 19 Aug 2023 14:38:01 -0400 Received: from pmg2.iro.umontreal.ca (localhost.localdomain [127.0.0.1]) by pmg2.iro.umontreal.ca (Proxmox) with ESMTP id 164FB80853; Sat, 19 Aug 2023 14:37:53 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1692470271; bh=OPRPFQKHF6NwoFYp9pfhNKiI4F1zGiOOkxhZ/H/9/e0=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=hFYOQ049t/8p/bFSPUgcckgMTwhdJlRCsSqmBCy7oX3NvS84G75JfNOdgQQH6eRvo pj2dytyYQFkpCOSOuz0jSj/c5a1VAx/Le52zpCHXRMeuedGIjCWO/m351mhFFAPVQz j69uX7RJ2Br6jWijvfAVze5iyV8o0q1zroyALjCwq1GuBwspKU43E1578kxigbP607 oiyHp/+CKJgP7feteB8DHlG773s4syfpL9ovNVBlagiYKC5W9MjfWq8KywxloEgJ2v L3c5uzRmAyQjyMK0z6J7j5s5XfDH2byL+CTui4dlqdDObFXeZ/DnAtb3YXbPBeRDL9 0mdnZPg6H7uBQ== Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg2.iro.umontreal.ca (Proxmox) with ESMTP id D143B8044E; Sat, 19 Aug 2023 14:37:51 -0400 (EDT) Received: from pastel (unknown [45.72.228.154]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id A4F5D12026A; Sat, 19 Aug 2023 14:37:51 -0400 (EDT) From: Stefan Monnier In-Reply-To: <87zg2m9b4u.fsf@gmx.de> (Michael Albinus's message of "Sat, 19 Aug 2023 19:48:17 +0200") Message-ID: References: <87r0o1r1io.fsf@gmx.de> <4b4a64de-846a-ed2a-f409-80ea75e9cb57@gmail.com> <87il9crgqh.fsf@gmx.de> <87bkf4r2xd.fsf@gmx.de> <875y5cqt9a.fsf@gmx.de> <87zg2m9b4u.fsf@gmx.de> Date: Sat, 19 Aug 2023 14:37:49 -0400 User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-SPAM-INFO: Spam detection results: 0 ALL_TRUSTED -1 Passed through trusted hosts only via SMTP AWL 0.023 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DKIM_SIGNED 0.1 Message has a DKIM or DK signature, not necessarily valid DKIM_VALID -0.1 Message has at least one valid DKIM or DK signature DKIM_VALID_AU -0.1 Message has a valid DKIM or DK signature from author's domain DKIM_VALID_EF -0.1 Message has a valid DKIM or DK signature from envelope-from domain X-SPAM-LEVEL: X-Spam-Score: -2.3 (--) 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: -3.3 (---) > I gave it another try. There is a new user option pcomplete-remote-ignore. FWIW, `pcomplete` is a generic completion library for use when completing things like function/command calls where the things to be completely at point depend on the position of the argument and the command/function that is called. It was originally designed for Eshell where those functions/commands are actual commands in the host system, but it's also used for things like ERC where the commands have nothing to do with executables installed in your machine. In theory is could be used for completion in code buffers where it could provide specialized completion depending on the expected type of the argument being completed. Stefan From unknown Thu Aug 14 22:23:05 2025 X-Loop: help-debbugs@gnu.org Subject: bug#65356: 30.0.50; [wishlist] Support Tramp method, user name and host name completion in eshell Resent-From: Michael Albinus Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 19 Aug 2023 19:15:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65356 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Stefan Monnier Cc: Jim Porter , 65356@debbugs.gnu.org Received: via spool by 65356-submit@debbugs.gnu.org id=B65356.169247247331362 (code B ref 65356); Sat, 19 Aug 2023 19:15:02 +0000 Received: (at 65356) by debbugs.gnu.org; 19 Aug 2023 19:14:33 +0000 Received: from localhost ([127.0.0.1]:52300 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qXRP7-00089m-FG for submit@debbugs.gnu.org; Sat, 19 Aug 2023 15:14:33 -0400 Received: from mout.gmx.net ([212.227.15.19]:59649) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qXRP4-00089Y-4u for 65356@debbugs.gnu.org; Sat, 19 Aug 2023 15:14:32 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.de; s=s31663417; t=1692472459; x=1693077259; i=michael.albinus@gmx.de; bh=OKSqzo/HJb8X7eIzvOgHTbfcXmTP3blp9TS4IRDfiw0=; h=X-UI-Sender-Class:From:To:Cc:Subject:In-Reply-To:References:Date; b=ZzVBxfY7dYoLOeGKYkStvB/MRtXy2TB+uYk51HF3ZtzxilUG1RInKWVd5H8gg4HPNejIqHh 7woyDrOO6qZYqI0wQNztwS+ETpTHEtkNhztRvhINqBISgFxuPewZcQe7NOr5/m5yvsiYrg56f ClHf0MNvLXI0KdveKjTlp0w2muyC7Whz/YGBLZK/C/ArYDR3Ri8p7zBtjyQplPXQ5LJdpSOSX DPKyjgcWcIkuNrpkwWGVeN0HwUZ/onfRzp2IAZWsnT7E5zICX7kuDWwTPc1sZvM98E/oV/BaU vdqtj3DGY0/AUoWuI6cRgyi3MseRyuuG3pQ+6OSoc/u8GFEEof8g== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Received: from gandalf.gmx.de ([185.89.39.27]) by mail.gmx.net (mrgmx005 [212.227.17.190]) with ESMTPSA (Nemesis) id 1MHoRA-1qUhrB1ZNW-00ErSI; Sat, 19 Aug 2023 21:14:19 +0200 From: Michael Albinus In-Reply-To: (Stefan Monnier's message of "Sat, 19 Aug 2023 14:37:49 -0400") References: <87r0o1r1io.fsf@gmx.de> <4b4a64de-846a-ed2a-f409-80ea75e9cb57@gmail.com> <87il9crgqh.fsf@gmx.de> <87bkf4r2xd.fsf@gmx.de> <875y5cqt9a.fsf@gmx.de> <87zg2m9b4u.fsf@gmx.de> Date: Sat, 19 Aug 2023 21:14:18 +0200 Message-ID: <87cyzilu9h.fsf@gmx.de> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K1:ErTA2+RS7F0g7XmUZWVZ0ZYmWkLmO88uFhXG1WoaMKHoSkTfAg/ BN0Rj8Qn3X/lZV2XQCc92i8gJXIqF6BZS1mwSWuZI8KkvbNLgQegvAInqw1VCZnhvnPb//4 SVFB9B0Qu5s9gdcg6joeYx02PvzcUR86CLztEEunO03aVTtOSPh2Zr6HYqzdIVpfiB99fKc ZEFEtnCU5LJbbY4qaCpLg== X-Spam-Flag: NO UI-OutboundReport: notjunk:1;M01:P0:hL357QQ2m1s=;6jchJzbFHZVMgx4IMO9fH3t2S9p 9etWhAyZR+W5KDo8erGTZTEkcl7zi6Yp2PKzNd1a8wOorCG1uI20CKXrwWP1Tj5VkwGXHZb1T CHTZ84TshU700BxI0D3r3owhtpPMm6yM+aEMMuCmMLyX3ZXlAswyEg2cWWxYhnB7uMdmjoXC9 IJgK670QWAucascTOpTNqyxbL/WMxPttI5jwEPghN+JAsdd2oujVc/3Bjr1B0mQciEGlzdk9A q61JmeRLYE5FdV1JYT0PvlhJOxFYfk7aerP+Tw2HrzdGvXFRE6MVp9jnpQsT5NbU5RVB9W8Xq z69oIdnpllOwXu5ImcuaUZcLee3MsfGEcQPVlCJKLfq4gw9aAsIoIsUZpAC+S4bAWGCz1zYTA cSSWmiZz32bQQc+Lkxf71+Xce8p+BTa6UmcutdXVHJDdx7CGHJZfjclSa8hGuWv8gCUh5OowR GguHe4dZSt0vVRqz9uZDuUZNEiIIG3+ku64hQMbyiFFckh6iQ98XjjGnlxHPSQlIfCjldnTHB JJq3Q0lKus6jxP5m8sbbpo/aQ5bRkvcxm/bCSPZlUdRwp5sEE92x6X6zi0RpweTYA73qnx1+V T6Zaw34oZHyb43GF/5tolMyEcTXy9waPgI7ton/e7XqswXuuTZLJaxgY2sz0zH+pU/1Xi3xc0 pZp8Epc/+//+MxuV6QKezkJtC/GW53RlXLR7jdasw0Ha1WPcbw62N0vfCo3YmshUGg64ma0mp BJJnmhOGZmk+BQr6iyoVeyw+zViaaYh/6VInMjQxXarfWyb/KgaGKJvqdmkWOqSJISez+sv0R qqOpweSTgPtU7cfXggvtVAFYmlC7sNVw2SGvnzwMnj4tvdSpS4K/Zz9ujnHQS16ILIv6gSoQb 7PdPQR3G/g90oQ2rP344Bqgh/JqNKgdkkvUi8eP43m+GIfBmSNWvCYRbTaKFTmucJn/4M1Icr RMhg3g== X-Spam-Score: -0.7 (/) 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.7 (-) Stefan Monnier writes: Hi Stefan, >> I gave it another try. There is a new user option pcomplete-remote-ignore. > > FWIW, `pcomplete` is a generic completion library for use when > completing things like function/command calls where the things to be > completely at point depend on the position of the argument and the > command/function that is called. > > It was originally designed for Eshell where those functions/commands are > actual commands in the host system, but it's also used for things like > ERC where the commands have nothing to do with executables installed in > your machine. ERC should could set pcomplete-remote-ignore to t, as I have proposed for shell buffers. Likely, even this isn't needed. The default (w/o my patch) is to complete remote file names. This hasn't disturbed ERC until now. > In theory is could be used for completion in code buffers where it > could provide specialized completion depending on the expected type of > the argument being completed. Hmm. Does it mean you agree with the patch, or not? My change should affect only file name completion, any other completion should work as before. > Stefan Best regards, Michael. From unknown Thu Aug 14 22:23:05 2025 X-Loop: help-debbugs@gnu.org Subject: bug#65356: 30.0.50; [wishlist] Support Tramp method, user name and host name completion in eshell Resent-From: Stefan Monnier Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 20 Aug 2023 00:03:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65356 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Michael Albinus Cc: Jim Porter , 65356@debbugs.gnu.org Received: via spool by 65356-submit@debbugs.gnu.org id=B65356.169248974727240 (code B ref 65356); Sun, 20 Aug 2023 00:03:02 +0000 Received: (at 65356) by debbugs.gnu.org; 20 Aug 2023 00:02:27 +0000 Received: from localhost ([127.0.0.1]:52468 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qXVti-00075I-WE for submit@debbugs.gnu.org; Sat, 19 Aug 2023 20:02:27 -0400 Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:17811) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qXVte-000751-Ef for 65356@debbugs.gnu.org; Sat, 19 Aug 2023 20:02:26 -0400 Received: from pmg2.iro.umontreal.ca (localhost.localdomain [127.0.0.1]) by pmg2.iro.umontreal.ca (Proxmox) with ESMTP id 5AAD080893; Sat, 19 Aug 2023 20:02:15 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1692489734; bh=0q3/X3nwxkYG5omSD9sYMuGXXIIhI/lWZlKx0JaWo20=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=h27P2MgSKASCe+3CrkaQyanj7Sc8OUCifp+klH4IX7oIau2dk2LDeFhH//9lx0JMh L99nP9+MopJdp37Au9rwmXUQqJ5S3xStwngYUXZLtLPqNzO6380TNrGIaNxJsYKGeV +FkgX6nC5FGsQ7U/7QApDOhmRoGv3JJPo5t0Hf43pgxSywcMPKolTSBxSlHGQjL4q1 GnHajgNuujosJnpxc5zktEqR5MYqcuDAe2Cv8H0TPJelS0YJ/3Mo188DK77TKMq4m/ 4gUBFxWzQomP4qTarIoW22F/B71CHq/q1XnepQ8TTgU1MJBPECDEkr38TQ6y9FEq7u s4q/ZaY2PGGAQ== Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg2.iro.umontreal.ca (Proxmox) with ESMTP id 51D318084F; Sat, 19 Aug 2023 20:02:14 -0400 (EDT) Received: from pastel (unknown [45.72.228.154]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id 292C0120334; Sat, 19 Aug 2023 20:02:14 -0400 (EDT) From: Stefan Monnier In-Reply-To: <87cyzilu9h.fsf@gmx.de> (Michael Albinus's message of "Sat, 19 Aug 2023 21:14:18 +0200") Message-ID: References: <87r0o1r1io.fsf@gmx.de> <4b4a64de-846a-ed2a-f409-80ea75e9cb57@gmail.com> <87il9crgqh.fsf@gmx.de> <87bkf4r2xd.fsf@gmx.de> <875y5cqt9a.fsf@gmx.de> <87zg2m9b4u.fsf@gmx.de> <87cyzilu9h.fsf@gmx.de> Date: Sat, 19 Aug 2023 20:02:12 -0400 User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-SPAM-INFO: Spam detection results: 0 ALL_TRUSTED -1 Passed through trusted hosts only via SMTP AWL 0.023 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DKIM_SIGNED 0.1 Message has a DKIM or DK signature, not necessarily valid DKIM_VALID -0.1 Message has at least one valid DKIM or DK signature DKIM_VALID_AU -0.1 Message has a valid DKIM or DK signature from author's domain DKIM_VALID_EF -0.1 Message has a valid DKIM or DK signature from envelope-from domain X-SPAM-LEVEL: X-Spam-Score: -2.3 (--) 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: -3.3 (---) > ERC should could set pcomplete-remote-ignore to t, as I have proposed Not sure if ERC's pcomplete ever completes file names, to be honest. >> In theory is could be used for completion in code buffers where it >> could provide specialized completion depending on the expected type of >> the argument being completed. > Hmm. Does it mean you agree with the patch, or not? My change should > affect only file name completion, any other completion should work > as before. Yes, it's OK. I was just pointing out that pcomplete doesn't specifically have anything to do with (completion of) file names, so the new variable is not really relevant to "pcomplete proper" but only to the set of defaults that are provided along with pcomplete. The name might try and reflect that a bit more, e.g. by including "file" somewhere. Stefan From unknown Thu Aug 14 22:23:05 2025 X-Loop: help-debbugs@gnu.org Subject: bug#65356: 30.0.50; [wishlist] Support Tramp method, user name and host name completion in eshell Resent-From: Jim Porter Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 20 Aug 2023 05:24:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65356 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Michael Albinus Cc: 65356@debbugs.gnu.org, Stefan Monnier Received: via spool by 65356-submit@debbugs.gnu.org id=B65356.169250903127242 (code B ref 65356); Sun, 20 Aug 2023 05:24:02 +0000 Received: (at 65356) by debbugs.gnu.org; 20 Aug 2023 05:23:51 +0000 Received: from localhost ([127.0.0.1]:52685 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qXaul-00075K-FX for submit@debbugs.gnu.org; Sun, 20 Aug 2023 01:23:51 -0400 Received: from mail-qk1-x733.google.com ([2607:f8b0:4864:20::733]:46541) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qXauj-000757-RQ for 65356@debbugs.gnu.org; Sun, 20 Aug 2023 01:23:50 -0400 Received: by mail-qk1-x733.google.com with SMTP id af79cd13be357-76d7bcefe8bso153952885a.1 for <65356@debbugs.gnu.org>; Sat, 19 Aug 2023 22:23:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1692509022; x=1693113822; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:mime-version:date:message-id:from:to:cc :subject:date:message-id:reply-to; bh=3o2HGIgTf+CWaQ4b/uef3Cc+yNQ1O8E6gQhdxjJLe8M=; b=pgPFuIQPdaT8QCv67j+QRjyoGpKPWIcZzeGqMNWYPnCywq0MuY/PyzxSfzm+dCoc3a S0KSY9C1578CpoQpGTbHrBk08fnCKbho9LUBbLVbMqUBtSZwMGhYIBjdxCrJ2syxLQm4 lkd0q5r+ppQJn0SLgQbbHx38tVIl6bxUOLAC1ddQLnq/K3s93RIhU3ejmq7GWetMzQT0 I3cN+/KZv+eDeHYqgYMHSEfsH7swt/DXTlc5C5w/gq57nCnxd/s7PIY7UvABjOA4p+CN ITPnZ+fJQ7rguOrB+J9N6ha/vZswwaPvGEe1c391ro15gLSnvzOHmP9jEN4iRLFraOey ie+A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1692509022; x=1693113822; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=3o2HGIgTf+CWaQ4b/uef3Cc+yNQ1O8E6gQhdxjJLe8M=; b=kn+8FFB85fO73RztOJwlIru8XqRAN/5Un3vq4uno3l63JHZ1tc4voCRiC8HElYe6Mv tAaWoq9VDtkJuX9idvvbV/+YmudkUAaUWMsEabwd8yxmlRkFtQI8usqW16vP9F3MiZZe qy1xMfz+k+BK2T2ENru+ussHgB2L/rQBc1yA99EC53+SQccS78nLjec4IRSX9lxdCOeu Z3GDWOSOjvUStsr4icBt/ccAhoUjXbn+eU4pa+kgqc/hpZl4SYpO34L3Fdwy2EU+zHv1 iJ2r0WtLqR26+MzNak22A1RB4pjOcbGBbdsquWgqUZkuR34uXoxMTWUVQjwctDir2tfL ulbg== X-Gm-Message-State: AOJu0YxjiFrWIijsZ/hC/KCHIjAK6GfmplvxyJYN1xDVG9wijwGYDpDF CSHT301HekAYrxRcIltdBbk= X-Google-Smtp-Source: AGHT+IH+oOEd8WlaXvaruQJ2nD22QKOYr4zYisHd5qRwSJtf+eDUvpXPYfGe9GeQ0tSpSgdSLKX5mg== X-Received: by 2002:a05:620a:218c:b0:767:1938:93c7 with SMTP id g12-20020a05620a218c00b00767193893c7mr4239656qka.43.1692509022625; Sat, 19 Aug 2023 22:23:42 -0700 (PDT) Received: from [192.168.1.2] (cpe-76-168-148-233.socal.res.rr.com. [76.168.148.233]) by smtp.googlemail.com with ESMTPSA id n10-20020a17090a670a00b0025c1cfdb93esm3919818pjj.13.2023.08.19.22.23.41 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sat, 19 Aug 2023 22:23:42 -0700 (PDT) Message-ID: Date: Sat, 19 Aug 2023 22:23:41 -0700 MIME-Version: 1.0 Content-Language: en-US References: <87r0o1r1io.fsf@gmx.de> <4b4a64de-846a-ed2a-f409-80ea75e9cb57@gmail.com> <87il9crgqh.fsf@gmx.de> <87bkf4r2xd.fsf@gmx.de> <875y5cqt9a.fsf@gmx.de> <87zg2m9b4u.fsf@gmx.de> From: Jim Porter In-Reply-To: <87zg2m9b4u.fsf@gmx.de> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: 0.0 (/) 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 (-) On 8/19/2023 10:48 AM, Michael Albinus wrote: > The patch is appended. Please note, that this has effect only when Tramp > is loaded, so you might need to test with "emacs -Q -l tramp". People, > who never use Tramp, won't see a difference. > > For testing you need a recent checkout of Emacs master, because I have > added another function to tramp.el. This is already pushed to master. > > Comments? This works for me, and I think it makes sense overall. It might be nice to add the ability to ignore remote file names in Eshell when completing an argument to an external command (which doesn't understand Tramp syntax), but that would probably require a bunch of work on the Eshell side, and we can worry about that later, I think. From unknown Thu Aug 14 22:23:05 2025 X-Loop: help-debbugs@gnu.org Subject: bug#65356: 30.0.50; [wishlist] Support Tramp method, user name and host name completion in eshell Resent-From: Michael Albinus Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 20 Aug 2023 07:51:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65356 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Stefan Monnier Cc: Jim Porter , 65356@debbugs.gnu.org Received: via spool by 65356-submit@debbugs.gnu.org id=B65356.169251784212298 (code B ref 65356); Sun, 20 Aug 2023 07:51:02 +0000 Received: (at 65356) by debbugs.gnu.org; 20 Aug 2023 07:50:42 +0000 Received: from localhost ([127.0.0.1]:53013 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qXdCs-0003CI-2U for submit@debbugs.gnu.org; Sun, 20 Aug 2023 03:50:42 -0400 Received: from mout.gmx.net ([212.227.15.15]:57177) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qXdCm-0003C1-SL for 65356@debbugs.gnu.org; Sun, 20 Aug 2023 03:50:40 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.de; s=s31663417; t=1692517826; x=1693122626; i=michael.albinus@gmx.de; bh=0YiSfgNs5bw/NPiWpxyjGpGfoe2nvO5upg8PCGOzj3U=; h=X-UI-Sender-Class:From:To:Cc:Subject:In-Reply-To:References:Date; b=dcHt//kx0UmouJhmqh8zydZgQTjYU05B5NqD+13cMsSUpVVV3pyRHCYdkgSniLPvHxFIQOK hPNmMnjz7GuE0W9LA6frqnQKgkcztoCAgqRjQa/AGeodVZez2C3hDJRrqDICOWUXskzpi528k gBRIsxDoOVOlVbFCuP8lXQxTu0tqAYuKGFNnP4u7z+39a/TS0c5F5CqAzAHCdDBbUv6wjkuNn eRSZnA//RyNnqZew0rxg7KW3KASyq6VX3U917yErtAh8D/j3Cmpw1Q5Jfybidtt4BwpIBeg8b y5yJteeHDajPgqvqUrn1qNQc6+sOturVHT81IbTd2Mh/h7KPoFjA== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Received: from gandalf.gmx.de ([185.89.39.27]) by mail.gmx.net (mrgmx005 [212.227.17.190]) with ESMTPSA (Nemesis) id 1MRCOE-1qLTZl49YK-00NDU3; Sun, 20 Aug 2023 09:50:26 +0200 From: Michael Albinus In-Reply-To: (Stefan Monnier's message of "Sat, 19 Aug 2023 20:02:12 -0400") References: <87r0o1r1io.fsf@gmx.de> <4b4a64de-846a-ed2a-f409-80ea75e9cb57@gmail.com> <87il9crgqh.fsf@gmx.de> <87bkf4r2xd.fsf@gmx.de> <875y5cqt9a.fsf@gmx.de> <87zg2m9b4u.fsf@gmx.de> <87cyzilu9h.fsf@gmx.de> Date: Sun, 20 Aug 2023 09:50:24 +0200 Message-ID: <87350e9mpr.fsf@gmx.de> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K1:EbfhCDy4Sw1El29WQI1t8f7FQmLKtys6XBXuKhX0lGONxC6PDUV gWUxulEcEK6esPQXSETf06MO5WhVAWcQeGisahFbVfhgQpFiQscV0mBCA8GWOXjHHr/x/mc di23nhAqoats0CYLL/xMasugpHomrm7rorTbnrinHplzrregg8GDFySj30L8iSsTCcUIJJJ n65hmRJKnAdZvRbsGQvLA== X-Spam-Flag: NO UI-OutboundReport: notjunk:1;M01:P0:8/3Jk6dOEJo=;shRMVHMWD7iaPqx58+vRS5UF+9B qG7kgKdi6MohaOr42AbLmTaNdRKlQhQ3B32p3y1+7kD0wTA5zVyWZtD6waQaSMRVw3wUo5wL4 Jc0Ln1OPB9YyAs/6ymMzxaMgxnTEqsx3Md5ankigbJAAdtyLVyZecSv7A/nYCwwM5NNE/vWIH xl2GOQzaBupYbAdfZCRb7yFpyoKZcfzV+uSw/9LDHSgfnlrRroZqePka8lkaUlXXdXQ9mWUWl eh2cxACIi3UeH78/p3FeR/wasFw2TdQvoLmgp4Sw8+pYIp0GlytdiZ/rcRbSLmvR9qb/d9bmz FNZzP1/P42egViGfg2F6N5rd3icncjJZBAEU6zJKTb+8AMwUozd7hMrq9pidb8w/P/nB01xKs IZAFw6xTe6UE/udcaYjHEWfN8v5WEO6q0tKOxKjfrlXIkta9SGT0Xx70M/UwqQY+KVOxu9H1E z3sdFtJ3yAq+F5qbN22ZBwRlVu5v132rec3LZdhXkhNMmnVTGZqbzllb/e5YAORbnQVskJ8w3 FjLgvBEAOrpJnBQfbbmiA7oBdYQfo90Sc1rX66BSe2y21vnC5TVz26qufgPAa2k+05wlUYo2F qftLum06Ne3T+Gkx/44ESrenrOwDWW90y/eUduuhPsVQItNO3EmeGCqgRngF0oLqjzo2Xwmf+ yHWJ4t/q0IzoWqkTHmfcuUg/9koPxfftyUfSwgdJbNn8euKcCZCW7h7wC6owFIksEMCgUaC1u XnhkElN5lbF0qgizOhRv3Lnj5aw/wT4BwRdssFi4ZwvOIb1E3JGyc/KXqHw8tqLN4h+wee9F5 p7JXQxzlk/8cRHq7suf6ahtgkZzEzGdLQq4Fo4zkho3VoWTX5cwMTMSzWW+HG4Er7VRXl+PPj C3KuoT/ctR19Ftr9bnysAY1QA0WzABXTxXFeusSaiq9T0/pbDNrJlqagVPnVh9CSOc9+83NwQ FdBlkw== X-Spam-Score: -0.7 (/) 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.7 (-) Stefan Monnier writes: Hi Stefan, > Yes, it's OK. I was just pointing out that pcomplete doesn't > specifically have anything to do with (completion of) file names, so the > new variable is not really relevant to "pcomplete proper" but only to > the set of defaults that are provided along with pcomplete. > The name might try and reflect that a bit more, e.g. by including > "file" somewhere. I've pushed it to master. The user option is called now pcomplete-remote-file-ignore. > Stefan Best regards, Michael. From unknown Thu Aug 14 22:23:05 2025 X-Loop: help-debbugs@gnu.org Subject: bug#65356: 30.0.50; [wishlist] Support Tramp method, user name and host name completion in eshell Resent-From: Michael Albinus Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 20 Aug 2023 10:54:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65356 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Jim Porter Cc: 65356@debbugs.gnu.org, Stefan Monnier Received: via spool by 65356-submit@debbugs.gnu.org id=B65356.169252880531432 (code B ref 65356); Sun, 20 Aug 2023 10:54:01 +0000 Received: (at 65356) by debbugs.gnu.org; 20 Aug 2023 10:53:25 +0000 Received: from localhost ([127.0.0.1]:53176 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qXg3h-0008Au-4C for submit@debbugs.gnu.org; Sun, 20 Aug 2023 06:53:25 -0400 Received: from mout.gmx.net ([212.227.15.15]:60497) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qXg3e-0008Af-4u for 65356@debbugs.gnu.org; Sun, 20 Aug 2023 06:53:23 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.de; s=s31663417; t=1692528791; x=1693133591; i=michael.albinus@gmx.de; bh=msCkyaRYhnuORXu8vLzCSl3WbQv5kQ+Td/tnyddecI0=; h=X-UI-Sender-Class:From:To:Cc:Subject:In-Reply-To:References:Date; b=plqatuG/sPZX2YyXx1tvbSDYukgrSjI6xKM11UzbHalEr+vw4G2PVEIMUZYao+ZKQDz/z7U UJUNsIXWXtGWOHJHTzKTr3qeEJNuLyvE4P6r1ky6jQNFFYta9zsx/2z1addF3pby6y5jEyQHf cSBCOYQKqmng33JcH6yb/rcIIU3JArLTp5FAsxDq+cjjtExnWdyhPhSKIrNwKKgMrgtSNETxi IpIG+HXO1TA8ea1UWQ3PD+YqgTgCfQSJBAdqwIOuWUez9mNf/oQ/D+LZBNM/ZD6YnGjluTSiI AnfAV54nEF7kjNHXP2TEE2SpKyminnB+wuRg4CcGY7UJCes4YZZA== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Received: from gandalf.gmx.de ([185.89.39.27]) by mail.gmx.net (mrgmx004 [212.227.17.190]) with ESMTPSA (Nemesis) id 1Mi2Nv-1q2Ry200u1-00e82A; Sun, 20 Aug 2023 12:53:11 +0200 From: Michael Albinus In-Reply-To: (Jim Porter's message of "Sat, 19 Aug 2023 22:23:41 -0700") References: <87r0o1r1io.fsf@gmx.de> <4b4a64de-846a-ed2a-f409-80ea75e9cb57@gmail.com> <87il9crgqh.fsf@gmx.de> <87bkf4r2xd.fsf@gmx.de> <875y5cqt9a.fsf@gmx.de> <87zg2m9b4u.fsf@gmx.de> Date: Sun, 20 Aug 2023 12:53:09 +0200 Message-ID: <87wmxq7zoq.fsf@gmx.de> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Provags-ID: V03:K1:eB6d0EdVKp/WVuVxgHmO1N3E90bPDdEouGPcD9FfN8LG5/RvpY/ Oz4qVQv4W19rl+Atf9MVkFUsxxXDii3RApM3baC2EMjtpDXrCcSiF7+yyDwIYpkZo8KosEa t1zRjGXuD1TcUVXxVcz0N+BIHCei4Q04tsnp9waUkNvPVQ49u9viK62VpRnHh9to911Ifpz DSuAww4vSha+GzoxSDBTg== X-Spam-Flag: NO UI-OutboundReport: notjunk:1;M01:P0:lbExKHqaP/o=;UKeg6m8nMk9yISYOHCHfP/hyxJO Y5FFpwXBlt/gMIQ/qs81seCtrz85qxWDlU7FKnuWxDh4rfbp5d665iFEpcqsRwsnhuDQlZQ3c qr1m3/So5//VSTzpv1L5x4zZjTI2JIN61vZawUJpYEEF3aU+u8EVkjmO0Rr5GScGBMMzd9zIh jfUKbm9wGV4gm0nTDoC/bJ78+EjxG7+k082il9tiQ8bDKO6nS12CuNRTElTZQ35uM/CgCSsZN Wc6jDvzrJdPy+zLkHqlsfFBS+p494il8NCH9luB4I1dy1pzVmr8+adoz+Sa7Fn7OTeRydH5Mu zT3Hc8n6uPlq/HycF5Ongt8mB62QxCaaz4Ho2lCmXswmVCzgZngE7+5Cx0dqaoBtXy0IL75iW hcS7NI5p0vq4MArZYzBa7/oIpYdF6g86UBjtaqWjb4qIyIG969f8mn0dMYi8reyVzXStEKD10 RcvB4muVl/3MLY90J8Nm2vAz4YMS/R2sdfMq+pdiJkpWVJo7umeKDKYbqhqjHG4zhOkX4aH/C QMnNHC82kmwsE8LtuNx3gHyZYEaxB7OOHPow7um+rkRpIUYpjRmOgPWvTj2lD9oWnfJuN5H0n oC1BesQ744T/x2dkCVURJUliDIWMEh2vxU4+jqmNy3rV79VhXD9dVjGIhfCL2JXmr7tigZw2A 4FgYQI6+hinuPbxCavy4qpogyz92jBE5I9iBN/Z9HvsKGJANMBZeKJiroBvrAJx1n3cw0GvfD QrTt+uQbO7aRAZT/T6OoppG6o3hVECZOA0OTlsH8Xk7SAFTA1KRDJCLTWklV1xOsIvqsg+aG6 PNLtw09TIcJfX1rH/Ke3/dOzcpgF40BW/u77NnUko2f/pDyQgNLJTcVXljxqYu1Y/2CYfPJvL HNwFnoWxuHCL6SoFXMCRGeWIpYNqqr39ZACppW6Sa5Amq6j04Gvj0J4n0C2feaFhKfwQOKuPR eOsqnw== X-Spam-Score: -0.7 (/) 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.7 (-) --=-=-= Content-Type: text/plain Jim Porter writes: Hi Jim, > This works for me, and I think it makes sense overall. It might be > nice to add the ability to ignore remote file names in Eshell when > completing an argument to an external command (which doesn't > understand Tramp syntax), but that would probably require a bunch of > work on the Eshell side, and we can worry about that later, I think. As POC, I've written the appended patch. It works for me in a simple case, but I'm pretty sure it needs to handle more cases. Since I'm not so familiar with Eshell, I let it to you :-) ... unless you say it is sufficient ATM. Best regards, Michael. --=-=-= Content-Type: text/x-patch Content-Disposition: attachment Content-Transfer-Encoding: quoted-printable diff --git a/lisp/eshell/em-cmpl.el b/lisp/eshell/em-cmpl.el index 732bbb3f1fa..25dccbd695c 100644 =2D-- a/lisp/eshell/em-cmpl.el +++ b/lisp/eshell/em-cmpl.el @@ -148,6 +148,10 @@ eshell-cmpl-dir-ignore (eshell-cmpl--custom-variable-docstring 'pcomplete-dir-ignore) :type (get 'pcomplete-dir-ignore 'custom-type)) +(defcustom eshell-cmpl-remote-file-ignore nil + (eshell-cmpl--custom-variable-docstring 'pcomplete-remote-file-ignore) + :type (get 'pcomplete-remote-file-ignore 'custom-type)) + (defcustom eshell-cmpl-ignore-case (eshell-under-windows-p) (eshell-cmpl--custom-variable-docstring 'completion-ignore-case) :type (get 'completion-ignore-case 'custom-type)) @@ -248,6 +252,8 @@ eshell-cmpl-initialize eshell-cmpl-file-ignore) (setq-local pcomplete-dir-ignore eshell-cmpl-dir-ignore) + (setq-local pcomplete-remote-file-ignore + eshell-cmpl-remote-file-ignore) (setq-local completion-ignore-case eshell-cmpl-ignore-case) (setq-local pcomplete-autolist @@ -325,6 +331,15 @@ eshell-complete--eval-argument-form "Failed to evaluate argument form during completion: %S" arg) (propertize "\0" 'eshell-argument-stub 'error)))) +;; Code stolen from `eshell-plain-command'. +(defun eshell-external-command-p (command) + "Whether an external command shall be called." + (let* ((esym (eshell-find-alias-function command)) + (sym (or esym (intern-soft command)))) + (not (and sym (fboundp sym) + (or esym eshell-prefer-lisp-functions + (not (eshell-search-path command))))))) + (defun eshell-complete-parse-arguments () "Parse the command line arguments for `pcomplete-argument'." (when (and eshell-no-completion-during-jobs @@ -406,6 +421,14 @@ eshell-complete-parse-arguments args posns) (setq args (nreverse evaled-args) posns (nreverse evaled-posns))) + ;; Determine, whether remote file names shall be completed. They + ;; shouldn't for external commands, or when in a pipe. Respect + ;; also `eshell-cmpl-remote-file-ignore', which could be set by + ;; the user. + (setq-local pcomplete-remote-file-ignore + (or eshell-cmpl-remote-file-ignore + eshell-in-pipeline-p ; does not work + (eshell-external-command-p (car args)))) ;; Convert arguments to forms that Pcomplete can understand. (cons (mapcar (lambda (arg) --=-=-=-- From unknown Thu Aug 14 22:23:05 2025 X-Loop: help-debbugs@gnu.org Subject: bug#65356: 30.0.50; [wishlist] Support Tramp method, user name and host name completion in eshell Resent-From: Jim Porter Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 23 Aug 2023 00:31:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65356 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Michael Albinus Cc: 65356@debbugs.gnu.org, Stefan Monnier Received: via spool by 65356-submit@debbugs.gnu.org id=B65356.169275064931859 (code B ref 65356); Wed, 23 Aug 2023 00:31:02 +0000 Received: (at 65356) by debbugs.gnu.org; 23 Aug 2023 00:30:49 +0000 Received: from localhost ([127.0.0.1]:60654 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qYblp-0008Hl-AF for submit@debbugs.gnu.org; Tue, 22 Aug 2023 20:30:49 -0400 Received: from mail-pf1-x42a.google.com ([2607:f8b0:4864:20::42a]:61914) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qYblo-0008HX-5m for 65356@debbugs.gnu.org; Tue, 22 Aug 2023 20:30:48 -0400 Received: by mail-pf1-x42a.google.com with SMTP id d2e1a72fcca58-68a4025b5e8so2268261b3a.3 for <65356@debbugs.gnu.org>; Tue, 22 Aug 2023 17:30:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1692750639; x=1693355439; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:mime-version:date:message-id:from:to:cc :subject:date:message-id:reply-to; bh=M5307+EHkLHSMIGS5/gztCmUfdbxkOe/tehOVmgnURM=; b=EHCMOXHogHztwQIueXZS0oqWMCfCr0ayPeSvUSdqDx8/aaccjSRrlbTeCsd0GS70bt xyQEFkdZaWRkB/ZS3FwIngnaCk/HohpuXapLfY2Y/wC+qELT7Rf4ROQuxAnEp4OvmR5f jRLAUCkgYLfhWZPOvShb2ttUbG0QIKi+nG7VSeJhk+L2+qSkZxDb4SMjz7bN4SFIXOK3 g5FC14zH4u/2OTessAaYkc+q2G4KhPrH2lchFJ1B75LxuGg4jOk5AXBq+Kgl73Icqezo fceaIADcCAwVjjklq5+EqUJBOcNrpp/0UMQEAovn9MgnaFtV3DhS1bRkzPBTyXsvBOha aEPA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1692750639; x=1693355439; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=M5307+EHkLHSMIGS5/gztCmUfdbxkOe/tehOVmgnURM=; b=FG9tMRv9XPGOovp7KK3hn2D2lCUuqX8ZfmouMKbVYOQfXYaVXjn1ecPKrqB4ZLsdRR iYRYgSmk4dbcjyxVz0tLZeNjEcsyPR1qzw5pmbDzOov+NEfslkP3rV5r3u2I9Pw+KPVO 4qcHc6SIyEFZ5t4lbmYnMwewm2FziKm+HToNa9WaHeBVQXMF1V7nFWwM7I8zrTwhYlHK yA7Aan1cwK2qycH1ANxB+3UBHkciszLaNY8UPHuIA42mSODUQxRLB3GKR91k7F0cjIo2 Bvbghh0JBWOyMcYSFsYzUj3SyNAIomczDayGZunrRVmIx5KXFsao30r7ElApy2HAFgcn eTow== X-Gm-Message-State: AOJu0Yx2EC5bDtqv7AOLmYb73aVwWYzNXKkZWT68cSQmhocdOzuT9ZvM pDTgJdHcU6qCPRcpmSCRy7E= X-Google-Smtp-Source: AGHT+IEqltum9XDvxOsNVoq0zRQMRQ/V0HF1zrZqDQBae7X1I2Vm0Im4RvpHt4Zgv8Tkw6U3w44mhQ== X-Received: by 2002:a05:6a20:ce84:b0:148:5933:30c9 with SMTP id if4-20020a056a20ce8400b00148593330c9mr7652166pzb.32.1692750638860; Tue, 22 Aug 2023 17:30:38 -0700 (PDT) Received: from [192.168.1.2] (cpe-76-168-148-233.socal.res.rr.com. [76.168.148.233]) by smtp.googlemail.com with ESMTPSA id c15-20020a170903234f00b001bc676df6a9sm9583210plh.132.2023.08.22.17.30.37 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 22 Aug 2023 17:30:38 -0700 (PDT) Message-ID: Date: Tue, 22 Aug 2023 17:30:37 -0700 MIME-Version: 1.0 Content-Language: en-US References: <87r0o1r1io.fsf@gmx.de> <4b4a64de-846a-ed2a-f409-80ea75e9cb57@gmail.com> <87il9crgqh.fsf@gmx.de> <87bkf4r2xd.fsf@gmx.de> <875y5cqt9a.fsf@gmx.de> <87zg2m9b4u.fsf@gmx.de> <87wmxq7zoq.fsf@gmx.de> From: Jim Porter In-Reply-To: <87wmxq7zoq.fsf@gmx.de> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: 0.0 (/) 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 (-) On 8/20/2023 3:53 AM, Michael Albinus wrote: > As POC, I've written the appended patch. It works for me in a simple > case, but I'm pretty sure it needs to handle more cases. Since I'm not > so familiar with Eshell, I let it to you :-) > > ... unless you say it is sufficient ATM. Let's just go with the change to add 'pcomplete-remote-file-ignore' for now. I'll have to think more about how Eshell can selectively ignore remote files correctly in all cases; there are a bunch of areas where Eshell could be smarter about completion already, and I have the feeling they'll conflict with each other if we don't plan this out carefully... From unknown Thu Aug 14 22:23:05 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.505 (Entity 5.505) X-Loop: help-debbugs@gnu.org From: help-debbugs@gnu.org (GNU bug Tracking System) To: Michael Albinus Subject: bug#65356: closed (Re: bug#65356: 30.0.50; [wishlist] Support Tramp method, user name and host name completion in eshell) Message-ID: References: <87fs4aqjin.fsf@gmx.de> <87r0o1r1io.fsf@gmx.de> X-Gnu-PR-Message: they-closed 65356 X-Gnu-PR-Package: emacs Reply-To: 65356@debbugs.gnu.org Date: Wed, 23 Aug 2023 07:57:02 +0000 Content-Type: multipart/mixed; boundary="----------=_1692777422-1005-1" This is a multi-part message in MIME format... ------------=_1692777422-1005-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #65356: 30.0.50; [wishlist] Support Tramp method, user name and host name c= ompletion in eshell which was filed against the emacs package, has been closed. The explanation is attached below, along with your original report. If you require more details, please reply to 65356@debbugs.gnu.org. --=20 65356: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D65356 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1692777422-1005-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 65356-done) by debbugs.gnu.org; 23 Aug 2023 07:56:48 +0000 Received: from localhost ([127.0.0.1]:60967 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qYijQ-0000Fl-8x for submit@debbugs.gnu.org; Wed, 23 Aug 2023 03:56:48 -0400 Received: from mout.gmx.net ([212.227.17.20]:35603) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qYijN-0000FW-Uv for 65356-done@debbugs.gnu.org; Wed, 23 Aug 2023 03:56:46 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.de; s=s31663417; t=1692777393; x=1693382193; i=michael.albinus@gmx.de; bh=UTs7OSN9SWo5I0CGMwTrswZST9BEsJQUzIew3PP67fQ=; h=X-UI-Sender-Class:From:To:Cc:Subject:In-Reply-To:References:Date; b=damBcqp9D2f7MXy8UVb1eAQud4ObJVVkFVAiAzEjMb1DmSE9JPwpQ8dqZ8D1lthqN28WX0L E3jR6z0SLqDt5ol05ZtycnWjcwFdUwED/zS5VvkdRRrc1cy7EhBUM8RYNe5wpTg9bypdOa47v KTY5DMV6nAv7ChTN1GqYguUgduKDB0r5Tl+y0H8ntyvzRXgU/9F3tF/Zvx1RWKQkK1MpVBnL0 EVojdeVm4f1RgWy0KasuTeifQ6hVDmXsfRTZrY42cm7yj5JDDiN/mRW4nIY7oqsf8/2qjIhY8 f9PdwwQ0JcBFE9e2GWhzHFZc9Da9unWwDqsB5mXrYqqcLXD/Wq9g== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Received: from gandalf.gmx.de ([185.89.39.16]) by mail.gmx.net (mrgmx104 [212.227.17.168]) with ESMTPSA (Nemesis) id 1Mz9Z5-1pmVcY1OIV-00wA5K; Wed, 23 Aug 2023 09:56:33 +0200 From: Michael Albinus To: Jim Porter Subject: Re: bug#65356: 30.0.50; [wishlist] Support Tramp method, user name and host name completion in eshell In-Reply-To: (Jim Porter's message of "Tue, 22 Aug 2023 17:30:37 -0700") References: <87r0o1r1io.fsf@gmx.de> <4b4a64de-846a-ed2a-f409-80ea75e9cb57@gmail.com> <87il9crgqh.fsf@gmx.de> <87bkf4r2xd.fsf@gmx.de> <875y5cqt9a.fsf@gmx.de> <87zg2m9b4u.fsf@gmx.de> <87wmxq7zoq.fsf@gmx.de> Date: Wed, 23 Aug 2023 09:56:32 +0200 Message-ID: <87fs4aqjin.fsf@gmx.de> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K1:MPsYhW+5Ztb70ldr8pWwXN7o+pSix6y2D7Yo3uLgXNK3RKa1NQ3 heQvMQ1+zbzSbYEBbAe3lSebFyqQ5i6JdV07vR55FYSY6BS2ISJmZOGR5YkBv6QxVFmeOZh ThwfE61Y9Ag69CHG05o3PPJKxxDbzxCPOQw+wupnpXPo89v075M6wbvkBr5Rz+YxZuuZj9f vtQo5Os7f63X2vxWr2QXQ== X-Spam-Flag: NO UI-OutboundReport: notjunk:1;M01:P0:qqJC1tUrXY8=;19rUIJRNLoftlA+i1Ck5qIzkv10 JvOHRFg3f69SVabU/nKGQ4WSwtWrns2+KAiUjiDtXYmTjXucmbgSPR4mS64VQj963SRuXE7j2 VOdBkXtKRJgaxwQIeKZLLGO7kzUe/ojcW26fQn9YzqGzxZvRIXjuu0hVxOqQsJZ099L4/yq4N QckCk+XLlMkXqSIL3K1pHZ9bdMllp7QlycKnkjx1GuwtyCVvf3mYZnORM/95/XWvjv5dXpZ02 2ta3D94I+vRy/xAq7qp7c+2Km6LYvF+c1FBOlJmzSI/5av/CSfgvKJipOXEl3yPQaFXzBHb+V 2pxUi6Y8rcmuUF+QibLuiXyRPS0fb9aK7QXpW/7nNcVoTfdx+xyDdSSFKQP02VRiAxZHrk85L HxH988uubQexCvrcvo+FiLFJi6atWKeL6wBZGeOQ5aLgeR+JhblmvOsyWkqbUUZUbHys5xyeh jfxi4SsnpDnPrAuoyK9r2WZZ/NomI35KX5jdLZFU74UdI4ok7L3h/dpGUnLPLyVc6MKh3yFPJ 4e5j6xd07DS2EduPNUfK+JDm8zUzJO4rhWkpjRYsfTA8YNvmc4yQ57XHYdjOd9LH4M/yqNy4o cbSKpBaXYW3OJPhCaQuNX380I6EdHQEPjkRNfd7RdC6+SRiJfLjJxCufOQmN7aHEk1+eHzNVI UOPSGxKT00aVU7ocg8Cws+RyaT3dpzJZ6GN5zoieV1H4XEECa/WzmPSOHRPexdJt7RMwcH6cR 3q4Q+/Hcs658SCHvg4nYaCMkgLYk6atBetWgRcOsrRyZU3B/KgY3nb5pYmiEZ5CDi4bIFF3IY esH8y7eEo6mHowa9x5LEE03QskGiBeLWRN30ijodyhGGZ+XwEKzepNjrQJp/UY1CIwcqUzcZQ tnYfIASxwLbBMF56VmTFSoRH0Yb7cjZA6814Bs7ajT0Zojut1l4O+A9q9Sc4RYVn+TEpJ2D7E cO/4XgaqAOtuaLAz0uaMWMmz8Zw= X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 65356-done Cc: 65356-done@debbugs.gnu.org, Stefan Monnier 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.7 (-) Version: 30.1 Jim Porter writes: Hi Jim, > Let's just go with the change to add 'pcomplete-remote-file-ignore' > for now. I'll have to think more about how Eshell can selectively > ignore remote files correctly in all cases; there are a bunch of areas > where Eshell could be smarter about completion already, and I have the > feeling they'll conflict with each other if we don't plan this out > carefully... Agreed. Pushed to master, I'm closing the bug. Best regards, Michael. ------------=_1692777422-1005-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 17 Aug 2023 18:02:13 +0000 Received: from localhost ([127.0.0.1]:45521 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qWhJy-0008Uk-57 for submit@debbugs.gnu.org; Thu, 17 Aug 2023 14:02:13 -0400 Received: from lists.gnu.org ([2001:470:142::17]:41372) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qWhJt-0008UB-5C for submit@debbugs.gnu.org; Thu, 17 Aug 2023 14:02:08 -0400 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 1qWhJn-0003Xq-5J for bug-gnu-emacs@gnu.org; Thu, 17 Aug 2023 14:01:59 -0400 Received: from mout.gmx.net ([212.227.17.20]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qWhJj-0006Rw-Fu for bug-gnu-emacs@gnu.org; Thu, 17 Aug 2023 14:01:58 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.de; s=s31663417; t=1692295312; x=1692900112; i=michael.albinus@gmx.de; bh=bRwWy2paAT5kiXJMSKshl8LObe6PjXpsYT0DGU0ETmg=; h=X-UI-Sender-Class:From:To:Subject:Date; b=aI0Rfj5ujCb6qdquEA/Vid9nO7pqH/WXKHXLsZ2d3lFywjAKd/u459rUk2opsIOCX13Uym/ iLzJtvN92DBJ2Jtpt1Zv7T1PeFn+TkJ8ze7+yaEgDDGLJ2g80EynrhQydhGdPvLdIdfg+QGi9 x13LkHsEwJc05Jp8hNoXIPiK0uFXj2v6y7oBMIr70COzRx9SESSzN+9xdc8NmC5qgacLQGDYA NGczjNqAiFeeO9JX44I7KxOWJQYNUZPGYw6KEbPQNfTUXGstKN+NLnPxL5+WYXUf+DZw5jdvd HRotXBvvI+4i7N359DMdswOYM+Vk7dPw9zEUNmAD5piwpy/vdHZQ== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Received: from gandalf.gmx.de ([185.89.39.27]) by mail.gmx.net (mrgmx105 [212.227.17.168]) with ESMTPSA (Nemesis) id 1ML9yc-1qETyX3jNK-00IHL0; Thu, 17 Aug 2023 20:01:52 +0200 From: Michael Albinus To: bug-gnu-emacs@gnu.org Subject: 30.0.50; [wishlist] Support Tramp method, user name and host name completion in eshell X-Debbugs-Cc: Jim Porter Date: Thu, 17 Aug 2023 20:01:51 +0200 Message-ID: <87r0o1r1io.fsf@gmx.de> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Provags-ID: V03:K1:B+pYvSMQb2Ua79+zMSCu/w7qI5m/1+RyJHVvohpspfyd2QhMN46 x6Vi3kdX7g2ko3nZY1A0to64CFLIOwiBbT06Vp88MzMPq1UtwVfOp/7l2OoqDp6+NamefY7 lyBBq8+Lvq2ct/aZ7FungJX7PzvlTed2FFRpvg8Tjb87YzekP9J5iGAknoeCw8DVskHNAAz FamRPKgc0I2e3Ti6Wv0hw== X-Spam-Flag: NO UI-OutboundReport: notjunk:1;M01:P0:GzEYhx59sEE=;6bGUy8mZpxeWRobzLLX2YOg7LOQ KQtYPZyoNW4F9hZPtYDe8mW5d51RSk9tzdwLSsydV36jrz9+TWxXqAYy1KyZlxOidEFEcgThp sqML2OYpzeRzbfPh9tlkPI16p0n1xrmTK0/M7wMXXwgExo/jLqdrGATxG8NOFakPNaQJMDyIQ xd/frhvYG4U8rDpbc8PxLBWK/sIVRFazg8oVFlg47TR5crCUV/1D/VU6Nu6AdKiqSGkeLbE+H LR/VN6b9gNxD8PpcVrph1uvebauYjtBqfT8ySE+VluiynKGYoDROVHkfowI25SV882AtWBy49 glBKZ9+Pb0+s1yUEsXOLs1N+W8knSgBakWeUzfubVDy7bzHLFKmXsClgtUL14yQEFYj1nd6S/ XdoSJbNoQvJEanGZdF5xwkBeZg3IPaQhGUsxCiKFSRTXXNXjIuZ1CMU6TSRVNNjXCe9CeEBkk 045zy/7gHH8xkBQhmvL8nYLGonLkjfson1ICLbRL2462vw0NuwDWNgEd+BmqkI3e4cNOG45Pb J7bSzQs1Qex6FDSV+l5kopJKFKbkKSDw4vTlGqDeWf1mxu39NH/KzIUynPtnvyiaLHsqrjLNT pMhI4axYy3txlGUycOkqRmh5a4e/vib8v3XBpOVnxuR2FkIZU9TOhP1KxvPy3dRmwqOvBLFkf nlleDxJrkvjrtIrNGuycALP5mCtQhT+6DEGEzfLeZ2hjwEygQ5opzwjlOHJDjaRNfikJndH9r cxYjx09cGlTCAM6lUgLUPU3v56pekzAiLk2Go77KU65P/Kq3Um0gKLxYDre3H8kCDml591/cO nEG7m0cI8RrKwYqrle+ubO70s60VDGZM9F9mLpkBScs3u/eaLc9ahL/EfQTCNrkA2+4isslns /NJe/PW7ySnKRPBghpIaDdJP0P+xRpvWAa1/vIKEI8hSqq4xMy01QgOI0eoiTcJ0wappiKWjG 9HQxvyHYmrnGOKisQfYckzD/nGQ= Received-SPF: pass client-ip=212.227.17.20; envelope-from=michael.albinus@gmx.de; helo=mout.gmx.net X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: 1.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: -0.0 (/) --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable When we open a file with find-file, the minibuffer offers method, user name and host name completion for remote files. That is, after typing "C-x C-f /ss TAB" we're offered with the completions "ssh:", "sshfs:" and "sshx:". Same for user name and host name. In eshell, this feature does not exist. I would like if I could type "cd /ss TAB" and could see the same offering of "ssh:", "sshfs:" and "sshx:". Same for user name and host name. The appended patch does this for me. I have no idea how good it fits into the eshell machinery, for example whether there are problems with the em-elecslash.el module. Comments welcome! Disclaimer: The idea has appeared on . Best regards, Michael. In GNU Emacs 30.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.38, cairo version 1.17.8) of 2023-08-15 built on gandalf Repository revision: 5c101b1adac2b4f3cc4e08a6492b406952c529f3 Repository branch: master Windowing system distributor 'The X.Org Foundation', version 11.0.12201009 System Description: Fedora Linux 38 (Workstation Edition) Configured using: 'configure --with-tree-sitter' Configured features: ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GPM GSETTINGS HARFBUZZ JPEG LIBOTF LIBSELINUX LIBXML2 M17N_FLT MODULES NOTIFY INOTIFY PDUMPER PNG RSVG SECCOMP SOUND SQLITE3 THREADS TIFF TOOLKIT_SCROLL_BARS TREE_SITTER X11 XDBE XIM XINPUT2 XPM GTK3 ZLIB Important settings: value of $LANG: en_US.UTF-8 value of $XMODIFIERS: @im=3Dibus locale-coding-system: utf-8 Major mode: ELisp/l Minor modes in effect: debbugs-browse-mode: t bug-reference-prog-mode: t display-time-mode: t delete-selection-mode: t icomplete-mode: t global-goto-address-mode: t goto-address-mode: t tooltip-mode: t global-eldoc-mode: t eldoc-mode: t show-paren-mode: t electric-indent-mode: t mouse-wheel-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t column-number-mode: t line-number-mode: t transient-mark-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t Load-path shadows: /home/albinus/src/elpa/packages/debbugs/debbugs hides /home/albinus/.emacs= .d/elpa/debbugs-0.36/debbugs /home/albinus/src/elpa/packages/debbugs/debbugs-org hides /home/albinus/.e= macs.d/elpa/debbugs-0.36/debbugs-org /home/albinus/src/elpa/packages/debbugs/debbugs-gnu hides /home/albinus/.e= macs.d/elpa/debbugs-0.36/debbugs-gnu /home/albinus/src/elpa/packages/debbugs/debbugs-guix hides /home/albinus/.= emacs.d/elpa/debbugs-0.36/debbugs-guix /home/albinus/src/elpa/packages/debbugs/debbugs-browse hides /home/albinus= /.emacs.d/elpa/debbugs-0.36/debbugs-browse /home/albinus/src/elpa/packages/debbugs/debbugs-pkg hides /home/albinus/.e= macs.d/elpa/debbugs-0.36/debbugs-pkg /home/albinus/src/elpa/packages/debbugs/debbugs-autoloads hides /home/albi= nus/.emacs.d/elpa/debbugs-0.36/debbugs-autoloads /home/albinus/src/elpa/packages/debbugs/debbugs-compat hides /home/albinus= /.emacs.d/elpa/debbugs-0.36/debbugs-compat ~/lisp/telepathy hides /home/albinus/.emacs.d/elpa/telepathy-20131209.1258= /telepathy /home/albinus/src/elpa/packages/tramp-theme/tramp-theme-autoloads hides /h= ome/albinus/.emacs.d/elpa/tramp-theme-0.2/tramp-theme-autoloads /home/albinus/src/elpa/packages/tramp-theme/tramp-theme hides /home/albinu= s/.emacs.d/elpa/tramp-theme-0.2/tramp-theme /home/albinus/src/elpa/packages/tramp-theme/tramp-theme-pkg hides /home/al= binus/.emacs.d/elpa/tramp-theme-0.2/tramp-theme-pkg /home/albinus/.emacs.d/elpa/hydra-0.15.0/lv hides /home/albinus/.emacs.d/e= lpa/lv-0.15.0/lv /home/albinus/src/tramp/lisp/tramp-sh hides /usr/local/share/emacs/site-li= sp/tramp-sh /home/albinus/src/tramp/lisp/tramp-cmds hides /usr/local/share/emacs/site-= lisp/tramp-cmds /home/albinus/src/tramp/lisp/tramp-gvfs hides /usr/local/share/emacs/site-= lisp/tramp-gvfs /home/albinus/src/tramp/lisp/tramp-ftp hides /usr/local/share/emacs/site-l= isp/tramp-ftp /home/albinus/src/tramp/lisp/tramp-crypt hides /usr/local/share/emacs/site= -lisp/tramp-crypt /home/albinus/src/tramp/lisp/tramp-adb hides /usr/local/share/emacs/site-l= isp/tramp-adb /home/albinus/src/tramp/lisp/tramp hides /usr/local/share/emacs/site-lisp/= tramp /home/albinus/src/tramp/lisp/tramp-cache hides /usr/local/share/emacs/site= -lisp/tramp-cache /home/albinus/src/tramp/lisp/tramp-rclone hides /usr/local/share/emacs/sit= e-lisp/tramp-rclone /home/albinus/src/tramp/lisp/tramp-compat hides /usr/local/share/emacs/sit= e-lisp/tramp-compat /home/albinus/src/tramp/lisp/tramp-integration hides /usr/local/share/emac= s/site-lisp/tramp-integration /home/albinus/src/tramp/lisp/tramp-archive hides /usr/local/share/emacs/si= te-lisp/tramp-archive /home/albinus/src/tramp/lisp/tramp-sudoedit hides /usr/local/share/emacs/s= ite-lisp/tramp-sudoedit /home/albinus/src/tramp/lisp/tramp-loaddefs hides /usr/local/share/emacs/s= ite-lisp/tramp-loaddefs /home/albinus/src/tramp/lisp/tramp-uu hides /usr/local/share/emacs/site-li= sp/tramp-uu /home/albinus/src/tramp/lisp/tramp-smb hides /usr/local/share/emacs/site-l= isp/tramp-smb /home/albinus/src/tramp/lisp/trampver hides /usr/local/share/emacs/site-li= sp/trampver /home/albinus/.emacs.d/elpa/transient-20230602.2121/transient hides /usr/l= ocal/share/emacs/30.0.50/lisp/transient ~/lisp/dbus hides /usr/local/share/emacs/30.0.50/lisp/net/dbus /home/albinus/src/tramp/lisp/tramp-sh hides /usr/local/share/emacs/30.0.50= /lisp/net/tramp-sh /home/albinus/src/tramp/lisp/tramp-fuse hides /usr/local/share/emacs/30.0.= 50/lisp/net/tramp-fuse /home/albinus/src/tramp/lisp/tramp-loaddefs hides /usr/local/share/emacs/3= 0.0.50/lisp/net/tramp-loaddefs /home/albinus/src/tramp/lisp/tramp-ftp hides /usr/local/share/emacs/30.0.5= 0/lisp/net/tramp-ftp /home/albinus/src/tramp/lisp/tramp hides /usr/local/share/emacs/30.0.50/li= sp/net/tramp /home/albinus/src/tramp/lisp/tramp-cache hides /usr/local/share/emacs/30.0= .50/lisp/net/tramp-cache /home/albinus/src/tramp/lisp/tramp-uu hides /usr/local/share/emacs/30.0.50= /lisp/net/tramp-uu /home/albinus/src/tramp/lisp/tramp-rclone hides /usr/local/share/emacs/30.= 0.50/lisp/net/tramp-rclone /home/albinus/src/tramp/lisp/tramp-integration hides /usr/local/share/emac= s/30.0.50/lisp/net/tramp-integration /home/albinus/src/tramp/lisp/tramp-archive hides /usr/local/share/emacs/30= .0.50/lisp/net/tramp-archive /home/albinus/src/tramp/lisp/tramp-adb hides /usr/local/share/emacs/30.0.5= 0/lisp/net/tramp-adb /home/albinus/src/tramp/lisp/tramp-cmds hides /usr/local/share/emacs/30.0.= 50/lisp/net/tramp-cmds /home/albinus/src/tramp/lisp/tramp-compat hides /usr/local/share/emacs/30.= 0.50/lisp/net/tramp-compat /home/albinus/src/tramp/lisp/tramp-sudoedit hides /usr/local/share/emacs/3= 0.0.50/lisp/net/tramp-sudoedit /home/albinus/src/tramp/lisp/tramp-container hides /usr/local/share/emacs/= 30.0.50/lisp/net/tramp-container /home/albinus/src/tramp/lisp/tramp-gvfs hides /usr/local/share/emacs/30.0.= 50/lisp/net/tramp-gvfs /home/albinus/src/tramp/lisp/tramp-crypt hides /usr/local/share/emacs/30.0= .50/lisp/net/tramp-crypt /home/albinus/src/tramp/lisp/tramp-message hides /usr/local/share/emacs/30= .0.50/lisp/net/tramp-message /home/albinus/src/tramp/lisp/tramp-smb hides /usr/local/share/emacs/30.0.5= 0/lisp/net/tramp-smb /home/albinus/src/tramp/lisp/trampver hides /usr/local/share/emacs/30.0.50= /lisp/net/trampver /home/albinus/src/tramp/lisp/tramp-sshfs hides /usr/local/share/emacs/30.0= .50/lisp/net/tramp-sshfs Features: (shadow sort mail-extr warnings emacsbug message yank-media puny rfc822 mml mml-sec epa derived epg rfc6068 epg-config gnus-util mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils cl-print cl-extra find-func shortdoc em-xtra em-unix em-tramp em-term term disp-table ehelp em-script em-prompt em-pred em-ls em-hist em-glob em-cmpl em-dirs em-basic em-banner em-alias esh-mode esh-var eshell esh-cmd generator esh-ext esh-opt esh-proc esh-io esh-arg esh-module esh-groups esh-util help-fns radix-tree mule-util display-line-numbers pulse color find-dired xref project grep compile text-property-search misearch multi-isearch ediff-vers ediff ediff-merg ediff-mult ediff-wind ediff-diff ediff-help ediff-init ediff-util vc-git diff-mode easy-mmode debbugs-browse bug-reference dired-aux face-remap ob-shell ob ob-tangle ol org-src ob-ref ob-lob ob-table ob-exp ob-comint ob-core org-cycle org-fold org-fold-core ob-eval org-keys oc org-compat org-version org-macs vc vc-dispatcher time tramp-cache time-stamp tramp-sh lxc-tramp lxd-tramp tramp trampver tramp-integration files-x tramp-message help-mode tramp-compat xdg shell pcomplete comint ansi-osc ring parse-time iso8601 time-date format-spec ansi-color tramp-loaddefs rx delsel ido jka-compr icomplete cus-edit pp cus-load icons wid-edit dired dired-loaddefs goto-addr thingatpt alert-autoloads android-mode-autoloads auth-source-gopass-autoloads auth-source-keytar-autoloads auth-source-kwallet-autoloads auth-source-xoauth2-autoloads auto-sudoedit-autoloads auto-virtualenv-autoloads auto-virtualenvwrapper-autoloads clang-format-autoloads company-shell-autoloads company-autoloads counsel-toki-autoloads counsel-tramp-autoloads counsel-autoloads dbus-codegen-autoloads debbugs-autoloads dired-du-autoloads dired-rsync-autoloads direnv-autoloads disk-usage-autoloads dockerfile-mode-autoloads ednc-autoloads el-get-autoloads envrc-autoloads exec-path-from-shell-autoloads fontaine-autoloads forge-autoloads closql-autoloads emacsql-autoloads friendly-tramp-path-autoloads ggtags-autoloads ghub-autoloads gited-autoloads gitlab-ci-mode-flycheck-autoloads gitlab-ci-mode-autoloads flycheck-autoloads gntp-autoloads gnus-desktop-notify-autoloads helm-gitlab-autoloads helm-projectile-autoloads helm-autoloads helm-core-autoloads async-autoloads ibuffer-tramp-autoloads inheritenv-autoloads ivy-gitlab-autoloads gitlab-autoloads jarchive-autoloads journalctl-mode-autoloads keepass-mode-autoloads keytar-autoloads kubel-autoloads kubernetes-autoloads log4e-autoloads lsp-java-autoloads dap-mode-autoloads lsp-docker-autoloads bui-autoloads lsp-treemacs-autoloads lsp-mode-autoloads lxc-tramp-autoloads lxd-tramp-autoloads magit-filenotify-autoloads magit-autoloads pcase git-commit-autoloads magit-popup-autoloads magit-section-autoloads marcopolo-autoloads nexus-autoloads nnir-est-autoloads oauth2-autoloads ob-restclient-autoloads orderless-autoloads org-tree-slide-autoloads pkg-info-autoloads epl-autoloads popup-autoloads projectile-autoloads promise-autoloads pyenv-mode-autoloads pylint-autoloads python-environment-autoloads deferred-autoloads pythonic-autoloads f-autoloads pyvenv-autoloads recentf-remove-sudo-tramp-prefix-autoloads relint-autoloads request-autoloads restclient-test-autoloads restclient-autoloads s3ed-autoloads finder-inf slime-autoloads macrostep-autoloads spinner-autoloads ssh-deploy-autoloads swiper-autoloads ivy-autoloads sx-autoloads markdown-mode-autoloads telepathy-autoloads tramp-theme-autoloads transient-dwim-autoloads transient-autoloads treemacs-autoloads cfrs-autoloads posframe-autoloads ht-autoloads pfuture-autoloads ace-window-autoloads avy-autoloads treepy-autoloads urgrep-autoloads uuid-autoloads vdiff-autoloads hydra-autoloads lv-autoloads vertico-autoloads virtualenv-autoloads virtualenvwrapper-autoloads s-autoloads dash-autoloads web-server-autoloads with-editor-autoloads info compat-autoloads xr-autoloads yaml-autoloads yaml-mode-autoloads package browse-url url url-proxy url-privacy url-expand url-methods url-history url-cookie generate-lisp-file url-domsuf url-util mailcap url-handlers url-parse auth-source cl-seq eieio eieio-core cl-macs password-cache json subr-x map byte-opt gv bytecomp byte-compile url-vars cl-loaddefs cl-lib rmc iso-transl tooltip cconv eldoc paren electric uniquify ediff-hook vc-hooks lisp-float-type elisp-mode mwheel term/x-win x-win term/common-win x-dnd touch-screen tool-bar dnd fontset image regexp-opt fringe tabulated-list replace newcomment text-mode lisp-mode prog-mode register page tab-bar menu-bar rfn-eshadow isearch easymenu timer select scroll-bar mouse jit-lock font-lock syntax font-core term/tty-colors frame minibuffer nadvice seq simple cl-generic indonesian philippine cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese composite emoji-zwj charscript charprop case-table epa-hook jka-cmpr-hook help abbrev obarray oclosure cl-preloaded button loaddefs theme-loaddefs faces cus-face macroexp files window text-properties overlay sha1 md5 base64 format env code-pages mule custom widget keymap hashtable-print-readable backquote threads dbusbind inotify dynamic-setting system-font-setting font-render-setting cairo gtk x-toolkit xinput2 x multi-tty move-toolbar make-network-process emacs) Memory information: ((conses 16 234759 52920) (symbols 48 19742 1) (strings 32 66564 4085) (string-bytes 1 2281459) (vectors 16 40066) (vector-slots 8 1166864 141729) (floats 8 244 2758) (intervals 56 11249 545) (buffers 992 27)) --=-=-= Content-Type: text/x-patch Content-Disposition: attachment Content-Transfer-Encoding: quoted-printable diff --git a/lisp/eshell/em-tramp.el b/lisp/eshell/em-tramp.el index 94eb9797033..c90e689f6de 100644 =2D-- a/lisp/eshell/em-tramp.el +++ b/lisp/eshell/em-tramp.el @@ -51,11 +51,23 @@ eshell-tramp-initialize "Initialize the Tramp-using commands code." (when (eshell-using-module 'eshell-cmpl) (add-hook 'pcomplete-try-first-hook - 'eshell-complete-host-reference nil t)) + 'eshell-complete-partial-tramp-file-name)) (setq-local eshell-complex-commands (append '("su" "sudo" "doas") eshell-complex-commands))) +(defun eshell-complete-partial-tramp-file-name () + "Complete a partial Tramp file name (method, user name, hostname)." + (let ((arg (pcomplete-actual-arg)) + (non-essential t) + (minibuffer-completing-file-name t)) + (when (string-match tramp-completion-file-name-regexp arg) + (setq pcomplete-stub (substring arg (length tramp-prefix-format)) + pcomplete-last-completion-raw t + pcomplete-termination-string "") + (throw 'pcomplete-completions + (file-name-all-completions pcomplete-stub tramp-prefix-forma= t))))) + (autoload 'eshell-parse-command "esh-cmd") (defun eshell/su (&rest args) --=-=-=-- ------------=_1692777422-1005-1-- From debbugs-submit-bounces@debbugs.gnu.org Sat Nov 02 14:56:35 2024 Received: (at control) by debbugs.gnu.org; 2 Nov 2024 18:56:35 +0000 Received: from localhost ([127.0.0.1]:55040 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1t7JIZ-0004xn-C8 for submit@debbugs.gnu.org; Sat, 02 Nov 2024 14:56:35 -0400 Received: from mail-pl1-f169.google.com ([209.85.214.169]:60485) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1t7JIX-0004xc-16; Sat, 02 Nov 2024 14:56:33 -0400 Received: by mail-pl1-f169.google.com with SMTP id d9443c01a7336-20c805a0753so27409805ad.0; Sat, 02 Nov 2024 11:56:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1730573732; x=1731178532; darn=debbugs.gnu.org; h=content-transfer-encoding:in-reply-to:from:references:to :content-language:subject:mime-version:date:message-id:from:to:cc :subject:date:message-id:reply-to; bh=VecpgVRtetmlSwP/yM8atmsjdgEz817tiyc1cRoykj0=; b=KzetzeDJEVK+y3GyzpZXCHCi4dCMoVGUPVGd+ws1OWYTikb2PRR7z89WY8p05dZgZo /vtbfDrPcRtlzzSGNtiGEfuKwbgpyqdF1Y/pzuk0BIuzdLPKdc6+2wdMEKBz1pN0Mz85 y/AtHyBXemeHR9RTcvFChWRc+Mj1JElLimXjWw7yhb6xAgPBNLLY53SnPXQyKydjGmSD v2iWzEIMxdXjmb4y7vErJ+9SbfPIRva/nXhnXn1Uo7fIAut/omFynTaZn5SwjHXeB++r WIHGL8gW8t5ZGz2Cg7bUhX8KE2/odeyZkKKMdfxeNQXbZ/tpCpGtybMYJnMx6irPM53q SwVA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1730573732; x=1731178532; h=content-transfer-encoding:in-reply-to:from:references:to :content-language:subject:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=VecpgVRtetmlSwP/yM8atmsjdgEz817tiyc1cRoykj0=; b=CwOk1q/6VNLlT+EC1Jm0+YpeEIImh3o9LnttbDmu0/T0xFh48itSYTZfdwjxsI7cHU XQ5q8hLmJ/9byKPFFg/Wks4H6CGxbUSfKSjdi3JaLg5m5UnOVFOTWz08mG4MGNftOVl2 DxFQHYj2qBARQM5YWJLZPW7CwKvMAqlkCwtFcgjmDmI3Fnl1m67+wGE44YxNJDQN3NRW tQ/zu1FC2EvZ5KIN0OWSpNSmj75b2HElzbZiKBN7McsxppeAmvxmYNvpAve5qtQ4RWbR k24nMBpvL8dc2ryfiMq8KttnGVn3tsTz05L2/P7kX0cixDcAZ4sC5a1p9L5hKFZfISNi DaPg== X-Forwarded-Encrypted: i=1; AJvYcCVqEBxMNbEguVlCTr/eUI+/SfjSbeaZIwn6Y6aB59dY7jzkoaK4j8D97IUiDRZKCadd9QTBJjnG7Q==@debbugs.gnu.org, AJvYcCWBAsVNzPnRNs09U6y1a5ftWEHBricCFGdOBwGWQo35W1p6viMn71Bl5cqYENggxVCLJPOTHA==@debbugs.gnu.org X-Gm-Message-State: AOJu0Yyy0VdDVBiHYkP0nrHttobBvrdkSA0E+6m4RiEQZ+yAxtGIuE8q jv9+vDabbD2r223hluC1rjwMAI+TMcNxM9dulizczLTWI2fwYXuq X-Google-Smtp-Source: AGHT+IH2CBn6plS3VUW3c+7n/8qfzihOnWcwfXEfxpLgrx6SCFGn3/W7dex8b7bFrALwQ+qVBVVEVw== X-Received: by 2002:a17:902:cecd:b0:20c:a97d:cc7f with SMTP id d9443c01a7336-210c6c3ec78mr385491625ad.41.1730573732039; Sat, 02 Nov 2024 11:55:32 -0700 (PDT) Received: from [192.168.1.2] (syn-023-240-098-037.res.spectrum.com. [23.240.98.37]) by smtp.googlemail.com with ESMTPSA id d9443c01a7336-211057a2bddsm36212045ad.134.2024.11.02.11.55.30 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sat, 02 Nov 2024 11:55:31 -0700 (PDT) Message-ID: <8af71f27-a0e1-4c0d-33bc-163c74ac15c1@gmail.com> Date: Sat, 2 Nov 2024 11:55:31 -0700 MIME-Version: 1.0 Subject: Re: bug#74177: 29.4; SSH host completion does not work using the TRAMP-SSH-Method in eshell Content-Language: en-US To: Olivier Rojon , 74177@debbugs.gnu.org References: <87bjyxg1lk.fsf@linux.fritz.box> From: Jim Porter In-Reply-To: <87bjyxg1lk.fsf@linux.fritz.box> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: control 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 (-) unarchive 65356 forcemerge 65356 74177 thanks On 11/2/2024 7:19 AM, Olivier Rojon wrote: > I don't know if this is a bug proper or a feature request. As stated in the Subject, the > completion of SSH hosts as read from ~/.ssh/config and ~/.ssh/known_hosts does not work > when using the /ssh:-TRAMP-Method in eshell. Thanks for the bug report. This is bug#65356[1], which is fixed in Emacs 30. Marking as a dupe. [1] https://debbugs.gnu.org/cgi/bugreport.cgi?bug=65356