Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Modify get_source.sh to automatically fetch release branches #660

Merged
merged 1 commit into from
Sep 13, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 10 additions & 4 deletions closed/get_j9_source.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/bash

# ===========================================================================
# (c) Copyright IBM Corp. 2017, 2021 All Rights Reserved
# (c) Copyright IBM Corp. 2017, 2023 All Rights Reserved
# ===========================================================================
#
# This code is free software; you can redistribute it and/or modify it
Expand Down Expand Up @@ -57,10 +57,16 @@ declare -A shas
declare -A references

git_urls[openj9]=https://github.com/eclipse-openj9/openj9
branches[openj9]=master

git_urls[omr]=https://github.com/eclipse-openj9/openj9-omr
branches[omr]=openj9

currentbranch=$(git rev-parse --abbrev-ref HEAD)
if [[ "$currentbranch" =~ v[0-9]+\.[0-9]+(\.[0-9]+)?-release ]] ; then
branches[openj9]=$currentbranch
branches[omr]=$currentbranch
else
branches[openj9]=master
branches[omr]=openj9
fi

pflag=false

Expand Down