@@ -59,6 +59,8 @@ async function GetProjectDetails(): Promise<XcodeProject> {
5959 let infoPlistContent = plist . parse ( fs . readFileSync ( infoPlistPath , 'utf8' ) ) ;
6060 const versionString = infoPlistContent [ 'CFBundleShortVersionString' ] ;
6161 core . info ( `Version string: ${ versionString } ` ) ;
62+ const buildString = infoPlistContent [ 'CFBundleVersion' ] ;
63+ core . info ( `Build string: ${ buildString } ` ) ;
6264 return new XcodeProject (
6365 projectPath ,
6466 projectName ,
@@ -93,7 +95,8 @@ async function parseBuildSettings(projectPath: string, scheme: string): Promise<
9395 if ( ! platformName ) {
9496 throw new Error ( 'Unable to determine the platform name from the build settings' ) ;
9597 }
96- const bundleId = core . getInput ( 'bundle-id' ) || matchRegexPattern ( buildSettingsOutput , / \s + P R O D U C T _ B U N D L E _ I D E N T I F I E R = (?< bundleId > [ \w . - ] + ) / , 'bundleId' ) ; if ( ! bundleId || bundleId === 'NO' ) {
98+ const bundleId = core . getInput ( 'bundle-id' ) || matchRegexPattern ( buildSettingsOutput , / \s + P R O D U C T _ B U N D L E _ I D E N T I F I E R = (?< bundleId > [ \w . - ] + ) / , 'bundleId' ) ;
99+ if ( ! bundleId || bundleId === 'NO' ) {
97100 throw new Error ( 'Unable to determine the bundle ID from the build settings' ) ;
98101 }
99102 const platforms = {
@@ -670,19 +673,23 @@ async function getWhatsNew(): Promise<string> {
670673 const branchNameDetails = await execGit ( [ 'log' , head , '-1' , '--format=%d' ] ) ;
671674 const branchNameMatch = branchNameDetails . match ( / \( (?< branch > .+ ) \) / ) ;
672675 let branchName = '' ;
673- if ( branchNameMatch ) {
676+ if ( branchNameMatch && branchNameMatch . groups ) {
677+ branchName = branchNameMatch . groups . branch ;
674678 if ( branchName . includes ( ' -> ' ) ) {
675679 branchName = branchName . split ( ' -> ' ) [ 1 ] ;
676680 }
677681 if ( branchName . includes ( ',' ) ) {
678682 branchName = branchName . split ( ',' ) [ 1 ] ;
679683 }
680- if ( branchName . includes ( 'origin /' ) ) {
681- branchName = branchName . split ( 'origin /' ) [ 1 ] ;
684+ if ( branchName . includes ( '/' ) ) {
685+ branchName = branchName . split ( '/' ) [ 1 ] ;
682686 }
683687 }
684- const commitMessage = await execGit ( [ 'log' , head , '-1' , '--format=%s ' ] ) ;
688+ const commitMessage = await execGit ( [ 'log' , head , '-1' , '--format=%B ' ] ) ;
685689 whatsNew = `[${ commitSha . trim ( ) } ]${ branchName . trim ( ) } \n${ commitMessage . trim ( ) } ` ;
690+ if ( whatsNew . length > 4000 ) {
691+ whatsNew = `${ whatsNew . substring ( 0 , 3997 ) } ...` ;
692+ }
686693 }
687694 if ( whatsNew . length === 0 ) {
688695 throw new Error ( 'Test details empty!' ) ;
0 commit comments