Return-Path: X-Original-To: apmail-maven-users-archive@www.apache.org Delivered-To: apmail-maven-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 169BF17DF5 for ; Sun, 5 Apr 2015 18:11:47 +0000 (UTC) Received: (qmail 98988 invoked by uid 500); 5 Apr 2015 18:11:45 -0000 Delivered-To: apmail-maven-users-archive@maven.apache.org Received: (qmail 98906 invoked by uid 500); 5 Apr 2015 18:11:45 -0000 Mailing-List: contact users-help@maven.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Maven Users List" Reply-To: "Maven Users List" Delivered-To: mailing list users@maven.apache.org Received: (qmail 98895 invoked by uid 99); 5 Apr 2015 18:11:45 -0000 Received: from mail-relay.apache.org (HELO mail-relay.apache.org) (140.211.11.15) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 05 Apr 2015 18:11:45 +0000 Received: from robertscholte.dynamic.ziggo.nl (5248749D.cm-4-1b.dynamic.ziggo.nl [82.72.116.157]) by mail-relay.apache.org (ASF Mail Server at mail-relay.apache.org) with ESMTPSA id 8DC2C1A04FF for ; Sun, 5 Apr 2015 18:11:44 +0000 (UTC) Content-Type: text/plain; charset=utf-8; format=flowed; delsp=yes To: "Maven Users List" Subject: Re: Easy way to tell if I have .class file conflicts between two jars? References: Date: Sun, 05 Apr 2015 20:11:39 +0200 MIME-Version: 1.0 Content-Transfer-Encoding: Quoted-Printable From: "Robert Scholte" Message-ID: In-Reply-To: User-Agent: Opera Mail/12.17 (Win32) Hi, take a look at this enforcer rule: http://mojo.codehaus.org/extra-enforcer-rules/banDuplicateClasses.html Robert Op Sun, 05 Apr 2015 19:57:07 +0200 schreef Kevin Burton = : > Im looking for a somewhat easy way to tell if a directory of .jar file= s > contains class reference which conflict. > > For example,org/xml/sax/XMLReader.class from two incompatible versions= . > > I wrote a simple command that does a find and then a "jar tf" to list = the > contents, then I sort by the filename, but this creates false positive= s = > in > the case where the files are actually the same .class file version. > > I think I could just use SHA1 to detect this =E2=80=A6 if the SHA1 is = identical I > can just ignore it. > > Of course a WAY better way to do this would be some sort of maven plug= in > that looked at all dependencies and generated errors/warnings if you a= dd = > a > dependency with class conflicts. That would be sweet. --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@maven.apache.org For additional commands, e-mail: users-help@maven.apache.org