Socket
Socket
Sign inDemoInstall

global-prefix

Package Overview
Dependencies
1
Maintainers
1
Versions
10
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.1.0 to 0.1.1

8

index.js

@@ -10,2 +10,8 @@ /*!

/**
* This is the code used internally by npm to
* resolve the global prefix.
*/
var isWindows = require('is-windows');
var path = require('path');

@@ -16,3 +22,3 @@ var prefix;

prefix = process.env.PREFIX;
} else if (process.platform === 'win32') {
} else if (isWindows()) {
// c:\node\node.exe --> prefix=c:\node\

@@ -19,0 +25,0 @@ prefix = path.dirname(process.execPath);

36

package.json
{
"name": "global-prefix",
"description": "Get the npm global path prefix.",
"version": "0.1.0",
"version": "0.1.1",
"homepage": "https://github.com/jonschlinkert/global-prefix",
"author": {
"name": "Jon Schlinkert",
"url": "https://github.com/jonschlinkert"
},
"repository": {
"type": "git",
"url": "git://github.com/jonschlinkert/global-prefix.git"
},
"author": "Jon Schlinkert (https://github.com/jonschlinkert)",
"repository": "jonschlinkert/global-prefix",
"bugs": {
"url": "https://github.com/jonschlinkert/global-prefix/issues"
},
"license": {
"type": "MIT",
"url": "https://github.com/jonschlinkert/global-prefix/blob/master/LICENSE"
},
"license": "MIT",
"files": [

@@ -34,3 +25,20 @@ "index.js"

"should": "*"
},
"dependencies": {
"is-windows": "^0.1.0"
},
"keywords": [
"global",
"module",
"modules",
"npm",
"path",
"prefix",
"resolve"
],
"verb": {
"related": {
"list": ["global-modules", "global-paths"]
}
}
}
}

@@ -1,9 +0,9 @@

# global-prefix [![NPM version](https://badge.fury.io/js/global-prefix.svg)](http://badge.fury.io/js/global-prefix) [![Build Status](https://travis-ci.org/jonschlinkert/global-prefix.svg)](https://travis-ci.org/jonschlinkert/global-prefix)
# global-prefix [![NPM version](https://badge.fury.io/js/global-prefix.svg)](http://badge.fury.io/js/global-prefix) [![Build Status](https://travis-ci.org/jonschlinkert/global-prefix.svg)](https://travis-ci.org/jonschlinkert/global-prefix)
> Get the npm global path prefix.
## Install with [npm](npmjs.org)
Install with [npm](https://www.npmjs.com/)
```bash
npm i global-prefix --save
```sh
$ npm i global-prefix --save
```

@@ -20,27 +20,34 @@

## Run tests
## Related projects
* [global-modules](https://github.com/jonschlinkert/global-modules): The directory used by npm for globally installed npm modules.
* [global-paths](https://github.com/jonschlinkert/global-paths): Returns an array of unique "global" directories based on the user's platform and environment. The… [more](https://github.com/jonschlinkert/global-paths)
## Running tests
Install dev dependencies:
```bash
npm i -d && npm test
```sh
$ npm i -d && npm test
```
## Contributing
Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](https://github.com/jonschlinkert/global-prefix/issues)
## Author
Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](https://github.com/jonschlinkert/global-prefix/issues/new)
## Authors
**Jon Schlinkert**
+ [github/jonschlinkert](https://github.com/jonschlinkert)
+ [twitter/jonschlinkert](http://twitter.com/jonschlinkert)
+ [twitter/jonschlinkert](http://twitter.com/jonschlinkert)
## License
Copyright (c) 2015 Jon Schlinkert
Copyright © 2015 Jon Schlinkert
[Copyright (c) npm, Inc. and Contributors](https://github.com/npm/npm/blob/master/LICENSE)
Released under the MIT license
Released under the MIT license.
***
_This file was generated by [verb-cli](https://github.com/assemble/verb-cli) on February 28, 2015._
_This file was generated by [verb-cli](https://github.com/assemble/verb-cli) on July 16, 2015._
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc