philipwalton / html-inspector

HTML Inspector is a code quality tool to help you and your team write better markup. It's written in JavaScript and runs in the browser, so testing your HTML has never been easier.
2.32k stars 145 forks source link

NPM Error #40

Closed adrianstainforth closed 10 years ago

adrianstainforth commented 10 years ago

Just tried to set up the NPM module but looks like there is an issue module.js:

module.js:340
    throw err;
          ^
Error: Cannot find module 'shelljs/global'
    at Function.Module._resolveFilename (module.js:338:15)
    at Function.Module._load (module.js:280:25)
    at Module.require (module.js:364:17)
    at require (module.js:380:17)
    at Object.<anonymous> (/usr/local/share/npm/lib/node_modules/html-inspector/bin/html-inspector:4:1)
    at Module._compile (module.js:456:26)
    at Object.Module._extensions..js (module.js:474:10)
    at Module.load (module.js:356:32)
    at Function.Module._load (module.js:312:12)
    at Function.Module.runMain (module.js:497:10)
philipwalton commented 10 years ago

Thanks for catching this. I accidentally put "shelljs" in devDependencies instead of just dependencies. It should be fixed in v0.7.3.

Let me know if you're still having issues.

adrianstainforth commented 10 years ago

Ok, firstly thanks for the quick response, that's working now and I can install it. However I'm now getting a reference failure:

htmlinspector index.html 
ReferenceError: Can't find variable: HTMLInspector

I did fork and run your test see if I can see anything obvious, but not sure I can see where it's failing

philipwalton commented 10 years ago

When you say you ran the tests, does that mean you ran npm test with no failures?

Also, is your index.html file available online anywhere that I could take a look?

adrianstainforth commented 10 years ago

Sorry it's taken a bit to get back. Well I forked and ran grunt test, but assume that it runs the same tests?

My files are here if you want a look https://github.com/djforth/image-replace

philipwalton commented 10 years ago

OK, I was able to reproduce it on my work laptop with your repo. I'll take a look at it later to see if I can track down the issue.

I'm going to keep this issue closed, but I opened up another one to track this bug.