From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: =?UTF-8?Q?K=C3=A9vin?= Le Gouguec Newsgroups: gmane.emacs.bugs Subject: bug#26661: compile, shell etc. should use bash-completion ! Date: Thu, 03 Sep 2020 00:10:29 +0200 Message-ID: <87h7sf6d9m.fsf@gmail.com> References: <878tmoxdno.fsf@jidanni.org> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="20266"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cc: 26661@debbugs.gnu.org, =?UTF-8?Q?=E7=A9=8D=E4=B8=B9=E5=B0=BC?= Dan Jacobson To: Stefan Kangas Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Sep 03 00:11:11 2020 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kDayE-00058g-DT for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 03 Sep 2020 00:11:10 +0200 Original-Received: from localhost ([::1]:54496 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kDayD-0002d8-EL for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 02 Sep 2020 18:11:09 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:57302) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kDay6-0002ar-8O for bug-gnu-emacs@gnu.org; Wed, 02 Sep 2020 18:11:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:49447) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kDay5-0004kw-Vi for bug-gnu-emacs@gnu.org; Wed, 02 Sep 2020 18:11:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kDay5-0007Ic-RB for bug-gnu-emacs@gnu.org; Wed, 02 Sep 2020 18:11:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: =?UTF-8?Q?K=C3=A9vin?= Le Gouguec Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 02 Sep 2020 22:11:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 26661 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: notabug wontfix Original-Received: via spool by 26661-submit@debbugs.gnu.org id=B26661.159908464128027 (code B ref 26661); Wed, 02 Sep 2020 22:11:01 +0000 Original-Received: (at 26661) by debbugs.gnu.org; 2 Sep 2020 22:10:41 +0000 Original-Received: from localhost ([127.0.0.1]:60993 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kDaxk-0007Hx-Qx for submit@debbugs.gnu.org; Wed, 02 Sep 2020 18:10:41 -0400 Original-Received: from mail-wm1-f44.google.com ([209.85.128.44]:54930) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kDaxh-0007Hh-Aw for 26661@debbugs.gnu.org; Wed, 02 Sep 2020 18:10:39 -0400 Original-Received: by mail-wm1-f44.google.com with SMTP id s13so844472wmh.4 for <26661@debbugs.gnu.org>; Wed, 02 Sep 2020 15:10:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=L1QMfHSk1cUTezj/b3jUR5FxwYPxdYt+BznkFuOhgGQ=; b=uQUi376gkqFyG6xSqfMRXpyyuotfEiBu0KTvP9GremQvgWmDu0JiPR5q77wumUgHvq gDnL0ECwrzDAl+3XkRygx+XdC8x2Jp/ecvN3Fk7iN9swn0pawNaNwGbu4a8fIZ1Nnksi Vz9xrd69MUBu4pApYDrzve9KvC+MaOUai1dvkaLEjuYdYH+z3ZsjxKd0ILjMimbLCMMd JtpkTcX88eyFiQbah2PzS7rquVmACBSjNXDFNoTWfgcx78ucaWb2GPtvj+su/qXL7XyL PtNXlYGwXUWRjNDpvhy4jSSDkcyaNc8aV8InKayqgFs37Fdu1oxnS/W9fPCGxKIaPaYL EJdQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=L1QMfHSk1cUTezj/b3jUR5FxwYPxdYt+BznkFuOhgGQ=; b=lcHjUjlfRi5A4AgrLptcOtkp5ZY6x3qQjNcBWwkCHPWQTmyOHhU8Enmp6fYw6v0gb9 yMYN1fuubAF6NQWU2VZvJEQ42RPsUJlthYhso8X2s3aTPAutz66HHsDb5WqO00Q1YKYz hEs2++dHxML8Zd299rCwhLhGI58uvR3LjTSS8rgeIXNjkerwh9ZKAVK78e8fiKpk8gkj jIBmk+ySnFao5UXHGoLpSPP/BcjqdQ3xRuwSyeEHRRz9bY1VoGz406+S6UgRNeEwhXaK i/T9VG1NcYTgtruFmorAVJBuHEt+OrVBEqwWYW9QetjVIKXmoPT5sNzP5qBqA0mtDU5j D1uQ== X-Gm-Message-State: AOAM533aZi1mKmzegHAsRAGvGD4P7xEcngR7fhtQ2RR6qXlXIPV3I7lc VaKDmKUBfwNZJmzgt6FG3XoJEuI178+GQQ== X-Google-Smtp-Source: ABdhPJyDsL8fo5olvYmMMMLZcaokSPhC4Clttw+aAFSpcFnUPklQwpqVMqAqTY3LXeAK8qbIKjMn+A== X-Received: by 2002:a7b:c2aa:: with SMTP id c10mr243938wmk.86.1599084631088; Wed, 02 Sep 2020 15:10:31 -0700 (PDT) Original-Received: from my-little-tumbleweed (200.143.13.109.rev.sfr.net. [109.13.143.200]) by smtp.gmail.com with ESMTPSA id m3sm1439977wmb.26.2020.09.02.15.10.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 02 Sep 2020 15:10:30 -0700 (PDT) In-Reply-To: (Stefan Kangas's message of "Tue, 1 Sep 2020 16:14:57 -0700") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:186968 Archived-At: Stefan Kangas writes: > I'm also not exactly sure how integrating bash completion with Emacs > would work. Bash completion consists of a number of highly > bash-specific scripts. It would take significant effort to write an > Emacs parser for them. > > It seems like a better idea for people to spend time on making pcomplete > extensions for more commands. But that would be outside the scope of > this feature request, I think. Out of curiosity, couldn't shell-mode (and M-x compile et al.) do what python-mode does, i.e. ask the interpreter's "completion API" for candidates when the user hits TAB? I think that's what the "bash-completion" package from MELPA does[1]; this approach would allow Emacs to leverage Bash's programmable completion with no special support for specific commands. (Apologies if I've misunderstood something, I've only very quickly glanced at python.el and bash-completion's internals.) [1] https://raw.githubusercontent.com/szermatt/emacs-bash-completion/master/bash-completion.el See e.g. bash-completion--setup-bash-common which runs "complete -p".