cspell hook install fails due pre-commit assumptions regarding npm packages
I am raising this bug here as cspell is still unusable as a pre-commit hook even after the author made additional changes and I am afraid that the root cause is no longer inside cspell package.

Mainly cspell is a typescript project that is published on npm and you cannot run it without building it first. Apparently pre-commit does not know about this concenpt (or I am not aware about it).'

More information can be found on https://github.com/Jason3S/cspell/issues/53#issuecomment-402562237

To enabled cspell hook it should be enough to add this:
```
  - repo: https://github.com/Jason3S/cspell.git
    rev: v3.2.2
    hooks:
      - id: cspell
```

Still, once you run pre-precommit you soon endup with something like:
```
cspell...................................................................Failed
hookid: cspell

internal/modules/cjs/loader.js:611
    throw err;
    ^

Error: Cannot find module './dist/app'
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:609:15)
    at Function.Module._load (internal/modules/cjs/loader.js:535:25)
    at Module.require (internal/modules/cjs/loader.js:663:17)
    at require (internal/modules/cjs/helpers.js:20:18)
    at Object.<anonymous> (/Users/ssbarnea/.cache/pre-commit/repolvipoC/bin.js:5:1)
    at Module._compile (internal/modules/cjs/loader.js:734:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:745:10)
    at Module.load (internal/modules/cjs/loader.js:626:32)
    at tryModuleLoad (internal/modules/cjs/loader.js:566:12)
    at Function.Module._load (internal/modules/cjs/loader.js:558:3)
internal/modules/cjs/loader.js:611
    throw err;
    ^
```

The maintainer of cspell mentioned that the project was not designed to run from source, and the expected behavior is to install the npm package. I have to say that I kinda agree with his view.

How can we address this issue? 
diff --git a/pre_commit/languages/node.py b/pre_commit/languages/node.py
index b313bf5..e7962cc 100644
--- a/pre_commit/languages/node.py
+++ b/pre_commit/languages/node.py
@@ -62,10 +62,11 @@ def install_environment(prefix, version, additional_dependencies):
             cmd.extend(['-n', version])
         cmd_output(*cmd)
 
+        dep = 'git+file:///{}'.format(prefix.prefix_dir)
         with in_env(prefix, version):
             helpers.run_setup_cmd(
                 prefix,
-                ('npm', 'install', '-g', '.') + additional_dependencies,
+                ('npm', 'install', '-g', dep) + additional_dependencies,
             )
 
 
['pre_commit/languages/node.py']