Closed tomsteg closed 8 years ago
As reported by another user it sounds like apm
is failing to install the dependencies properly, can you try uninstalling the plugin and then installing it again?
I uninstalled it and installed it again, but I get the same error. I added a screenshot of my settings.
Do you have npm
installed on your system? If so can you run npm list --depth=0
in the ~/.atom/packages/linter-phpmd
folder?
The only reason it should ever be saying that is if it somehow has an out of date atom-linter
installed, but got as far in updating it as removing that old dependency.
I get the following result:
linter-phpmd@1.4.1 /Users/thomassteglich/.atom/packages/linter-phpmd
├── atom-linter@4.3.4
└── atom-package-deps@3.0.7
Hmmm, looks like it's actually loading the module from the linter-php
package, can you run npm list
(without the depth restriction) in there?
Here is the list without restrictions (and error line at the bottom):
linter-phpmd@1.4.1 /Users/thomassteglich/.atom/packages/linter-phpmd
├─┬ atom-linter@4.3.4
│ ├─┬ consistent-path@1.0.3
│ │ └─┬ shell-path@1.0.8
│ │ └─┬ strip-ansi@3.0.0
│ │ └── ansi-regex@2.0.0
│ ├── named-js-regexp@1.3.1
│ └─┬ tmp@0.0.28 invalid
│ └── os-tmpdir@1.0.1
└─┬ atom-package-deps@3.0.7
└── sb-callsite@1.1.2
npm ERR! invalid: tmp@0.0.28 /Users/thomassteglich/.atom/packages/linter-phpmd/node_modules/atom-linter/node_modules/tmp
Run that in ~/.atom/packages/linter-php
(not linter-phpmd) :wink:
Oh, sorry. Here is the list from linter-php:
linter-php@1.1.7 /Users/thomassteglich/.atom/packages/linter-php
├─┬ atom-linter@4.3.4
│ ├─┬ consistent-path@1.0.3
│ │ └─┬ shell-path@1.0.8
│ │ └─┬ strip-ansi@3.0.0
│ │ └── ansi-regex@2.0.0
│ ├── named-js-regexp@1.3.1
│ └─┬ tmp@0.0.28 invalid
│ └── os-tmpdir@1.0.1
└─┬ atom-package-deps@3.0.7
└── sb-callsite@1.1.2
npm ERR! invalid: tmp@0.0.28 /Users/thomassteglich/.atom/packages/linter-php/node_modules/atom-linter/node_modules/tmp
And here is the list from phpcs:
linter-phpcs@1.3.0 /Users/thomassteglich/.atom/packages/linter-phpcs
├─┬ atom-linter@3.4.1
│ ├─┬ tmp@0.0.28 invalid
│ │ └── os-tmpdir@1.0.1
│ └── xregexp@2.0.0
├── atom-package-deps@2.1.3
└─┬ minimatch@3.0.0
└─┬ brace-expansion@1.1.2
├── balanced-match@0.3.0
└── concat-map@0.0.1
npm ERR! invalid: tmp@0.0.28 /Users/thomassteglich/.atom/packages/linter-phpcs/node_modules/atom-linter/node_modules/tmp
I disabled phpcs, restarted atom, and enabled phpcs again. The error has gone.
Looks like a release for linter-phpcs
is in order :wink:.
I wish Atom would fix the bug that causes issues like this :frowning:.
when I save a php file with html code in it, I get an error: