Results 69 comments of Felix Brucker

Thanks for the link, i got it working with some small modifications: I changed the line in question (worker.js) from ``` var _config = require('../config'); ``` to ``` var _config...

Yes indeed, when adding your suggested pkg config to `thread.js` package.json i only needed `"assets": ["lib/worker.js"],` in my projects package.json

Though i still had to use the `__dirname` fix for the `..config` thingy. Probably related to this line: https://github.com/andywer/threads.js/blob/master/src/worker.node/worker.js#L5 ?

Using `scripts` only produced some warnings and finally an error about the .map files. I changed the globs to only use .js files but it still can't find ../config. I...

Sure, last i tried with the js globs was ``` "pkg": { "scripts": [ "lib/defaults*.js", "lib/worker.node/*.js" ] } ``` before it was ``` "pkg": { "assets": [ "lib/defaults*", "lib/worker.node/*" ]...

> Hence, in order to make use of a file collected at packaging time (require a javascript file or serve an asset) you should take __filename, __dirname, process.pkg.defaultEntrypoint or require.main.filename...

Just did that (infact i added some more stuff just to be sure: `"scripts": ["lib/config.js","lib/defaults*.js","lib/worker.node/*.js","lib/*.js","lib/**/*.js"]`) but it didn't work as well.

The path you mentioned is a cache of recently accessed files by your user. The detection is a heuristic detection (HEUR), in this case (if you used the official binary...