Return-Path: Delivered-To: apmail-incubator-buildr-commits-archive@locus.apache.org Received: (qmail 26815 invoked from network); 1 Sep 2008 00:42:34 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 1 Sep 2008 00:42:34 -0000 Received: (qmail 21109 invoked by uid 500); 1 Sep 2008 00:42:33 -0000 Delivered-To: apmail-incubator-buildr-commits-archive@incubator.apache.org Received: (qmail 21093 invoked by uid 500); 1 Sep 2008 00:42:33 -0000 Mailing-List: contact buildr-commits-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: buildr-dev@incubator.apache.org Delivered-To: mailing list buildr-commits@incubator.apache.org Received: (qmail 21084 invoked by uid 99); 1 Sep 2008 00:42:33 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 31 Aug 2008 17:42:33 -0700 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 01 Sep 2008 00:41:43 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 38C95234C1B8 for ; Sun, 31 Aug 2008 17:41:44 -0700 (PDT) Message-ID: <761366879.1220229704218.JavaMail.jira@brutus> Date: Sun, 31 Aug 2008 17:41:44 -0700 (PDT) From: "Assaf Arkin (JIRA)" To: buildr-commits@incubator.apache.org Subject: [jira] Commented: (BUILDR-142) Allow running project tasks from a top directory in the same way as after 'cd' to the project's base dir In-Reply-To: <2087423100.1220214104193.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/BUILDR-142?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12627361#action_12627361 ] Assaf Arkin commented on BUILDR-142: ------------------------------------ There is one way to run a specific task, and that's by naming it as an argument to buildr. Separately, some people use the command line and they cd into a directory and work there, so we make some tasks pick on that and just find the projec(s) from the local directory. It does the right thing most of the time, but is not recommended for automating a build (i.e. IDE, CI). The notion of specific tasks is prevalent throughout Buildr. It's how you name tasks, how you find tasks, what you'll see when you run buildr --prereqs, follow the console messages, diagnose error messages. I doubt you can use Buildr effectively without understanding what it does, what do you do when things go wrong? So if we're not doing a good enough job allowing people to do all these things, we should consider that either the Buildr model is wrong, or the documentation needs more work. > Allow running project tasks from a top directory in the same way as after 'cd' to the project's base dir > -------------------------------------------------------------------------------------------------------- > > Key: BUILDR-142 > URL: https://issues.apache.org/jira/browse/BUILDR-142 > Project: Buildr > Issue Type: New Feature > Components: Core features > Affects Versions: 1.3.2 > Reporter: Ittay Dror > Assignee: Victor Hugo Borja > Fix For: 1.3.3 > > Attachments: 0001-rspec-for-p-switch.patch, 0002-added-p-switch.patch, 0003-allow-project-names-with-path-separators.patch, 0004-list-project-names-with-file-separator.patch > > > Currently, to run a specific project's tasks, there are two alternatives: > 1. cd to the project's base dir and run 'buildr' or 'buildr '. > 2. run 'buildr : :' > The first one requires 'cd' and is not comfortable to run from an IDE. The second one is verbose, cannot rely on default tasks and is confusing to new users. > Users usually expect the behavior as in 'make' or 'tar'. That is, a switch (usually -C) that first does a 'cd' for you and then continues to run as usual. This is an issue I'm faced with right now. People are confused when I tell them to run 'buildr top_project:sub_project:build'. Also, people don't think of projects as tasks. This is an implementation detail of Buildr, not something that people comprehend intuitively (at least my users) > Moreover, several projects may share the same base directory (I intend to use this to compile the same source tree with different configurations), so a 'cd' will cause both to compile. > Suggestion: add a '-p' switch that tells buildr the "local project" to use when running. Then users simply invoke 'buildr -p top_project:sub_project' and all default tasks run. > Suggestion 2: since project names will usually correspond with a directory layout, allow to specify them with File::SEPARATOR. this way, command line completion is easy (especially in windows). -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.