From d6010730bedadbf91647d0a47abd1276c544d562 Mon Sep 17 00:00:00 2001 From: Jae Sung Park Date: Fri, 26 Aug 2016 15:50:27 +0900 Subject: [PATCH] chore(changelog): Handle all commit tags Added to handle docs, style and chore tags. Changed boundary regex patterns. Fix #368 Close #369 --- config/exec.js | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/config/exec.js b/config/exec.js index 2f0bb3d..c97eb99 100644 --- a/config/exec.js +++ b/config/exec.js @@ -1,9 +1,12 @@ -// Filtering types +// Commit log tag filtering types for changelog var filterType = { feat: "Features", fix: "Bug Fixes", + docs: "Documents", + style: "Code Styles", refactor: "Refactorings", - test: "Test Codes" + test: "Test Codes", + chore: "Chore tasks" }; module.exports = { @@ -79,7 +82,7 @@ module.exports = { var rxNewline = /\r?\n/g; var rxBody = /(?:ref|fix|close)\s([egy#]|gh)-?([0-9]+)/i; - var rxSubject = new RegExp("^("+ Object.keys(filterType).join("|") +")\\s?\\(([a-z-_,\\s]+)\\)\\s*:\\s*(.*)", "i"); + var rxSubject = new RegExp("^("+ Object.keys(filterType).join("|") +")\\s?\\(([\\w-,\\s]+)\\)\\s*:\\s*(.*)", "i"); var issue, subject, category, module; for (var i = 0, el; el = result.logs.item[i]; i++) { @@ -177,4 +180,4 @@ module.exports = { }, stdout: false } -}; \ No newline at end of file +};