default-browser-id
Advanced tools
Comparing version 0.1.1 to 0.1.2
'use strict'; | ||
var bplist = require('bplist-parser'); | ||
var untildify = require('untildify'); | ||
var file = process.env.HOME + '/Library/Preferences/com.apple.LaunchServices.plist'; | ||
var file = untildify('~/Library/Preferences/com.apple.LaunchServices.plist'); | ||
var bundleId = 'com.apple.Safari'; | ||
@@ -6,0 +7,0 @@ |
{ | ||
"name": "default-browser-id", | ||
"version": "0.1.1", | ||
"version": "0.1.2", | ||
"description": "Get the bundle identifier of the default browser (OS X). Example: com.apple.Safari", | ||
@@ -44,3 +44,4 @@ "license": "MIT", | ||
"dependencies": { | ||
"bplist-parser": "0.0.4" | ||
"bplist-parser": "0.0.5", | ||
"untildify": "^0.1.0" | ||
}, | ||
@@ -47,0 +48,0 @@ "devDependencies": { |
@@ -1,2 +0,2 @@ | ||
# default-browser-id [![Build Status](https://travis-ci.org/sindresorhus/default-browser-id.png?branch=master)](http://travis-ci.org/sindresorhus/default-browser-id) | ||
# default-browser-id [![Build Status](https://travis-ci.org/sindresorhus/default-browser-id.svg?branch=master)](https://travis-ci.org/sindresorhus/default-browser-id) | ||
@@ -9,5 +9,5 @@ > Get the [bundle identifier](https://developer.apple.com/library/Mac/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html#//apple_ref/doc/plist/info/CFBundleIdentifier) of the default browser (OS X) | ||
```bash | ||
$ npm install --save default-browser-id | ||
``` | ||
npm install --save default-browser-id | ||
``` | ||
@@ -20,4 +20,6 @@ | ||
defaultBrowserId(); | ||
//=> com.apple.Safari | ||
defaultBrowserId(function (err, browserId) { | ||
console.log(browserId); | ||
//=> com.apple.Safari | ||
}); | ||
``` | ||
@@ -30,11 +32,11 @@ | ||
```bash | ||
$ npm install --global default-browser-id | ||
``` | ||
npm install --global default-browser-id | ||
``` | ||
### Usage | ||
```bash | ||
$ default-browser-id | ||
``` | ||
default-browser-id | ||
``` | ||
@@ -46,2 +48,2 @@ Which will for example output `com.apple.Safari`. | ||
MIT © [Sindre Sorhus](http://sindresorhus.com) | ||
[MIT](http://opensource.org/licenses/MIT) © [Sindre Sorhus](http://sindresorhus.com) |
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 1 instance in 1 package
3082
39
46
1
2
+ Addeduntildify@^0.1.0
+ Addedbplist-parser@0.0.5(transitive)
+ Addeduntildify@0.1.0(transitive)
- Removedbplist-parser@0.0.4(transitive)
Updatedbplist-parser@0.0.5