@@ -79,6 +79,11 @@ def add_skara_upstream(workspace, jdk_version, skara_repo, branch):
7979 # Fetch origin
8080 repo .remotes .origin .fetch ()
8181
82+ # Check if the remote named 'skara' exists, add if not
83+ if "skara" not in [remote .name for remote in repo .remotes ]:
84+ print (f"Initial setup of: { skara_repo } " )
85+ repo .create_remote ("skara" , skara_repo )
86+
8287 # Check out the specified branch
8388 if branch in repo .heads :
8489 # Branch exists locally, just check it out
@@ -98,11 +103,6 @@ def add_skara_upstream(workspace, jdk_version, skara_repo, branch):
98103 # Create master branch
99104 repo .create_head (branch , f"skara/{ branch } " ).checkout ()
100105
101- # Check if the remote named 'skara' exists, add if not
102- if "skara" not in [remote .name for remote in repo .remotes ]:
103- print (f"Initial setup of: { skara_repo } " )
104- repo .create_remote ("skara" , skara_repo )
105-
106106 except GitCommandError as error :
107107 print (f"Git command failed: { error } " )
108108 exit (1 )
@@ -233,7 +233,9 @@ def perform_merge_into_release_from_master(workspace, github_repo, branch):
233233 )
234234 print (f"Tagging { tag } as { tag } _adopt" )
235235 adoptTag = f"{ tag } _adopt"
236- repo .create_tag (adoptTag , ref = tag , message = f"Merged { tag } into release" )
236+ repo .create_tag (
237+ adoptTag , ref = "release" , message = f"Merged { tag } into release"
238+ )
237239 newAdoptTags .append (adoptTag )
238240
239241 if repo .git .rev_parse (
@@ -274,6 +276,7 @@ def perform_merge_into_release_from_master(workspace, github_repo, branch):
274276
275277 if repo .git .tag ("-l" , prevReleaseAdoptTag ):
276278 if not repo .git .tag ("-l" , currentReleaseAdoptTag ):
279+ print ("here" )
277280 print (
278281 f"Tagging new current release tag { currentReleaseAdoptTag } "
279282 + f"which is same commit as the previous { prevReleaseAdoptTag } "
0 commit comments