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: progmodes/project.el and search paths Date: Tue, 4 Aug 2015 20:43:35 +0300 Message-ID: <55C0F9C7.8010006@yandex.ru> References: <55BE209F.1000009@siege-engine.com> <55BE509B.2080307@yandex.ru> <87r3nkjxby.fsf@isaac.fritz.box> <87h9ogyq6s.fsf@isaac.fritz.box> <86mvy7e6hr.fsf@stephe-leake.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 1438710231 23426 80.91.229.3 (4 Aug 2015 17:43:51 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 4 Aug 2015 17:43:51 +0000 (UTC) To: Stephen Leake , emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Aug 04 19:43:51 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 1ZMgFh-0002Ac-3F for ged-emacs-devel@m.gmane.org; Tue, 04 Aug 2015 19:43:49 +0200 Original-Received: from localhost ([::1]:36589 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZMgFg-0004XB-IX for ged-emacs-devel@m.gmane.org; Tue, 04 Aug 2015 13:43:48 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:59148) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZMgFd-0004Wu-A3 for emacs-devel@gnu.org; Tue, 04 Aug 2015 13:43:46 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZMgFY-0005Pf-Ag for emacs-devel@gnu.org; Tue, 04 Aug 2015 13:43:45 -0400 Original-Received: from mail-lb0-x22f.google.com ([2a00:1450:4010:c04::22f]:36817) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZMgFY-0005PZ-1n for emacs-devel@gnu.org; Tue, 04 Aug 2015 13:43:40 -0400 Original-Received: by lbbud7 with SMTP id ud7so10435699lbb.3 for ; Tue, 04 Aug 2015 10:43:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:subject:to:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-type:content-transfer-encoding; bh=x0SPZipgcsEY7ncgrR0vgk8FtiR0+NEoFSYmhz4jJE0=; b=cTjzKw1zyrmhA3RDbw4fu5HkL3LmbjOWUTh4sY8lfMJ/sL4X7BnRP90CqA0nCJZrqB r+fdGvI5mtmXMfsxq3ebM12i84BzR+jXb9xF+glatGdZtzkXzi91ahq9vGz29rXBxcNq hRogAkD+qrziGmcORZiP11kY6hzAsxapewnOjLDwgPYuPYep0tgo4C2wuKw51ZsxwVHv 5NP1eKCEBUP9phTRTyAMRNEs5h+prPb9cTLR5mszV0blhFmNsrRS/TlZTRap7D4w2Wqf nUZvVREMOrrhbu4/7sSJw+MX+HabIY2Cw6X3OsP2/Ar/BfRvxsDUMFNVDLcMXQOYTs5u 0jvA== X-Received: by 10.152.219.3 with SMTP id pk3mr4816529lac.114.1438710218909; Tue, 04 Aug 2015 10:43:38 -0700 (PDT) Original-Received: from [10.9.0.103] (nat.webazilla.com. [78.140.128.228]) by smtp.googlemail.com with ESMTPSA id kc4sm356899lbc.39.2015.08.04.10.43.37 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 04 Aug 2015 10:43:37 -0700 (PDT) User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:40.0) Gecko/20100101 Thunderbird/40.0 In-Reply-To: <86mvy7e6hr.fsf@stephe-leake.org> X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a00:1450:4010:c04::22f 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:188402 Archived-At: On 08/04/2015 12:40 PM, Stephen Leake wrote: > It would help if the header comment in project.el said something along > those lines. > > There is a big difference between: > > "provide an interface between projects and the rest of Emacs" > > and > > "provide a core API for implementing projects". > > The current project.el header is unclear as to which it is intended to > be. Would adding this help? diff --git a/lisp/progmodes/project.el b/lisp/progmodes/project.el index d849f93..16578f1 100644 --- a/lisp/progmodes/project.el +++ b/lisp/progmodes/project.el @@ -22,6 +22,10 @@ ;; This file contains generic infrastructure for dealing with ;; projects, and a number of public functions: finding the current ;; root, related project directories, search path, etc. +;; +;; The goal is to make it easy for Lisp programs to operate on the +;; current project, without having to know which package handles +;; detection of that project type, parsing its config files, etc. ;;; Code: > If it's really the former, that puts a much different light on things; > it should be providing wrappers/adaptors for EDE, projectile, etc, so > grep, compile etc can use project information. "Should" is a strong word. There's wrapper for EDE living in lisp/cedet/ede.el already. Projectile "should" include its own wrapper as well. > In particular, there should be no "xref-find-regexp"; instead, "grep" > and similar commands should be enhanced to optionally use project > functions to get the search path. xref-find-regexp can still be useful: it'll search a user-specified directory and present the results using the xref interface. At the moment, xref-find-regexp offers both types of searches. To search in an arbitrary directory, you preface it with C-u.