title: Electron-builder Error: Application directory dist doesn't exists
body: <p>The app built a couple of years ago using:</p>
  <ul>
  <li>Angular v5.2.0</li>
  <li>Angular-CLI v1.6.4</li>
  <li>Electron v1.7.8</li>
  <li>Electron Builder v20.0.5</li>
  <li>Node 10.15.0</li>
  <li>NPM 6.4.1</li>
  <li>node-gyp 3.8.0</li>
  </ul>
  <p>It was last compiled in September 2019 but now when run <code>npm i</code> after cloning from the repo getting the following error on electron-builder. Running on Windows 10 and Visual Studio Code. I've got the same error on MacOS Catalina.</p>
  <pre><code>PS C:\[Project\directory]&gt; npm i      
  npm WARN deprecated fsevents@1.2.13: fsevents 1 will break on node v14+ and could be using insecure binaries. Upgrade t
  
  &gt; [projectname-version]-beta postinstall C:\Pinro\8track-player
  &gt; electron-builder install-app-deps
  
    • electron-builder version=20.0.5
    • loaded configuration file=C:[project\directory]\electron-builder.json
  Error: Application directory dist doesn't exists
      at C:\[project\directory]\node_modules\electron-builder-lib\src\util\config.ts:140:13
  From previous event:
      at computeDefaultAppDirectory (C:\[project\directory]\node_modules\electron-builder-lib\out\util\config.js:131:22)
      at C:\[project\directory]\node_modules\electron-builder\src\cli\install-app-deps.ts:52:78
      at Generator.next (&lt;anonymous&gt;)
  From previous event:
      at installAppDeps (C:\[project\directory]\node_modules\electron-builder\out\cli\install-app-deps.js:51:21)
      at then (C:\[project\directory]\node_modules\electron-builder\src\cli\cli.ts:48:33)
      at runCallback (timers.js:705:18)
      at tryOnImmediate (timers.js:676:5)
      at processImmediate (timers.js:658:5)
  From previous event:
      at Object.args [as handler] (C:\[project\directory]\node_modules\electron-builder\src\cli\cli.ts:48:33)
      at Object.runCommand (C:\[project\directory]\node_modules\electron-builder\node_modules\yargs\lib\command.js:235:44
      at Object.parseArgs [as _parseArgs] (C:\[project\directory]\node_modules\electron-builder\node_modules\yargs\yargs.
      at Object.get [as argv] (C:\[project\directory]\node_modules\electron-builder\node_modules\yargs\yargs.js:965:21)
      at Object.&lt;anonymous&gt; (C:\[project\directory]node_modules\electron-builder\src\cli\cli.ts:42:15)
      at Module._compile (internal/modules/cjs/loader.js:689:30)
      at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
      at Module.load (internal/modules/cjs/loader.js:599:32)
      at tryModuleLoad (internal/modules/cjs/loader.js:538:12)
      at Function.Module._load (internal/modules/cjs/loader.js:530:3)
      at Function.Module.runMain (internal/modules/cjs/loader.js:742:12)
      at startup (internal/bootstrap/node.js:283:19)
      at bootstrapNodeJSCore (internal/bootstrap/node.js:743:3)
  npm ERR! code ELIFECYCLE
  npm ERR! errno 1
  npm ERR! [project-name-version]-beta postinstall: `electron-builder install-app-deps`
  npm ERR! Exit status 1
  npm ERR!
  npm ERR! Failed at the [project-name-version]-beta postinstall script.
  npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
  
  npm ERR! A complete log of this run can be found in:
  npm ERR!     C:\[Project directory]\AppData\Roaming\npm-cache\_logs\2020-07-12T07_25_33_106Z-debug.log
  PS C:\[Project\directory]&gt;
  
  </code></pre>
  <p><strong>package.json:</strong></p>
  <pre><code>{
    &quot;name&quot;: &quot;[project-name]&quot;,
    &quot;version&quot;: &quot;[version-number]-beta&quot;,
    &quot;description&quot;: &quot;&quot;,
    &quot;author&quot;: {
      &quot;name&quot;: &quot;&quot;,
      &quot;email&quot;: &quot;&quot;
    },
    &quot;keywords&quot;: [
      &quot;angular&quot;,
      &quot;angular 5&quot;,
      &quot;electron&quot;,
      &quot;typescript&quot;,
      &quot;sass&quot;
    ],
    &quot;main&quot;: &quot;main.js&quot;,
    &quot;private&quot;: true,
    &quot;scripts&quot;: {
      &quot;ng&quot;: &quot;ng&quot;,
      &quot;lint&quot;: &quot;ng lint&quot;,
      &quot;start&quot;: &quot;tsc main.ts &amp;&amp; npm-run-all --parallel webpack:watch electron:serve&quot;,
      &quot;webpack:watch&quot;: &quot;webpack --watch&quot;,
      &quot;start:web&quot;: &quot;webpack-dev-server --content-base . --port 4200 --inline&quot;,
      &quot;build:electron:main&quot;: &quot;tsc main.ts --outDir dist &amp;&amp; copyfiles package.json dist &amp;&amp; cd dist &amp;&amp; npm install --prod &amp;&amp; cd ..&quot;,
      &quot;build&quot;: &quot;webpack --display-error-details &amp;&amp; npm run build:electron:main&quot;,
      &quot;build:prod&quot;: &quot;cross-env NODE_ENV=production npm run build&quot;,
      &quot;electron:serve&quot;: &quot;npm run build:electron:main &amp;&amp; electron ./dist --serve&quot;,
      &quot;electron:test&quot;: &quot;electron ./dist&quot;,
      &quot;electron:dev&quot;: &quot;npm run build &amp;&amp; electron ./dist&quot;,
      &quot;electron:prod&quot;: &quot;npm run build:prod &amp;&amp; electron ./dist&quot;,
      &quot;electron:linux&quot;: &quot;npm run build:prod &amp;&amp; npx electron-builder build --linux&quot;,
      &quot;electron:windows&quot;: &quot;npm run build:prod &amp;&amp; npx electron-builder build --windows&quot;,
      &quot;electron:mac&quot;: &quot;npm run build:prod &amp;&amp; npx electron-builder build --mac&quot;,
      &quot;rebuild&quot;: &quot;electron-rebuild -f -w sqlite3 -v 1.8&quot;,
      &quot;test&quot;: &quot;karma start ./karma.conf.js&quot;,
      &quot;pree2e&quot;: &quot;webdriver-manager update --standalone false --gecko false --quiet &amp;&amp; npm run build&quot;,
      &quot;e2e&quot;: &quot;protractor ./protractor.conf.js&quot;,
      &quot;postinstall&quot;: &quot;electron-builder install-app-deps&quot;
    },
    &quot;dependencies&quot;: {
      &quot;@types/bluebird&quot;: &quot;3.5.20&quot;,
      &quot;electron-builder-squirrel-windows&quot;: &quot;20.0.5&quot;,
      &quot;electron-rebuild&quot;: &quot;^1.11.0&quot;,
      &quot;electron-squirrel-startup&quot;: &quot;^1.0.0&quot;,
      &quot;sqlite3&quot;: &quot;https://github.com/mapbox/node-sqlite3/tarball/master&quot;
    },
    &quot;devDependencies&quot;: {
      &quot;@angular-devkit/core&quot;: &quot;^0.3.1&quot;,
      &quot;@angular/cli&quot;: &quot;1.6.4&quot;,
      &quot;@angular/common&quot;: &quot;5.2.0&quot;,
      &quot;@angular/compiler&quot;: &quot;5.2.0&quot;,
      &quot;@angular/compiler-cli&quot;: &quot;5.2.0&quot;,
      &quot;@angular/core&quot;: &quot;5.2.0&quot;,
      &quot;@angular/forms&quot;: &quot;5.2.0&quot;,
      &quot;@angular/http&quot;: &quot;5.2.0&quot;,
      &quot;@angular/language-service&quot;: &quot;5.2.0&quot;,
      &quot;@angular/platform-browser&quot;: &quot;5.2.0&quot;,
      &quot;@angular/platform-browser-dynamic&quot;: &quot;5.2.0&quot;,
      &quot;@angular/router&quot;: &quot;5.2.0&quot;,
      &quot;@ng-bootstrap/ng-bootstrap&quot;: &quot;1.1.1&quot;,
      &quot;@ngx-translate/core&quot;: &quot;9.0.1&quot;,
      &quot;@ngx-translate/http-loader&quot;: &quot;2.0.0&quot;,
      &quot;@types/core-js&quot;: &quot;0.9.46&quot;,
      &quot;@types/jasmine&quot;: &quot;2.5.54&quot;,
      &quot;@types/jasminewd2&quot;: &quot;2.0.2&quot;,
      &quot;@types/lodash&quot;: &quot;^4.14.50&quot;,
      &quot;@types/node&quot;: &quot;^7.10.2&quot;,
      &quot;amplitudejs&quot;: &quot;^3.2.3&quot;,
      &quot;autoprefixer&quot;: &quot;7.1.4&quot;,
      &quot;bootstrap&quot;: &quot;^4.0.0&quot;,
      &quot;chart.js&quot;: &quot;^2.5.0&quot;,
      &quot;circular-dependency-plugin&quot;: &quot;3.0.0&quot;,
      &quot;codelyzer&quot;: &quot;3.2.0&quot;,
      &quot;copy-webpack-plugin&quot;: &quot;4.1.1&quot;,
      &quot;copyfiles&quot;: &quot;1.2.0&quot;,
      &quot;core-js&quot;: &quot;2.4.1&quot;,
      &quot;cross-env&quot;: &quot;5.0.5&quot;,
      &quot;crypto-js&quot;: &quot;^3.1.9-1&quot;,
      &quot;css-loader&quot;: &quot;0.28.7&quot;,
      &quot;cssnano&quot;: &quot;3.10.0&quot;,
      &quot;diskspace&quot;: &quot;^2.0.0&quot;,
      &quot;electron&quot;: &quot;^1.8.8&quot;,
      &quot;electron-builder&quot;: &quot;20.0.5&quot;,
      &quot;electron-builder-squirrel-windows&quot;: &quot;20.0.5&quot;,
      &quot;electron-json-storage&quot;: &quot;^4.0.2&quot;,
      &quot;electron-log&quot;: &quot;^2.2.14&quot;,
      &quot;electron-reload&quot;: &quot;1.2.2&quot;,
      &quot;electron-squirrel-startup&quot;: &quot;^1.0.0&quot;,
      &quot;enhanced-resolve&quot;: &quot;3.3.0&quot;,
      &quot;exports-loader&quot;: &quot;0.6.4&quot;,
      &quot;file-loader&quot;: &quot;1.1.5&quot;,
      &quot;html-loader&quot;: &quot;0.5.1&quot;,
      &quot;html-webpack-plugin&quot;: &quot;2.29.0&quot;,
      &quot;is-online&quot;: &quot;^7.0.0&quot;,
      &quot;istanbul-instrumenter-loader&quot;: &quot;3.0.0&quot;,
      &quot;jasmine-core&quot;: &quot;2.8.0&quot;,
      &quot;jasmine-spec-reporter&quot;: &quot;4.2.1&quot;,
      &quot;jquery&quot;: &quot;^3.3.1&quot;,
      &quot;json-loader&quot;: &quot;0.5.7&quot;,
      &quot;karma&quot;: &quot;1.7.1&quot;,
      &quot;karma-chrome-launcher&quot;: &quot;2.2.0&quot;,
      &quot;karma-cli&quot;: &quot;1.0.1&quot;,
      &quot;karma-coverage-istanbul-reporter&quot;: &quot;1.3.0&quot;,
      &quot;karma-jasmine&quot;: &quot;1.1.0&quot;,
      &quot;karma-jasmine-html-reporter&quot;: &quot;0.2.2&quot;,
      &quot;karma-sourcemap-loader&quot;: &quot;0.3.7&quot;,
      &quot;less-loader&quot;: &quot;4.0.5&quot;,
      &quot;minimist&quot;: &quot;1.2.0&quot;,
      &quot;mkdirp&quot;: &quot;0.5.1&quot;,
      &quot;node-cron&quot;: &quot;^1.2.1&quot;,
      &quot;node-vibrant&quot;: &quot;^3.0.0&quot;,
      &quot;npm-run-all&quot;: &quot;^4.1.2&quot;,
      &quot;npx&quot;: &quot;^9.7.1&quot;,
      &quot;os-name&quot;: &quot;^2.0.1&quot;,
      &quot;popper.js&quot;: &quot;^1.14.3&quot;,
      &quot;postcss-custom-properties&quot;: &quot;6.2.0&quot;,
      &quot;postcss-loader&quot;: &quot;2.0.6&quot;,
      &quot;postcss-url&quot;: &quot;7.1.2&quot;,
      &quot;protractor&quot;: &quot;5.1.2&quot;,
      &quot;raw-loader&quot;: &quot;0.5.1&quot;,
      &quot;replace&quot;: &quot;^0.3.0&quot;,
      &quot;rimraf&quot;: &quot;^2.6.2&quot;,
      &quot;rxjs&quot;: &quot;5.5.2&quot;,
      &quot;sass-loader&quot;: &quot;6.0.6&quot;,
      &quot;script-loader&quot;: &quot;0.7.1&quot;,
      &quot;source-map-loader&quot;: &quot;0.2.1&quot;,
      &quot;style-loader&quot;: &quot;0.18.2&quot;,
      &quot;stylus-loader&quot;: &quot;3.0.1&quot;,
      &quot;ts-node&quot;: &quot;3.3.0&quot;,
      &quot;tslint&quot;: &quot;5.7.0&quot;,
      &quot;typescript&quot;: &quot;2.6.2&quot;,
      &quot;uglifyjs-webpack-plugin&quot;: &quot;1.0.0&quot;,
      &quot;url-loader&quot;: &quot;0.6.2&quot;,
      &quot;wait-on&quot;: &quot;^2.1.0&quot;,
      &quot;webdriver-manager&quot;: &quot;12.0.6&quot;,
      &quot;webpack&quot;: &quot;3.8.1&quot;,
      &quot;webpack-concat-plugin&quot;: &quot;1.4.0&quot;,
      &quot;webpack-dev-server&quot;: &quot;2.9.3&quot;,
      &quot;zone.js&quot;: &quot;0.8.17&quot;
    },
    &quot;files&quot;: [
      &quot;*.js&quot;,
      &quot;build&quot;,
      &quot;node_modules&quot;
    ],
    &quot;engines&quot;: {
      &quot;node&quot;: &quot;10.15.0&quot;
    }
  }
  
  </code></pre>
  <p><strong>electron-builder.json:</strong></p>
  <pre><code>{
    &quot;productName&quot;: &quot;[Project name]&quot;,
    &quot;appId&quot;: &quot;[ID]&quot;,
    &quot;directories&quot;: {
      &quot;app&quot;: &quot;dist&quot;,
      &quot;output&quot;: &quot;app-builds&quot;
    },
    &quot;win&quot;: {
      &quot;icon&quot;: &quot;dist/favicon&quot;,
      &quot;target&quot;: [
        &quot;squirrel&quot;
      ]
    },
    &quot;mac&quot;: {
      &quot;icon&quot;: &quot;dist/favicon&quot;,
      &quot;target&quot;: [
        &quot;dmg&quot;
      ]
    },
    &quot;linux&quot;: {
      &quot;icon&quot;: &quot;dist&quot;,
      &quot;target&quot;: [
        &quot;AppImage&quot;
      ]
    }
  }
  
  </code></pre>
  <p>What I have done so far:</p>
  <p>Windows 10:</p>
  <ol>
  <li>Installed Node 10.15.0 and NPM 6.4.1</li>
  <li>node-gyp 3.8.0</li>
  <li>windows-build-tools</li>
  </ol>
  <p>Can you please suggest any solution to run the app? Thanks in advance.</p>
  <p><a href="https://i.stack.imgur.com/NyQZU.png" rel="nofollow noreferrer">Error debug log - screencapture</a></p>