Skip to content

Commit

Permalink
support HUSKY_GIT_PARAMS
Browse files Browse the repository at this point in the history
  • Loading branch information
chenshuai2144 committed May 8, 2021
1 parent 8cb9bf0 commit 5242b98
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/verifyCommit.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
const chalk = require('chalk');
const osLocale = require('os-locale');

const msgPath = process.env.GIT_PARAMS;
const msgPath = process.env.GIT_PARAMS || process.env.HUSKY_GIT_PARAMS;
const msg = require('fs').readFileSync(msgPath, 'utf-8').trim();

const commitRE = /^(((\ud83c[\udf00-\udfff])|(\ud83d[\udc00-\ude4f\ude80-\udeff])|[\u2600-\u2B55]) )?(revert: )?(feat|fix|docs|UI|refactor|⚡perf|workflow|build|CI|typos|chore|tests|types|wip|release|dep|locale)(\(.+\))?: .{1,50}/;
Expand Down

0 comments on commit 5242b98

Please sign in to comment.