-
Notifications
You must be signed in to change notification settings - Fork 84
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
155 changed files
with
3,944 additions
and
1,208 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -25,41 +25,33 @@ if(NOT DMG_FILE_LEN EQUAL 1) | |
endif() | ||
message(STATUS "Using DMG: ${DMG_FILE}") | ||
|
||
if(NOT USER) | ||
set(USER [email protected]) | ||
endif() | ||
|
||
execute_process(COMMAND ${XCRUN} altool -t osx --notarize-app --verbose -u ${USER} -p @env:PASSWORD --primary-bundle-id com.governikus.ausweisapp2 -f ${DMG_FILE} | ||
OUTPUT_VARIABLE UUID_OUTPUT) | ||
set(keychain --keychain-profile "AC_PASSWORD") | ||
execute_process(COMMAND ${XCRUN} notarytool submit ${keychain} ${DMG_FILE} OUTPUT_VARIABLE UUID_OUTPUT) | ||
|
||
set(regex_uuid "RequestUUID = ([-|0-9|a-z]+)") | ||
set(regex_uuid "id: ([-|0-9|a-z]+)") | ||
FETCH_REGEX(UUID "${regex_uuid}" "${UUID_OUTPUT}") | ||
if(UUID) | ||
message(STATUS "Fetched UUID: ${UUID}") | ||
else() | ||
message(FATAL_ERROR "Cannot fetch UUID: ${UUID_OUTPUT}") | ||
endif() | ||
|
||
set(regex_status "Status: ([a-z| ]+)") | ||
while(TRUE) | ||
message(STATUS "Wait 30 seconds...") | ||
execute_process(COMMAND ${CMAKE_COMMAND} -E sleep 30) | ||
message(STATUS "Wait...") | ||
execute_process(COMMAND ${XCRUN} notarytool wait ${UUID} ${keychain}) | ||
|
||
execute_process(COMMAND ${XCRUN} altool -u ${USER} -p @env:PASSWORD --notarization-info ${UUID} | ||
OUTPUT_VARIABLE STATUS_OUTPUT) | ||
execute_process(COMMAND ${XCRUN} notarytool info ${UUID} ${keychain} OUTPUT_VARIABLE STATUS_OUTPUT) | ||
|
||
FETCH_REGEX(STATUS "${regex_status}" "${STATUS_OUTPUT}") | ||
set(regex_status "status: ([a-zA-Z| ]+)") | ||
FETCH_REGEX(STATUS "${regex_status}" "${STATUS_OUTPUT}") | ||
|
||
if(STATUS STREQUAL "success") | ||
message(STATUS "Notarization succeeded...") | ||
break() | ||
elseif(STATUS STREQUAL "in progress") | ||
message(STATUS "Waiting...\n${STATUS_OUTPUT}") | ||
else() | ||
message(STATUS "Fetched Status: ${STATUS}") | ||
message(FATAL_ERROR "Notarization failed:\n${STATUS_OUTPUT}") | ||
endif() | ||
endwhile() | ||
if(STATUS STREQUAL "Accepted") | ||
message(STATUS "Notarization succeeded...") | ||
else() | ||
message(STATUS "Fetched Status: ${STATUS}") | ||
execute_process(COMMAND ${XCRUN} notarytool log ${UUID} ${keychain}) | ||
message(FATAL_ERROR "Notarization failed:\n${STATUS_OUTPUT}") | ||
endif() | ||
|
||
execute_process(COMMAND ${XCRUN} stapler staple -v ${DMG_FILE}) | ||
execute_process(COMMAND ${XCRUN} stapler validate -v ${DMG_FILE}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
# This file will be included in Tools.cmake AND after Libraries.cmake | ||
# So this file will be called two times and the check needs to respect that | ||
# with a "VALIDATOR function" or "if(NOT VARIABLE)". | ||
|
||
if(NOT QMLFORMAT) | ||
set(QMLFORMAT_MIN_VERSION 6) | ||
function(qmlformat_validator validator_result binary) | ||
execute_process(COMMAND ${binary} --version OUTPUT_VARIABLE QMLFORMAT_VERSION OUTPUT_STRIP_TRAILING_WHITESPACE) | ||
string(REPLACE "qmlformat " "" QMLFORMAT_VERSION "${QMLFORMAT_VERSION}") | ||
|
||
if("${QMLFORMAT_VERSION}" VERSION_LESS "${QMLFORMAT_MIN_VERSION}") | ||
set(${validator_result} FALSE PARENT_SCOPE) | ||
endif() | ||
endfunction() | ||
|
||
if(CMAKE_VERSION VERSION_GREATER_EQUAL "3.25") | ||
set(VALIDATOR VALIDATOR qmlformat_validator) | ||
endif() | ||
|
||
find_program(QMLFORMAT qmlformat HINTS "${QT_INSTALL_ARCHDATA}/bin" ${VALIDATOR} CMAKE_FIND_ROOT_PATH_BOTH) | ||
if(QMLFORMAT) | ||
execute_process(COMMAND ${QMLFORMAT} --version OUTPUT_VARIABLE QMLFORMAT_VERSION OUTPUT_STRIP_TRAILING_WHITESPACE) | ||
string(REPLACE "qmlformat " "" QMLFORMAT_VERSION "${QMLFORMAT_VERSION}") | ||
|
||
if("${QMLFORMAT_VERSION}" VERSION_LESS "${QMLFORMAT_MIN_VERSION}") | ||
unset(QMLFORMAT CACHE) # let's retry later | ||
else() | ||
file(GLOB_RECURSE FILES_QML ${PROJECT_SOURCE_DIR}/*.qml) | ||
set(QMLFORMAT_CMD ${QMLFORMAT} -i -n -l unix -t -w 4) | ||
|
||
set(FORMATTING_FILE ${PROJECT_BINARY_DIR}/formatting.files.qml) | ||
file(WRITE ${FORMATTING_FILE} "") | ||
foreach(file ${FILES_QML}) | ||
file(APPEND ${FORMATTING_FILE} ${file}) | ||
file(APPEND ${FORMATTING_FILE} "\n") | ||
endforeach() | ||
|
||
add_custom_target(format.qml COMMAND ${QMLFORMAT_CMD} -F ${FORMATTING_FILE} SOURCES ${FILES_QML}) | ||
add_dependencies(format format.qml) | ||
endif() | ||
endif() | ||
endif() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.