From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Dmitry Gutov Newsgroups: gmane.emacs.devel Subject: Re: Project support and completions (Was: Re: bug#19466: 25.0.50; xref-find-def doesn't find C functions) Date: Sun, 25 Jan 2015 01:25:12 +0200 Message-ID: <54C429D8.6010302@yandex.ru> References: <8361cucl3u.fsf@gnu.org> <54A230CD.3040309@yandex.ru> <83vbktb1ct.fsf@gnu.org> <54A2EE15.3020406@yandex.ru> <831tnhasx0.fsf@gnu.org> <54A6DAF6.5070605@yandex.ru> <831tna9tmr.fsf@gnu.org> <54A9C94F.8040701@yandex.ru> <83vbkl99vm.fsf@gnu.org> <54B8878A.4050506@yandex.ru> <54B8C22B.3080200@gmx.at> <54BC7A77.5020307@yandex.ru> <54BCC033.2010104@gmx.at> <83oapuy8ew.fsf@gnu.org> <54BDC34C.5070309@yandex.ru> <83wq4hwejl.fsf@gnu.org> <54BEBF63.9050709@yandex.ru> <8361c0w16n.fsf@gnu.org> <54C063E3.8020401@yandex.ru> <83a91avglz.fsf@gnu.org> <54C1655E.4050403@yandex.ru> <83r3uluawd.fsf@gnu.org> <54C28635.8070606@yandex.ru> <83twzhryyq.fsf@gnu.org> <54C2C9DC.1050908@yandex.ru> <83h9vgsehi.fsf@gnu.org> <54C3E7B6.2020006@yandex.ru> <837fwbstls.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1422141952 5154 80.91.229.3 (24 Jan 2015 23:25:52 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 24 Jan 2015 23:25:52 +0000 (UTC) Cc: emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Jan 25 00:25:47 2015 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1YFA5L-0000rT-5R for ged-emacs-devel@m.gmane.org; Sun, 25 Jan 2015 00:25:47 +0100 Original-Received: from localhost ([::1]:36366 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YFA5J-0005Ro-WD for ged-emacs-devel@m.gmane.org; Sat, 24 Jan 2015 18:25:46 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:45110) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YFA4y-0005RT-Fn for emacs-devel@gnu.org; Sat, 24 Jan 2015 18:25:26 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YFA4v-0002px-9r for emacs-devel@gnu.org; Sat, 24 Jan 2015 18:25:24 -0500 Original-Received: from mail-wi0-x229.google.com ([2a00:1450:400c:c05::229]:64242) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YFA4v-0002pj-3Z; Sat, 24 Jan 2015 18:25:21 -0500 Original-Received: by mail-wi0-f169.google.com with SMTP id h11so3005341wiw.0; Sat, 24 Jan 2015 15:25:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; bh=+MmFgAe/9SI0wkMG5OlxPC8NFPwmYdZpzIomgDlaWp8=; b=OZIsZTUowPDBiZKrNxYWTnMJNQgwY2Ra2wn61f2EmP0VewbHcjr7C7XV/0pYmQbtds YCEnoAawa0ZcmEE25tWUhXsklLolWBzld/EnGBlvaQW9hx2b7XbpsPeehvOxKSB/QJ9F Z0E6TDVmC8nd1EOpOrOfqo3G/UghyVW8k574oXvqX5DLj5SbeHB2U4SyIoB1qDAFrbOq SL7s0eRCdNOY8hm6XEkahZMNxbXNhdZExNsyB3vR6XRexsNKwoZv0ls1efYbF7NxW44B hIw39+g2KXSVnMh9Xoy9iQMJIkp8K50tjTtxTJrhBEBCPCaI7G5csL9R0zKJzf8USbWc PjHg== X-Received: by 10.180.73.101 with SMTP id k5mr17458437wiv.43.1422141920534; Sat, 24 Jan 2015 15:25:20 -0800 (PST) Original-Received: from [192.168.1.3] ([82.102.93.54]) by mx.google.com with ESMTPSA id k1sm7976345wjn.9.2015.01.24.15.25.17 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 24 Jan 2015 15:25:19 -0800 (PST) User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:33.0) Gecko/20100101 Thunderbird/33.0 In-Reply-To: <837fwbstls.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a00:1450:400c:c05::229 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:181732 Archived-At: On 01/25/2015 12:26 AM, Eli Zaretskii wrote: > For example, it sounds to me that by having an "add project" and > "remove project" commands, we can give the user the ability to tell A specific project solution could provide those commands. > which projects' databases of symbols are relevant to what she is doing > now. Then Emacs can select completion candidates from the list of > projects currently in the active set. This introduces a new constraint on the potential "project" API. While we want to be able to list files or buffers (and maybe do something with their contents) from all current projects, there are commands in Projectile that necessarily work just on one directory, such as: - Visit project in Dired. - Run a build tool, ag, grep, or any plain shell command in root. - Run vc-dir in root. - (Might or might not also fit the description) Regenerate tags. So the project API either has to be able to designate one project as the "main one" while implementing "list all files" differently, or dynamically look up the real current project root, to use in those commands. > Such a paradigm will not > overwhelm users, since knowing which packages one is working on at any > given time is something we all do anyway. I believe some would still prefer just having it inferred. > Ideally, the popular extensions should already be there. Working on > several packages at the same time is not an uncommon use case. If the projects are unrelated, personally I'd rather keep them separate. Or, in the example you've given before (application and a library it uses), at least with certain languages/environments the project solution could automatically infer all the libraries used by the current application, as well as their current sources, from the project file. That would make add-project and remove-project commands unnecessary, leaving only select-project.