Fix @atom/notify's binary path when running within Atom's ASAR archive

/cc @rafeca
This commit is contained in:
Nathan Sobo
2019-05-13 12:12:36 -06:00
parent 5ce573ca42
commit a952e40b31
3 changed files with 6 additions and 5 deletions

6
package-lock.json generated
View File

@@ -456,9 +456,9 @@
}
},
"@atom/notify": {
"version": "1.2.2",
"resolved": "https://registry.npmjs.org/@atom/notify/-/notify-1.2.2.tgz",
"integrity": "sha512-6hVDX5Y1dov5Wk0e3deLUzPLiBaz7g180Uzh8ca5zu/iFHEGSeRNzV8DY7m9fmT00/gVkptyx+vjGewYctsUpA=="
"version": "1.3.0",
"resolved": "https://registry.npmjs.org/@atom/notify/-/notify-1.3.0.tgz",
"integrity": "sha512-dFBaZ2a2BEfS/uiMq/dkYGl0mGaaf8u9L8wqwr/ODSt0rw2weQe/5owtYnTeb0YoqJxO9zLQzgE1PscThAxyMw=="
},
"@atom/nsfw": {
"version": "1.0.22",

View File

@@ -14,7 +14,7 @@
"license": "MIT",
"electronVersion": "2.0.18",
"dependencies": {
"@atom/notify": "1.2.2",
"@atom/notify": "1.3.0",
"@atom/nsfw": "1.0.22",
"@atom/source-map-support": "^0.3.4",
"@atom/watcher": "1.3.1",

View File

@@ -586,7 +586,8 @@ class PathWatcherManager {
if (this.useExperimentalWatcher()) {
if (!this.notifyWatcher) {
const options = {
onError: (error) => {
transformBinPath: (binPath) => binPath.replace(/\bapp\.asar\b/, 'app.asar.unpacked'),
onError: error => {
throw new Error(`Error watching file system: ${error}`)
}
}