Skip to content

Commit

Permalink
Build tags of specified target repo (#287)
Browse files Browse the repository at this point in the history
  • Loading branch information
WenqingLiAMD authored Jul 26, 2022
1 parent 1965d38 commit 51cd891
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions utils/amdvlk_build_for_tag.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,18 +36,18 @@ def __init__(self):
self.buildTag = ''
self.driverRoot = ''
self.diffTag = 'v-2022.Q3.1'
self.validTags = self.GetValidTags()
self.validTags = []

def GetValidTags(self):
repo = Github().get_repo('GPUOpen-Drivers/AMDVLK')
def UpdateValidTags(self, repoPath):
repo = Github().get_repo(repoPath)
allTags = repo.get_tags()
validTags = []
for t in allTags:
if t.name[:2] == 'v-': validTags.append(t.name)
if not validTags:
eprint("No valid tags found from AMDVLK")
exit(-1)
return sorted(validTags, reverse=True)
self.validTags = sorted(validTags, reverse=True)

def GetOpt(self):
parser = OptionParser()
Expand Down Expand Up @@ -85,6 +85,7 @@ def GetOpt(self):

print("The target repo is " + self.targetRepo)

self.UpdateValidTags(self.targetRepo.strip('/ ').split('/')[-1] + '/AMDVLK')
if options.buildTag:
if options.buildTag in self.validTags:
self.buildTag = options.buildTag
Expand Down

0 comments on commit 51cd891

Please sign in to comment.