From issues-return-100700-apmail-maven-issues-archive=maven.apache.org@maven.apache.org Sat Feb 21 18:44:43 2015 Return-Path: X-Original-To: apmail-maven-issues-archive@minotaur.apache.org Delivered-To: apmail-maven-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 03A34100FE for ; Sat, 21 Feb 2015 18:44:43 +0000 (UTC) Received: (qmail 95552 invoked by uid 500); 21 Feb 2015 18:44:42 -0000 Delivered-To: apmail-maven-issues-archive@maven.apache.org Received: (qmail 95501 invoked by uid 500); 21 Feb 2015 18:44:42 -0000 Mailing-List: contact issues-help@maven.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@maven.apache.org Delivered-To: mailing list issues@maven.apache.org Received: (qmail 95490 invoked by uid 99); 21 Feb 2015 18:44:42 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 21 Feb 2015 18:44:42 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=5.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: local policy) Received: from [199.193.192.100] (HELO codehaus01.managed.contegix.com) (199.193.192.100) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 21 Feb 2015 18:44:38 +0000 Received: from codehaus01 (localhost.localdomain [127.0.0.1]) by codehaus01.managed.contegix.com (Postfix) with ESMTP id EB51FB0482 for ; Sat, 21 Feb 2015 12:43:17 -0600 (CST) Date: Sat, 21 Feb 2015 12:43:17 -0600 (CST) From: "Abhijit Sarkar (JIRA)" To: issues@maven.apache.org Message-ID: In-Reply-To: References: Subject: [jira] (MENFORCER-225) Add rules for mutually-exclusive profiles and banned profiles MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 22cf62d5d84cf5bea94eb3b65e0ebd09 X-Virus-Checked: Checked by ClamAV on apache.org Abhijit Sarkar created MENFORCER-225: ---------------------------------------- Summary: Add rules for mutually-exclusive profiles and banned profiles Key: MENFORCER-225 URL: https://jira.codehaus.org/browse/MENFORCER-225 Project: Maven Enforcer Plugin Issue Type: New Feature Components: Rule API, Standard Rules Affects Versions: 1.4 Reporter: Abhijit Sarkar Attachments: enforcer-rules.patch I wrote 2 new enforces rules: * The ability to specify a set of mutually-exclusive profiles (p1,p2:p1,p3 would mean p1 can't be active with either p2 or p3). This has been discussed on [this thread|http://stackoverflow.com/questions/24855678/enforce-exactly-one-of-two-maven-profiles] on SO. * The ability to ban profiles (the contrary of {{requireActiveProfile}}). p1, p2 would mean neither p1 nor p2 can be active for this build. Both of these rules support wildcards and consider inherited profiles as well. I've attached a patch complete with unit test cases. {{mvn clean install}} passes in local. These are built on v1.4 of the rules. -- This message was sent by Atlassian JIRA (v6.1.6#6162)