importre / alfred-slack-status

:speech_balloon: Alfred 3 workflow to change Slack statuses at once
MIT License
13 stars 3 forks source link

npm install fails when Alfred preferences aren’t in the default location #4

Open aaronk6 opened 6 years ago

aaronk6 commented 6 years ago

My Alfred preferences are shared across multiple users (using Alfred’s syncing feature), and are therefore stored in /Users/Shared/Library/Application Support/Alfred 3. However, this could also be any other location, e.g. Dropbox.

npm i -g alfred-slack-status                                       ⏎

> alfred-slack-status@0.2.0 postinstall /usr/local/lib/node_modules/alfred-slack-status
> alfy-init

{ Error: Command failed: alfred-link
Error: Alfred preferences not found at location /Users/aaron/Library/Preferences/com.runningwithcrayons.Alfred-Preferences-3.plist
    at pathExists.then.exists (/usr/local/lib/node_modules/alfred-slack-status/node_modules/resolve-alfred-prefs/index.js:15:10)
    at <anonymous>

    at Promise.all.then.arr (/usr/local/lib/node_modules/alfred-slack-status/node_modules/execa/index.js:201:11)
    at <anonymous>
    at process._tickCallback (internal/process/next_tick.js:188:7)
  code: 1,
  killed: false,
  stdout: '',
  stderr: 'Error: Alfred preferences not found at location /Users/aaron/Library/Preferences/com.runningwithcrayons.Alfred-Preferences-3.plist\n    at pathExists.then.exists (/usr/local/lib/node_modules/alfred-slack-status/node_modules/resolve-alfred-prefs/index.js:15:10)\n    at <anonymous>\n',
  failed: true,
  signal: null,
  cmd: 'alfred-link',
  timedOut: false }
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! alfred-slack-status@0.2.0 postinstall: `alfy-init`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the alfred-slack-status@0.2.0 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!     /Users/aaron/.npm/_logs/2018-02-01T12_14_04_834Z-debug.log