Skip to content

Commit bcf3ee1

Browse files
- fix executable path output
1 parent 2280a39 commit bcf3ee1

File tree

6 files changed

+18
-6
lines changed

6 files changed

+18
-6
lines changed

dist/index.js

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40911,6 +40911,13 @@ async function ExportXcodeArchive(projectRef) {
4091140911
}
4091240912
await execWithXcBeautify(exportArgs);
4091340913
projectRef.exportPath = exportPath;
40914+
const globPath = `${exportPath}/**/*.ipa\n${exportPath}/**/*.app`;
40915+
const globber = await glob.create(globPath);
40916+
const files = await globber.glob();
40917+
if (files.length === 0) {
40918+
throw new Error(`No IPA or APP file found in the export path.\n${globPath}`);
40919+
}
40920+
core.setOutput('executable', files[0]);
4091440921
core.info(`Exported: ${exportPath}`);
4091540922
return projectRef;
4091640923
}
@@ -43021,7 +43028,6 @@ const main = async () => {
4302143028
let projectRef = await (0, xcode_1.GetProjectDetails)();
4302243029
projectRef.credential = credential;
4302343030
projectRef = await (0, xcode_1.ArchiveXcodeProject)(projectRef);
43024-
core.setOutput('executable', projectRef.archivePath);
4302543031
projectRef = await (0, xcode_1.ExportXcodeArchive)(projectRef);
4302643032
core.setOutput('output-directory', projectRef.exportPath);
4302743033
}

dist/index.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "unity-xcode-builder",
3-
"version": "1.0.0",
3+
"version": "1.0.1",
44
"description": "A GitHub Action to build and archive Unity exported xcode projects.",
55
"author": "buildalon",
66
"license": "MIT",

src/index.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@ const main = async () => {
2626
let projectRef = await GetProjectDetails();
2727
projectRef.credential = credential;
2828
projectRef = await ArchiveXcodeProject(projectRef);
29-
core.setOutput('executable', projectRef.archivePath);
3029
projectRef = await ExportXcodeArchive(projectRef);
3130
core.setOutput('output-directory', projectRef.exportPath);
3231
} else {

src/xcode.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -172,6 +172,13 @@ async function ExportXcodeArchive(projectRef: XcodeProject): Promise<XcodeProjec
172172
}
173173
await execWithXcBeautify(exportArgs);
174174
projectRef.exportPath = exportPath;
175+
const globPath = `${exportPath}/**/*.ipa\n${exportPath}/**/*.app`;
176+
const globber = await glob.create(globPath);
177+
const files = await globber.glob();
178+
if (files.length === 0) {
179+
throw new Error(`No IPA or APP file found in the export path.\n${globPath}`);
180+
}
181+
core.setOutput('executable', files[0]);
175182
core.info(`Exported: ${exportPath}`);
176183
return projectRef;
177184
}

0 commit comments

Comments
 (0)