You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@geode.apache.org by bb...@apache.org on 2021/02/26 17:05:16 UTC

[geode-native] branch develop updated: Fix regex in set-pipeline script - Git remote URL for https doesn't necessarily have to end in ".git" Wq

This is an automated email from the ASF dual-hosted git repository.

bbender pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/geode-native.git


The following commit(s) were added to refs/heads/develop by this push:
     new a08d3e9  Fix regex in set-pipeline script - Git remote URL for https doesn't necessarily have to end in ".git" Wq
a08d3e9 is described below

commit a08d3e9d9eab855d65894192239b1847518a302e
Author: Blake Bender <bb...@vmware.com>
AuthorDate: Fri Feb 26 09:03:13 2021 -0800

    Fix regex in set-pipeline script
    - Git remote URL for https doesn't necessarily have to end in ".git"
    Wq
---
 ci/set-pipeline.sh | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/ci/set-pipeline.sh b/ci/set-pipeline.sh
index 79deabd..eff03b1 100755
--- a/ci/set-pipeline.sh
+++ b/ci/set-pipeline.sh
@@ -72,11 +72,15 @@ target=${target:-default}
 output=${output:-$(mktemp -d)}
 
 branch=${branch:-$(git rev-parse --abbrev-ref HEAD)}
+echo "branch set to ${branch}"
 git_tracking_branch=${git_tracking_branch:-$(git for-each-ref --format='%(upstream:short)' $(git symbolic-ref -q HEAD))}
+echo "git_tracking_branch set to ${git_tracking_branch}"
 git_remote=${git_remote:-$(echo ${git_tracking_branch} | cut -d/ -f1)}
+echo "git_remote set to ${git_remote}"
 git_repository_url=${git_repository_url:-$(git remote get-url ${git_remote})}
+echo "git_repository_url set to ${git_repository_url}"
 
-if [[ ${git_repository_url} =~ ^((https|git)(:\/\/|@)github\.com[\/:])([^\/:]+)\/(.+).git$ ]]; then
+if [[ ${git_repository_url} =~ ^((https|git)(:\/\/|@)github\.com[\/:])([^\/:]+)\/(.+)[\.git]?$ ]]; then
   github_owner=${github_owner:-${BASH_REMATCH[4]}}
   github_repository=${github_repository:-${BASH_REMATCH[5]}}
 fi
@@ -116,4 +120,5 @@ for variant in ${variants}; do
       "--pipeline=${pipeline}${pipeline_suffix}" \
       "--config=${output}/${variant}.yml"
 
-done
\ No newline at end of file
+done
+