Skip to content
This repository has been archived by the owner on Jun 29, 2019. It is now read-only.

Commit

Permalink
Fix build-darwin task to compress Hain.app file only without redu…
Browse files Browse the repository at this point in the history
…ndant files
  • Loading branch information
Heejin (macbook) committed Mar 2, 2017
1 parent d2afb2d commit b386399
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -68,12 +68,12 @@ function buildZip(arch) {
}

// Workaround to build zip file which is including symlinks
function buildZipUsingExec(arch, platform) {
function buildZipUsingExec(arch, platform, filesToCompress) {
const filename = `hain-${platform}-${arch}-v${appPkg.version}.zip`;
const targetDir = `hain-${platform}-${arch}`;
const targetDir = `Hain-${platform}-${arch}`;
const workingDir = path.join(__dirname, 'out', targetDir);
return new Promise((resolve, reject) => {
cp.exec(`zip --symlinks -r ../${filename} *`, {
cp.exec(`zip --symlinks -r ../${filename} ${filesToCompress}`, {
cwd: workingDir
}, (err, stdout, stderr) => {
if (err) {
Expand Down Expand Up @@ -139,7 +139,7 @@ gulp.task('build-debian', ['renderer'], () => {

gulp.task('build-darwin', ['renderer', 'deps'], () => {
return build('x64', 'darwin', 'icon.icns')
.then(() => buildZipUsingExec('x64', 'darwin'));
.then(() => buildZipUsingExec('x64', 'darwin', '*.app'));
});

gulp.task('build-installer', ['build', 'build-zip'], () => {
Expand Down

0 comments on commit b386399

Please sign in to comment.