Squish: Update getQtCreatorVersionFromFile()

Change-Id: I9ca74e66c71b363604c6ea1467b2d1ccdffb45f5
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This commit is contained in:
Robert Löhning
2023-01-23 22:55:41 +01:00
parent 86c2143353
commit 1c25a48393

View File

@@ -16,10 +16,10 @@ def getQtCreatorVersionFromDialog():
return ""
def getQtCreatorVersionFromFile():
qtCreatorPriFileName = "../../../../qtcreator_ide_branding.pri"
qtCreatorPriFileName = "../../../../cmake/QtCreatorIDEBranding.cmake"
# open file <qtCreatorPriFileName> and read version
fileText = readFile(qtCreatorPriFileName)
chk = re.search("(?<=QTCREATOR_DISPLAY_VERSION =)\s\d+.\d+.\d+\S*", fileText)
chk = re.search('(?<=set\(IDE_VERSION_DISPLAY ")\d+.\d+.\d+\S*(?="\))', fileText)
try:
ver = chk.group(0).strip()
return ver