Skip to content

Commit

Permalink
fix: dmg/pkg in the out dir, not in the subdir mac
Browse files Browse the repository at this point in the history
BREAKING CHANGE: dmg/pkg in the out dir, not in the subdir mac
  • Loading branch information
develar committed Feb 28, 2017
1 parent 8dd6cd5 commit 0bba4fe
Show file tree
Hide file tree
Showing 23 changed files with 484 additions and 432 deletions.
1 change: 1 addition & 0 deletions .idea/dictionaries/develar.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions packages/electron-builder/src/macPackager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,11 +52,11 @@ export default class MacPackager extends PlatformPackager<MacOptions> {
break

case "dmg":
mapper("dmg", outDir => new DmgTarget(this, path.join(outDir, "mac")))
mapper("dmg", outDir => new DmgTarget(this, outDir))
break

case "pkg":
mapper("pkg", outDir => new PkgTarget(this, path.join(outDir, "mac")))
mapper("pkg", outDir => new PkgTarget(this, outDir))
break

default:
Expand Down
87 changes: 0 additions & 87 deletions test/out/__snapshots__/BuildTest.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -237,90 +237,3 @@ Object {
},
}
`;
exports[`sign custom buildResources and output dirs: linux 1`] = `
Array [
"TestApp-1.1.0-x86_64.AppImage",
]
`;
exports[`sign custom buildResources and output dirs: win 1`] = `
Array [
"Test App ßW Setup 1.1.0.exe",
]
`;
exports[`sign custom buildResources and output dirs: win 2`] = `
Array [
"TestApp-Setup-1.1.0.exe",
]
`;
exports[`sign scheme validation 1`] = `
"Config is invalid:
{
\\"foo\\": \\"Unknown option\\",
\\"mac\\": [
{
\\"foo\\": \\"Unknown option\\"
},
\\"Invalid option object\\"
]
}
Raw validation errors: [
{
\\"keyword\\": \\"additionalProperties\\",
\\"dataPath\\": \\"\\",
\\"schemaPath\\": \\"#/additionalProperties\\",
\\"params\\": {
\\"additionalProperty\\": \\"foo\\"
},
\\"message\\": \\"should NOT have additional properties\\"
},
{
\\"keyword\\": \\"additionalProperties\\",
\\"dataPath\\": \\".mac\\",
\\"schemaPath\\": \\"#/additionalProperties\\",
\\"params\\": {
\\"additionalProperty\\": \\"foo\\"
},
\\"message\\": \\"should NOT have additional properties\\"
},
{
\\"keyword\\": \\"type\\",
\\"dataPath\\": \\".mac\\",
\\"schemaPath\\": \\"#/properties/mac/anyOf/1/type\\",
\\"params\\": {
\\"type\\": \\"null\\"
},
\\"message\\": \\"should be null\\"
},
{
\\"keyword\\": \\"anyOf\\",
\\"dataPath\\": \\".mac\\",
\\"schemaPath\\": \\"#/properties/mac/anyOf\\",
\\"params\\": {},
\\"message\\": \\"should match some schema in anyOf\\"
}
]"
`;
exports[`sign scheme validation 2 1`] = `
"Config is invalid:
{
\\"appId\\": \\"Should be null,string\\"
}
Raw validation errors: [
{
\\"keyword\\": \\"type\\",
\\"dataPath\\": \\".appId\\",
\\"schemaPath\\": \\"#/properties/appId/type\\",
\\"params\\": {
\\"type\\": \\"null,string\\"
},
\\"message\\": \\"should be null,string\\"
}
]"
`;
88 changes: 88 additions & 0 deletions test/out/__snapshots__/ExtraBuildTest.js.snap
Original file line number Diff line number Diff line change
@@ -0,0 +1,88 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`custom buildResources and output dirs: linux 1`] = `
Array [
Object {
"file": "TestApp-1.1.0-x86_64.AppImage",
"safeArtifactName": undefined,
},
]
`;

exports[`custom buildResources and output dirs: win 1`] = `
Array [
Object {
"file": "Test App ßW Setup 1.1.0.exe",
"safeArtifactName": "TestApp-Setup-1.1.0.exe",
},
]
`;

exports[`scheme validation 1`] = `
"Config is invalid:
{
\\"foo\\": \\"Unknown option\\",
\\"mac\\": [
{
\\"foo\\": \\"Unknown option\\"
},
\\"Invalid option object\\"
]
}
Raw validation errors: [
{
\\"keyword\\": \\"additionalProperties\\",
\\"dataPath\\": \\"\\",
\\"schemaPath\\": \\"#/additionalProperties\\",
\\"params\\": {
\\"additionalProperty\\": \\"foo\\"
},
\\"message\\": \\"should NOT have additional properties\\"
},
{
\\"keyword\\": \\"additionalProperties\\",
\\"dataPath\\": \\".mac\\",
\\"schemaPath\\": \\"#/additionalProperties\\",
\\"params\\": {
\\"additionalProperty\\": \\"foo\\"
},
\\"message\\": \\"should NOT have additional properties\\"
},
{
\\"keyword\\": \\"type\\",
\\"dataPath\\": \\".mac\\",
\\"schemaPath\\": \\"#/properties/mac/anyOf/1/type\\",
\\"params\\": {
\\"type\\": \\"null\\"
},
\\"message\\": \\"should be null\\"
},
{
\\"keyword\\": \\"anyOf\\",
\\"dataPath\\": \\".mac\\",
\\"schemaPath\\": \\"#/properties/mac/anyOf\\",
\\"params\\": {},
\\"message\\": \\"should match some schema in anyOf\\"
}
]"
`;

exports[`scheme validation 2 1`] = `
"Config is invalid:
{
\\"appId\\": \\"Should be null,string\\"
}
Raw validation errors: [
{
\\"keyword\\": \\"type\\",
\\"dataPath\\": \\".appId\\",
\\"schemaPath\\": \\"#/properties/appId/type\\",
\\"params\\": {
\\"type\\": \\"null,string\\"
},
\\"message\\": \\"should be null,string\\"
}
]"
`;
21 changes: 12 additions & 9 deletions test/out/__snapshots__/filesTest.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,17 @@ exports[`expand not defined env 1`] = `"Env FOO_NOT_DEFINED is not defined"`;

exports[`extraResources on Linux and Windows 1`] = `
Array [
"RELEASES",
"Test App ßW Setup 1.1.0.exe",
"TestApp-1.1.0-full.nupkg",
]
`;

exports[`extraResources on Linux and Windows 2`] = `
Array [
"TestApp-Setup-1.1.0.exe",
Object {
"file": "Test App ßW Setup 1.1.0.exe",
"safeArtifactName": "TestApp-Setup-1.1.0.exe",
},
Object {
"file": "TestApp-1.1.0-full.nupkg",
"safeArtifactName": undefined,
},
Object {
"file": "RELEASES",
"safeArtifactName": undefined,
},
]
`;
10 changes: 8 additions & 2 deletions test/out/linux/__snapshots__/debTest.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@

exports[`arm deb 1`] = `
Array [
"TestApp_1.1.0_armv7l.deb",
Object {
"file": "TestApp_1.1.0_armv7l.deb",
"safeArtifactName": undefined,
},
]
`;

Expand All @@ -20,6 +23,9 @@ Categories=Development;

exports[`deb 1`] = `
Array [
"TestApp_1.1.0_amd64.deb",
Object {
"file": "TestApp_1.1.0_amd64.deb",
"safeArtifactName": undefined,
},
]
`;
35 changes: 28 additions & 7 deletions test/out/linux/__snapshots__/fpmTest.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,38 @@

exports[`rpm and tar.gz 1`] = `
Array [
"TestApp-1.1.0.rpm",
"TestApp-1.1.0.tar.gz",
Object {
"file": "TestApp-1.1.0.rpm",
"safeArtifactName": undefined,
},
Object {
"file": "TestApp-1.1.0.tar.gz",
"safeArtifactName": "TestApp-1.1.0.tar.gz",
},
]
`;

exports[`targets 1`] = `
Array [
"TestApp-1.1.0.7z",
"TestApp-1.1.0.freebsd",
"TestApp-1.1.0.pacman",
"TestApp-1.1.0.sh",
"TestApp-1.1.0.zip",
Object {
"file": "TestApp-1.1.0.7z",
"safeArtifactName": "TestApp-1.1.0.7z",
},
Object {
"file": "TestApp-1.1.0.freebsd",
"safeArtifactName": undefined,
},
Object {
"file": "TestApp-1.1.0.pacman",
"safeArtifactName": undefined,
},
Object {
"file": "TestApp-1.1.0.sh",
"safeArtifactName": undefined,
},
Object {
"file": "TestApp-1.1.0.zip",
"safeArtifactName": "TestApp-1.1.0.zip",
},
]
`;
15 changes: 12 additions & 3 deletions test/out/linux/__snapshots__/linuxArchiveTest.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,17 @@

exports[`tar 1`] = `
Array [
"TestApp-1.1.0.tar.bz2",
"TestApp-1.1.0.tar.lz",
"TestApp-1.1.0.tar.xz",
Object {
"file": "TestApp-1.1.0.tar.bz2",
"safeArtifactName": "TestApp-1.1.0.tar.bz2",
},
Object {
"file": "TestApp-1.1.0.tar.lz",
"safeArtifactName": "TestApp-1.1.0.tar.lz",
},
Object {
"file": "TestApp-1.1.0.tar.xz",
"safeArtifactName": "TestApp-1.1.0.tar.xz",
},
]
`;
10 changes: 8 additions & 2 deletions test/out/linux/__snapshots__/linuxPackagerTest.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,19 @@ Categories=Development;

exports[`AppImage 1`] = `
Array [
"TestApp-1.1.0-x86_64.AppImage",
Object {
"file": "TestApp-1.1.0-x86_64.AppImage",
"safeArtifactName": undefined,
},
]
`;

exports[`icons from ICNS 1`] = `
Array [
"TestApp-1.1.0-x86_64.AppImage",
Object {
"file": "TestApp-1.1.0-x86_64.AppImage",
"safeArtifactName": undefined,
},
]
`;

Expand Down
5 changes: 4 additions & 1 deletion test/out/linux/__snapshots__/snapTest.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -257,6 +257,9 @@ Categories=Development;

exports[`snap 1`] = `
Array [
"sep_1.1.0_amd64.snap",
Object {
"file": "sep_1.1.0_amd64.snap",
"safeArtifactName": undefined,
},
]
`;
32 changes: 16 additions & 16 deletions test/out/mac/__snapshots__/macPackagerTest.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,22 @@
exports[`electronDist 1`] = `"ENOENT: no such file or directory, scandir '<path>/Electron.app'"`;
exports[`one-package 1`] = `
Array [
Object {
"file": "latest-mac.json",
},
Object {
"file": "Test App ßW-1.1.0.dmg",
"safeArtifactName": "TestApp-1.1.0.dmg",
},
Object {
"file": "Test App ßW-1.1.0-mac.zip",
"safeArtifactName": "TestApp-1.1.0-mac.zip",
},
]
`;
exports[`one-package 2`] = `
Object {
"BuildMachineOSBuild": "15G31",
"CFBundleDisplayName": "Test App ßW",
Expand Down Expand Up @@ -54,22 +70,6 @@ Object {
}
`;
exports[`one-package 2`] = `
Array [
Object {
"file": "latest-mac.json",
},
Object {
"file": "Test App ßW-1.1.0.dmg",
"safeArtifactName": "TestApp-1.1.0.dmg",
},
Object {
"file": "Test App ßW-1.1.0-mac.zip",
"safeArtifactName": "TestApp-1.1.0-mac.zip",
},
]
`;
exports[`one-package 3`] = `
Object {
"releaseDate": "1970-01-01T00:00:00.000Z",
Expand Down
Loading

0 comments on commit 0bba4fe

Please sign in to comment.