Skip to content

Commit 228d8f8

Browse files
authored
Use APFS for the DMG (#81)
1 parent 9094004 commit 228d8f8

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

cli.js

+4-4
Original file line numberDiff line numberDiff line change
@@ -106,10 +106,9 @@ async function init() {
106106
composedIconPath = await composeIcon(path.join(appPath, 'Contents/Resources', `${appIconName}.icns`));
107107
}
108108

109-
const minSystemVersion = (Object.prototype.hasOwnProperty.call(appInfo, 'LSMinimumSystemVersion') && appInfo.LSMinimumSystemVersion.length > 0) ? appInfo.LSMinimumSystemVersion.toString() : '10.11';
110-
const minorVersion = Number(minSystemVersion.split('.')[1]) || 0;
111-
const dmgFormat = (minorVersion >= 11) ? 'ULFO' : 'UDZO'; // ULFO requires 10.11+
112-
ora.info(`Minimum runtime ${minSystemVersion} detected, using ${dmgFormat} format`).start();
109+
// Xcode 14+ only supports building apps for macOS 10.13+
110+
const dmgFormat = 'ULFO'; // ULFO requires macOS 10.11+
111+
const dmgFilesystem = 'APFS'; // APFS requires macOS 10.13+
113112

114113
const ee = appdmg({
115114
target: dmgPath,
@@ -123,6 +122,7 @@ async function init() {
123122
background: path.join(__dirname, 'assets/dmg-background.png'),
124123
'icon-size': 160,
125124
format: dmgFormat,
125+
filesystem: dmgFilesystem,
126126
window: {
127127
size: {
128128
width: 660,

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242
"apple"
4343
],
4444
"dependencies": {
45-
"appdmg": "^0.6.0",
45+
"appdmg": "^0.6.6",
4646
"execa": "^1.0.0",
4747
"gm": "^1.23.1",
4848
"icns-lib": "^1.0.1",

readme.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ $ create-dmg --help
3636

3737
## DMG
3838

39-
The DMG detects the minimum runtime of the app, and uses ULFO (macOS 10.11 or later) or UDZO as appropriate. The resulting image has the filename `App Name 0.0.0.dmg`, for example `Lungo 1.0.0.dmg`.
39+
The DMG requires macOS 10.13 or later and has the filename `App Name 0.0.0.dmg`, for example `Lungo 1.0.0.dmg`.
4040

4141
It will try to code sign the DMG, but the DMG is still created and fine even if the code signing fails, for example if you don't have a developer certificate.
4242

0 commit comments

Comments
 (0)