Browse Source

fix(Builder): fix exclusion of packed app building

Evshiron Magicka 8 years ago
parent
commit
dba64401e9
1 changed files with 2 additions and 2 deletions
  1. 2 2
      src/lib/Builder.ts

+ 2 - 2
src/lib/Builder.ts

@@ -387,7 +387,7 @@ export class Builder {
 
         debug('in copyFiles', 'ignore', ignore);
 
-        const files = await globby(config.files, {
+        const files: string[] = await globby(config.files, {
             cwd: this.dir,
             // TODO: https://github.com/isaacs/node-glob#options, warn for cyclic links.
             follow: true,
@@ -409,7 +409,7 @@ export class Builder {
                     postfix: '.zip',
                 });
 
-                await compress(this.dir, files, 'zip', nwFile);
+                await compress(this.dir, files.filter((file) => !file.endsWith('/')), 'zip', nwFile);
 
                 const { path: tempDir } = await tmpDir();
                 await this.writeStrippedManifest(resolve(tempDir, 'package.json'), pkg, config);