Skip to content

Commit 8dcbb1e

Browse files
committed
chore: postMake
1 parent 09a2425 commit 8dcbb1e

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

packages/common/electron-build/src/hooks/postMake.ts

+9-2
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,9 @@ const platformNamesMap = {
1515
win32: 'windows',
1616
};
1717
const updateYmlMap = {
18-
darwin: 'latest-mac.yml',
18+
darwin_universal: 'latest-mac.yml',
19+
darwin_x64: 'latest-mac-x64.yml',
20+
darwin_arm64: 'latest-mac-arm64.yml',
1921
linux: 'latest-linux.yml',
2022
win32: 'latest.yml',
2123
};
@@ -70,8 +72,13 @@ export const postMake: ForgeHookMap['postMake'] = async (
7072
throw new Error('Missing required artifact or platform information');
7173
}
7274

75+
const ymlKey =
76+
firstResult.platform === 'darwin'
77+
? `${firstResult.platform}_${firstResult.arch}`
78+
: firstResult.platform;
79+
7380
const ymlPath = `${path.dirname(firstResult.artifacts[0])}/${
74-
updateYmlMap[firstResult.platform as keyof typeof updateYmlMap]
81+
updateYmlMap[ymlKey as keyof typeof updateYmlMap]
7582
}`;
7683

7784
const ymlStr = yaml.dump(yml, {

0 commit comments

Comments
 (0)