Skip to content

Commit

Permalink
Require Node.js 8
Browse files Browse the repository at this point in the history
  • Loading branch information
sindresorhus committed Mar 27, 2019
1 parent 09730f8 commit ded993f
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 7 deletions.
1 change: 0 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,3 @@ language: node_js
node_js:
- '10'
- '8'
- '6'
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"url": "sindresorhus.com"
},
"engines": {
"node": ">=6"
"node": ">=8"
},
"scripts": {
"test": "xo && ava",
Expand Down
6 changes: 4 additions & 2 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

> List of [SPDX licenses](https://spdx.org/licenses/)
The lists of licenses are just JSON files and can be used wherever.
The lists of licenses are just JSON files and can be used anywhere.

- [spdx.json](spdx.json) contains just license metadata
- [spdx-full.json](spdx-full.json) includes the license text too
Expand All @@ -21,7 +21,6 @@ $ npm install spdx-license-list
## Usage

```js
const fs = require('fs');
const spdxLicenseList = require('spdx-license-list');

console.log(spdxLicenseList.MIT);
Expand All @@ -32,8 +31,11 @@ console.log(spdxLicenseList.MIT);
osiApproved: true
}
*/
```

```js
const mitLicense = require('spdx-license-list/licenses/MIT');

console.log(mitLicense.licenseText);
//=> 'MIT License\r\n\r\nCopyright (c) <year> <copyright holders> …'
```
Expand Down
6 changes: 3 additions & 3 deletions test.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import test from 'ava';
import m from '.';
import spdxLicenseList from '.';

test('main', t => {
t.is(m.MIT.name, 'MIT License');
t.is(m.MIT.url, 'http://www.opensource.org/licenses/MIT');
t.is(spdxLicenseList.MIT.name, 'MIT License');
t.is(spdxLicenseList.MIT.url, 'http://www.opensource.org/licenses/MIT');
t.true(require('./full').MIT.licenseText.length > 0);
t.true(require('./simple').has('MIT'));
t.is(require('./licenses/MIT').name, 'MIT License');
Expand Down

0 comments on commit ded993f

Please sign in to comment.