Skip to content

Commit 0705cd5

Browse files
committedJun 22, 2018
feat: enforce Conventional Commit style commit messages (#282)
* feat: enforce Conventional Commit style * chore: drop node@0.12 from Travis tests
1 parent 2e33970 commit 0705cd5

File tree

4 files changed

+1805
-801
lines changed

4 files changed

+1805
-801
lines changed
 

‎.travis.yml

-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
language: node_js
22
node_js:
3-
- "0.12"
43
- "4"
54
- "6"
65
- "8"

‎README.md

+6-6
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ Version 1 (timestamp):
2828

2929
```javascript
3030
const uuidv1 = require('uuid/v1');
31-
uuidv1(); // ⇨ '1c572360-faca-11e7-83ee-9d836d45ff41'
31+
uuidv1(); // ⇨ '3b99e3e0-7598-11e8-90be-95472fb3ecbd'
3232

3333
```
3434

@@ -56,7 +56,7 @@ Version 4 (random):
5656

5757
```javascript
5858
const uuidv4 = require('uuid/v4');
59-
uuidv4(); // ⇨ '45db52e1-f95c-4b5f-99a2-8b8d978c99b4'
59+
uuidv4(); // ⇨ '3a017fc5-4f50-4db9-b0ce-4547ba0a1bfd'
6060

6161
```
6262

@@ -167,8 +167,8 @@ Example: In-place generation of two binary IDs
167167
```javascript
168168
// Generate two ids in an array
169169
const arr = new Array();
170-
uuidv1(null, arr, 0); // ⇨ [ 28, 97, 14, 112, 250, 202, 17, 231, 146, 52, 157, 131, 109, 69, 255, 65 ]
171-
uuidv1(null, arr, 16); // ⇨ [ 28, 97, 14, 112, 250, 202, 17, 231, 146, 52, 157, 131, 109, 69, 255, 65, 28, 97, 53, 128, 250, 202, 17, 231, 146, 52, 157, 131, 109, 69, 255, 65 ]
170+
uuidv1(null, arr, 0); // ⇨ [ 59, 155, 106, 128, 117, 152, 17, 232, 146, 52, 149, 71, 47, 179, 236, 189 ]
171+
uuidv1(null, arr, 16); // ⇨ [ 59, 155, 106, 128, 117, 152, 17, 232, 146, 52, 149, 71, 47, 179, 236, 189, 59, 155, 145, 144, 117, 152, 17, 232, 146, 52, 149, 71, 47, 179, 236, 189 ]
172172

173173
```
174174

@@ -237,8 +237,8 @@ Example: Generate two IDs in a single buffer
237237

238238
```javascript
239239
const buffer = new Array();
240-
uuidv4(null, buffer, 0); // ⇨ [ 253, 175, 55, 222, 195, 132, 75, 162, 156, 105, 127, 104, 58, 195, 192, 66 ]
241-
uuidv4(null, buffer, 16); // ⇨ [ 253, 175, 55, 222, 195, 132, 75, 162, 156, 105, 127, 104, 58, 195, 192, 66, 210, 238, 41, 99, 195, 139, 75, 146, 144, 79, 164, 48, 65, 180, 91, 48 ]
240+
uuidv4(null, buffer, 0); // ⇨ [ 202, 18, 44, 182, 222, 65, 71, 82, 164, 80, 208, 169, 173, 93, 252, 13 ]
241+
uuidv4(null, buffer, 16); // ⇨ [ 202, 18, 44, 182, 222, 65, 71, 82, 164, 80, 208, 169, 173, 93, 252, 13, 243, 221, 205, 191, 130, 146, 75, 199, 146, 71, 96, 195, 45, 156, 124, 9 ]
242242

243243
```
244244

‎package-lock.json

+1,789-792
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎package.json

+10-2
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,11 @@
22
"name": "uuid",
33
"version": "3.2.1",
44
"description": "RFC4122 (v1, v4, and v5) UUIDs",
5+
"commitlint": {
6+
"extends": [
7+
"@commitlint/config-conventional"
8+
]
9+
},
510
"keywords": [
611
"uuid",
712
"guid",
@@ -12,12 +17,16 @@
1217
"uuid": "./bin/uuid"
1318
},
1419
"devDependencies": {
20+
"@commitlint/cli": "7.0.0",
21+
"@commitlint/config-conventional": "7.0.1",
1522
"eslint": "4.5.0",
23+
"husky": "0.14.3",
1624
"mocha": "3.1.2",
1725
"runmd": "1.0.1",
1826
"standard-version": "4.2.0"
1927
},
2028
"scripts": {
29+
"commitmsg": "commitlint -E GIT_PARAMS",
2130
"test": "mocha test/test.js",
2231
"md": "runmd --watch --output=README.md README_js.md",
2332
"release": "standard-version",
@@ -31,6 +40,5 @@
3140
"repository": {
3241
"type": "git",
3342
"url": "https://github.com/kelektiv/node-uuid.git"
34-
},
35-
"dependencies": {}
43+
}
3644
}

0 commit comments

Comments
 (0)
Please sign in to comment.