From commits-return-28701-archive-asf-public=cust-asf.ponee.io@geode.apache.org Mon Oct 15 20:31:51 2018 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx-eu-01.ponee.io (Postfix) with SMTP id A12D9180674 for ; Mon, 15 Oct 2018 20:31:50 +0200 (CEST) Received: (qmail 45579 invoked by uid 500); 15 Oct 2018 18:31:49 -0000 Mailing-List: contact commits-help@geode.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@geode.apache.org Delivered-To: mailing list commits@geode.apache.org Received: (qmail 45570 invoked by uid 99); 15 Oct 2018 18:31:49 -0000 Received: from ec2-52-202-80-70.compute-1.amazonaws.com (HELO gitbox.apache.org) (52.202.80.70) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Oct 2018 18:31:49 +0000 Received: by gitbox.apache.org (ASF Mail Server at gitbox.apache.org, from userid 33) id 0196D82C17; Mon, 15 Oct 2018 18:31:49 +0000 (UTC) Date: Mon, 15 Oct 2018 18:31:48 +0000 To: "commits@geode.apache.org" Subject: [geode] 01/02: Improve reporting in checkPom. Add task updateExpectedPom to spare manual copy. MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit From: rhoughton@apache.org In-Reply-To: <153962830698.12076.12038017585706941467@gitbox.apache.org> References: <153962830698.12076.12038017585706941467@gitbox.apache.org> X-Git-Host: gitbox.apache.org X-Git-Repo: geode X-Git-Refname: refs/heads/develop X-Git-Reftype: branch X-Git-Rev: 0d8f7d44196cff91fbb02885fe3c5b7c749ce587 X-Git-NotificationType: diff X-Git-Multimail-Version: 1.5.dev Auto-Submitted: auto-generated Message-Id: <20181015183149.0196D82C17@gitbox.apache.org> This is an automated email from the ASF dual-hosted git repository. rhoughton pushed a commit to branch develop in repository https://gitbox.apache.org/repos/asf/geode.git commit 0d8f7d44196cff91fbb02885fe3c5b7c749ce587 Author: Patrick Rhomberg AuthorDate: Thu Sep 27 14:09:03 2018 -0700 Improve reporting in checkPom. Add task updateExpectedPom to spare manual copy. --- gradle/publish.gradle | 22 ++++++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) diff --git a/gradle/publish.gradle b/gradle/publish.gradle index f4eb8a0..8c93dec 100644 --- a/gradle/publish.gradle +++ b/gradle/publish.gradle @@ -163,12 +163,15 @@ subprojects { def message = "The ".concat(project.name).concat(" pom-default.xml has changed. Verify dependencies.") - .concat("\nWhen fixed, copy ").concat(actualPomFile as String) - .concat("\nto ").concat(expectedPomFile as String) + .concat("\nWhen changes have been approved, copy :\n") + .concat(" cp ").concat(actualPomFile as String) + .concat(" ").concat(expectedPomFile as String) .concat("\nRemoved Dependencies\n--------------\n") - .concat(String.join("\n", removedDependencies.toString())) + .concat(String.join("\n", removedDependencies.each { dep -> dep.toString() })) .concat("\n\nNew Dependencies\n--------------\n") - .concat(String.join("\n", newDependencies.toString()) + "\n\n") + .concat(String.join("\n", newDependencies.each { dep -> dep.toString() })) + .concat("\n\n") + throw new RuntimeException(message) } @@ -178,6 +181,17 @@ subprojects { } check.dependsOn('checkPom') + task updateExpectedPom(dependsOn: generatePomFileForMavenPublication, type: Copy) { + description 'After having verified changes with checkPom, this task will perform the copy.' + + def expectedPomFile = sourceSets.test.resources.find() { it.name == "expected-pom.xml" } + def actualPomFile = generatePomFileForMavenPublication.outputs.files.first() + if (tasks.getByName("generatePomFileForMavenPublication").enabled && expectedPomFile && actualPomFile) { + from actualPomFile + into expectedPomFile.parent + rename '.*xml', "expected-pom.xml" + } + } } // subprojects