Skip to content
Permalink
Browse files

Require Node.js 8

  • Loading branch information
sindresorhus committed Jun 11, 2019
1 parent 6138851 commit b05129a82916528524bed8c205ed55de7d6b344d
Showing with 14 additions and 9 deletions.
  1. +5 −2 index.js
  2. +7 −7 package.json
  3. +2 −0 readme.md
@@ -22,7 +22,10 @@ class Configstore {
this.path = options.configPath || path.join(configDirectory, pathPrefix);

if (defaults) {
this.all = Object.assign({}, defaults, this.all);
this.all = {
...defaults,
...this.all
};
}
}

@@ -55,7 +58,7 @@ class Configstore {
// Make sure the folder exists as it could have been deleted in the meantime
makeDir.sync(path.dirname(this.path), makeDirOptions);

writeFileAtomic.sync(this.path, JSON.stringify(value, null, '\t'), writeFileOptions);
writeFileAtomic.sync(this.path, JSON.stringify(value, undefined, '\t'), writeFileOptions);
} catch (error) {
// Improve the message of permission errors
if (error.code === 'EACCES') {
@@ -10,7 +10,7 @@
"url": "sindresorhus.com"
},
"engines": {
"node": ">=6"
"node": ">=8"
},
"scripts": {
"test": "xo && ava"
@@ -32,15 +32,15 @@
"save"
],
"dependencies": {
"dot-prop": "^4.1.0",
"dot-prop": "^5.1.0",
"graceful-fs": "^4.1.2",
"make-dir": "^2.1.0",
"unique-string": "^1.0.0",
"write-file-atomic": "^2.0.0",
"xdg-basedir": "^3.0.0"
"make-dir": "^3.0.0",
"unique-string": "^2.0.0",
"write-file-atomic": "^3.0.0",
"xdg-basedir": "^4.0.0"
},
"devDependencies": {
"ava": "^1.3.1",
"ava": "^2.1.0",
"xo": "^0.24.0"
}
}
@@ -63,6 +63,8 @@ Default config.

#### options

Type: `object`

##### globalConfigPath

Type: `boolean`<br>

0 comments on commit b05129a

Please sign in to comment.
You can’t perform that action at this time.