From commits-return-1269-archive-asf-public=cust-asf.ponee.io@yetus.apache.org Fri Feb 15 19:33:28 2019 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 ECECC180651 for ; Fri, 15 Feb 2019 20:33:27 +0100 (CET) Received: (qmail 81769 invoked by uid 500); 15 Feb 2019 19:33:27 -0000 Mailing-List: contact commits-help@yetus.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@yetus.apache.org Delivered-To: mailing list commits@yetus.apache.org Received: (qmail 81760 invoked by uid 99); 15 Feb 2019 19:33:27 -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; Fri, 15 Feb 2019 19:33:27 +0000 Received: by gitbox.apache.org (ASF Mail Server at gitbox.apache.org, from userid 33) id 48E0B83A91; Fri, 15 Feb 2019 19:33:26 +0000 (UTC) Date: Fri, 15 Feb 2019 19:33:26 +0000 To: "commits@yetus.apache.org" Subject: [yetus] branch master updated: YETUS-793. patch analysis shouldn't require dry-run MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Message-ID: <155025920614.21246.17050702372824065566@gitbox.apache.org> From: aw@apache.org X-Git-Host: gitbox.apache.org X-Git-Repo: yetus X-Git-Refname: refs/heads/master X-Git-Reftype: branch X-Git-Oldrev: 680a23051d57526a994d55dd9a748e1e224503eb X-Git-Newrev: 2923027750d8dbc42cf8576cd871146f391a99ec X-Git-Rev: 2923027750d8dbc42cf8576cd871146f391a99ec X-Git-NotificationType: ref_changed_plus_diff X-Git-Multimail-Version: 1.5.dev Auto-Submitted: auto-generated This is an automated email from the ASF dual-hosted git repository. aw pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/yetus.git The following commit(s) were added to refs/heads/master by this push: new 2923027 YETUS-793. patch analysis shouldn't require dry-run 2923027 is described below commit 2923027750d8dbc42cf8576cd871146f391a99ec Author: Allen Wittenauer AuthorDate: Tue Feb 12 08:23:37 2019 -0800 YETUS-793. patch analysis shouldn't require dry-run Signed-off-by: Allen Wittenauer --- precommit/src/main/shell/smart-apply-patch.sh | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/precommit/src/main/shell/smart-apply-patch.sh b/precommit/src/main/shell/smart-apply-patch.sh index 8997ae4..049294e 100755 --- a/precommit/src/main/shell/smart-apply-patch.sh +++ b/precommit/src/main/shell/smart-apply-patch.sh @@ -101,6 +101,7 @@ function cleanup_and_exit function setup_defaults { common_defaults + REPORTONLY=false } ## @description Print the usage information @@ -148,6 +149,7 @@ function yetus_usage echo "" echo "Patch reporting:" + yetus_add_option "--report-only" "Do not try to apply at all; just report on the patch" yetus_add_option "--build-tool=" "Override the build tool" yetus_add_option "--changedfilesreport=" "List of files that this patch modifies" yetus_add_option "--changedmodulesreport=" "List of modules that this patch modifies" @@ -211,6 +213,9 @@ function parse_args --changedunionreport=*) UNIONREPORT=${i#*=} ;; + --report-only) + REPORTONLY=true + ;; --*) ## PATCH_OR_ISSUE can't be a --. So this is probably ## a plugin thing. @@ -246,8 +251,6 @@ function patch_reports return fi - set -x - find_changed_files if [[ -n "${FILEREPORT}" ]]; then @@ -401,6 +404,11 @@ plugins_initialize locate_patch +if [[ "${REPORTONLY}" = true ]]; then + patch_reports + cleanup_and_exit 0 +fi + if [[ ${COMMITMODE} = true ]]; then status=$("${GIT}" status --porcelain) if [[ "$status" != "" ]] ; then